summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* ide: sanitize handling of IDE_HFLAG_NO_SET_MODE host flagBartlomiej Zolnierkiewicz2008-04-264-10/+13
| | | | | | | | | | | | | | * Check for IDE_HFLAG_NO_SET_MODE host flag in ide_set_pio(), ide_set_[pio,dma]_mode(), ide_set_xfer_rate() and set_pio_mode(). * Remove no longer needed IDE_HFLAG_NO_SET_MODE host flag checking from ide_tune_dma(). * Remove superfluous ->set_pio_mode checking from do_special(). This is a part of preparations for adding 'struct ide_port_ops'. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* sis5513: fail early for unsupported chipsetsBartlomiej Zolnierkiewicz2008-04-261-15/+15
| | | | | | | | | | | | | | | * Factor out chipset family detection from init_chipset_sis5513() to sis_find_family(). * Use sis_find_family() in sis5513_init_one() to fail early if the chipset is unsupported. * Keep a local copy sis5513_chipset in sis5513_init_one() and set .udma_mask according to chipset family. * Remove no longer need ->ultra_mask setting from init_hwif_sis5513(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* it821x: fix kzalloc() failure handlingBartlomiej Zolnierkiewicz2008-04-261-6/+18
| | | | | | | | | Allocate 'struct it821x_dev' objects for both ports in it821x_init_one(). Fixes potential OOPS in it821x_quirkproc() (uses 'itdev' unconditionally) and other problems ('itdev' is needed for correct operation of the driver). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* qd65xx: use IDE_HFLAG_SINGLE host flagBartlomiej Zolnierkiewicz2008-04-262-21/+15
| | | | | | | | | | | | | | | | | | * Set IDE_HFLAG_SINGLE host flag in qd_probe() for QD6500 and QD6580 with the second port disabled. * Check for IDE_HFLAG_SINGLE in qd6580_port_init_devs() instead of using cached value of QD6580 Control register. * Don't cache QD6580 Control register value in hwif->config_data (bits 8-15) and remove no longer needed QD_CONTROL() macro. * Cache QD65xx base address in hwif->config_data (bits 8-15) instead of hwif->select_data. * Set hwif->config_data in qd_probe() and remove qd_setup() helper. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* qd65xx: always use ->selectproc methodBartlomiej Zolnierkiewicz2008-04-261-27/+10
| | | | | | | | qd_select() checks itself whether timings should be reprogrammed so remove superfluous qd_timing_ok() and always use ->selectproc method (rename qd_select() to qd65xx_select() while at it). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: put proc-related functions together under single ifdefBorislav Petkov2008-04-261-13/+10
| | | | | | | [bart: ported it over Paolo's patch] Signed-off-by: Borislav Petkov <petkovbb@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: Replace __FUNCTION__ with __func__Paolo Ciarrocchi2008-04-261-5/+5
| | | | | | | [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/ide-cd.cPaolo Ciarrocchi2008-04-261-124/+134
| | | | | | | | | | | | | | | | Before: total: 43 errors, 66 warnings, 2183 lines checked After: total: 0 errors, 36 warnings, 2192 lines checked I didn't (and I don't plan to) fix the warnings: WARNING: line over 80 characters [bart: minor fixes, md5sum checked (modulo s/"ignore = NULL;"/"ignore;"/ fix)] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/cy82c693.cPaolo Ciarrocchi2008-04-261-37/+37
| | | | | | | | | | | | | Before: total: 34 errors, 14 warnings, 456 lines checked After: total: 0 errors, 8 warnings, 456 lines checked [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/it8213.cPaolo Ciarrocchi2008-04-261-5/+4
| | | | | | | | | | | | | | File is now error free, only a few WARNING: line over 80 characters are left. Compile tested. [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/ide-floppy.cPaolo Ciarrocchi2008-04-261-8/+8
| | | | | | | | | | File is now error free. Compile tested. [bart: minor fixes, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/legacy/ali14xx.cPaolo Ciarrocchi2008-04-261-5/+6
| | | | | | | | | | File is now error free, 2 warnings left. Compile tested. [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/legacy/hd.cPaolo Ciarrocchi2008-04-261-38/+40
| | | | | | | | | | Fix a lot of errors and warnings. Compile tested. [bart: some fixes, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/cmd640.cPaolo Ciarrocchi2008-04-261-46/+48
| | | | | | | | | | Fix all the errors and a few warnings. Compile tested. [bart: some fixes, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/opti621.cPaolo Ciarrocchi2008-04-261-25/+30
| | | | | | | | | Compile tested. [bart: some fixes, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/ide-pnp.cPaolo Ciarrocchi2008-04-261-5/+5
| | | | | | | | | | File is now error free. Compile tested. [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/ide-proc.cPaolo Ciarrocchi2008-04-261-80/+75
| | | | | | | | | | Lot of errors and warnings removed. Compile tested. [bart: minor fixes, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/legacy/ide-4drives.cPaolo Ciarrocchi2008-04-261-1/+1
| | | | | | | | | | File is now error and warning free. Compile tested. [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/legacy/umc8672.cPaolo Ciarrocchi2008-04-261-29/+29
| | | | | | | | | | File is now error free. Compile tested. [bart: minor fixes, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/generic.cPaolo Ciarrocchi2008-04-261-2/+2
| | | | | | | | | | File is now error free. Compile tested. [bart: fix issues noticed by Adrian Bunk & Cyrill Gorcunov, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/jmicron.cPaolo Ciarrocchi2008-04-261-2/+1
| | | | | | | | | | File is now error free. Compile tested. [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/sis5513.cPaolo Ciarrocchi2008-04-261-100/+98
| | | | | | | | | | | About 300 errors and warnings fixed. File is now error free. Compile tested. [bart: minor fixes, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/slc90e66.cPaolo Ciarrocchi2008-04-261-3/+3
| | | | | | | | | | File is now error free, only 1 warning left. Compile tested. [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/pci/tc86c001.cPaolo Ciarrocchi2008-04-261-14/+14
| | | | | | | | | | File is now error and warning free. Compile tested. [bart: md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* IDE: Coding Style fixes to drivers/ide/setup-pci.cPaolo Ciarrocchi2008-04-261-17/+12
| | | | | | | | | | File is now error free. Compile tested. [bart: minor fixes, md5sum checked] Signed-off-by: Paolo Ciarrocchi <paolo.ciarrocchi@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: remove hwif->straight8 flagBartlomiej Zolnierkiewicz2008-04-262-26/+11
| | | | | | | | All host drivers now either set hwif->mmio or reserve continuous I/O resources so remove no longer needed hwif->straight8 flag and never reached code for 'hwif->straight8 == 0' case. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: remove IDE_HFLAG_CY82C693 host flagBartlomiej Zolnierkiewicz2008-04-263-11/+3
| | | | | | | | Sergei suggested that it shouldn't be necessary + it had no effect anyway since ide_id_dma_bug() is called earlier in ide_tune_dma(). Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* falconide: fix resources reservation (take 2)Bartlomiej Zolnierkiewicz2008-04-261-0/+7
| | | | | | | | | | | | | | | | * Tell IDE layer to not manage resources by setting hwif->mmio flag and request resources in falconide_init(). * Use request_mem_region() for resources reservation. * Use driver name for resources reservation. v2: * Fix missing printk() parameter. (Noticed by Geert Uytterhoeven) Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Michael Schmitz <schmitz@debian.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-mpc8xx: fix resources reservationBartlomiej Zolnierkiewicz2008-04-261-1/+17
| | | | | | | | | | | | * Tell IDE layer to not manage resources by setting hwif->mmio flag and request resources in m8xx_ide_init_ports(). * Use request_mem_region() for resources reservation. * Use driver name for resources reservation. Cc: Vitaly Bordug <vitb@kernel.crashing.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-mpc8xx: make m8xx_ide_init_ports() return an error valueBartlomiej Zolnierkiewicz2008-04-261-15/+25
| | | | | | | | | | * Make m8xx_ide_init_ports() return an error value. * Update mpc8xx_ide_probe() to setup/probe only ports for which m8xx_ide_init_ports() succedded. Cc: Vitaly Bordug <vitb@kernel.crashing.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* bast-ide: fix resources reservationBartlomiej Zolnierkiewicz2008-04-261-0/+10
| | | | | | | | | | | | * Tell IDE layer to not manage resources by setting hwif->mmio flag and request resources in bastide_init(). * Use request_mem_region() for resources reservation. * Use driver name for resources reservation. Cc: Ben Dooks <support@simtec.co.uk> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* delkin_cb: fix resources handlingBartlomiej Zolnierkiewicz2008-04-261-1/+3
| | | | | | | Tell IDE layer to not manage resources by setting hwif->mmio flag. Cc: Mark Lord <mlord@pobox.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide_platform: fix resources handlingBartlomiej Zolnierkiewicz2008-04-261-3/+2
| | | | | | | | | Tell IDE layer to not manage resources by always setting hwif->mmio flag (resources are handled by a platform device). Cc: Anton Vorontsov <avorontsov@ru.mvista.com> Cc: Vitaly Bordug <vitb@kernel.crashing.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* remove include/linux/hdsmart.hAdrian Bunk2008-04-262-127/+0
| | | | | | | | | include/linux/hdsmart.h is not used by the kernel and should therefore be removed. Signed-off-by: Adrian Bunk <bunk@kernel.org> Cc: "Robert P. J. Day" <rpjday@crashcourse.ca>, Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove the internal 64k bufferBorislav Petkov2008-04-262-123/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This removes the internal ide-cd buffer and falls back to read-ahead block layer capabilities. Thorough testing (cd burning, dvd read, raw read) gives with the bufferless mode marginally better performance in addition to simplified code. bufferless: dd: reading `/dev/hdc': Input/output error 6238+0 records in 6238+0 records out 204406784 bytes (204 MB) copied, 259.891 s, 787 kB/s real 4m21.598s user 0m0.014s sys 0m0.744s with the old buffer (2.6.25-rc1): dd: reading `/dev/hdc': Input/output error 6238+0 records in 6238+0 records out 204406784 bytes (204 MB) copied, 262.893 s, 778 kB/s real 4m22.938s user 0m0.009s sys 0m0.771s Signed-off-by: Borislav Petkov <petkovbb@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-disk: fix issues found by checkpatch.plBartlomiej Zolnierkiewicz2008-04-261-50/+70
| | | | | | | | There are no changes to the resulting drivers/ide/ide-disk.o binary file (md5sum-s after and before the patch match). Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-disk: add proc_idedisk_read_smart() helperBartlomiej Zolnierkiewicz2008-04-261-22/+17
| | | | | | | | | | | | * Factor out common code from proc_idedisk_read_smart_{thresholds,values}() to proc_idedisk_read_smart() helper. * Rename proc_idedisk_read_smart_thresholds() to proc_idedisk_read_st() and proc_idedisk_read_smart_values() to proc_idedisk_read_sv(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: unexport ide_hwifs[]Bartlomiej Zolnierkiewicz2008-04-261-5/+0
| | | | | | All modular users have been fixed to not reference ide_hwifs[] directly. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-generic: use ide_find_port() (take 3)Bartlomiej Zolnierkiewicz2008-04-261-2/+12
| | | | | | | | | | | | | | | There should be no functional changes caused by this patch. v2: * Fix comment (noticed by Sergei Shtylyov). v3: * Fix no initalization of idx in some case. (Johann Felix Soden) Cc: Johann Felix Soden <johfel@users.sourceforge.net> Cc: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com> Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: use ide_find_port() in legacy VLB host drivers (take 2)Bartlomiej Zolnierkiewicz2008-04-268-81/+122
| | | | | | | | | | | | | | | | | | * Add IDE_HFLAG_QD_2ND_PORT host flag to indicate the need of skipping first ide_hwifs[] slot for the second port of QD65xx controller. * Handle this new host flag in ide_find_port_slot(). * Convert legacy VLB host drivers to use ide_find_port(). While at it: * Fix couple of printk()-s in qd65xx host driver to not use hwif->name. v2: * Fix qd65xx. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: merge ide_match_hwif() and ide_find_port()Bartlomiej Zolnierkiewicz2008-04-264-63/+54
| | | | | | | | | | | | | | * Change ide_match_hwif() argument from 'u8 bootable' to 'struct ide_port_info *d'. * Move ide_match_hwif() to ide-probe.c from setup-pci.c and rename it to ide_find_port_slot(). Update some comments while at it. * ide_find_port() can be now just a wrapper for ide_find_port_slot(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: remove PIO "downgrade" quirkBartlomiej Zolnierkiewicz2008-04-265-15/+0
| | | | | | | No need for it nowadays so remove quirk code from ide_get_best_pio_mode() and IDE_HFLAG_PIO_DOWNGRADE host flag. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: use DIV_ROUND_UPJulia Lawall2008-04-262-16/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The kernel.h macro DIV_ROUND_UP performs the computation (((n) + (d) - 1) / (d)) but is perhaps more readable. An extract of the semantic patch that makes this change is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @haskernel@ @@ #include <linux/kernel.h> @depends on haskernel@ expression n,d; @@ ( - (n + d - 1) / d + DIV_ROUND_UP(n,d) | - (n + (d - 1)) / d + DIV_ROUND_UP(n,d) ) @depends on haskernel@ expression n,d; @@ - DIV_ROUND_UP((n),d) + DIV_ROUND_UP(n,d) @depends on haskernel@ expression n,d; @@ - DIV_ROUND_UP(n,(d)) + DIV_ROUND_UP(n,d) // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: IDE_HFLAG_BOOTABLE -> IDE_HFLAG_NON_BOOTABLEBartlomiej Zolnierkiewicz2008-04-2631-60/+37
| | | | | | | | | "bootable" should be the default behavior so replace IDE_HFLAG_BOOTABLE host flag with IDE_HFLAG_NON_BOOTABLE. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* qd65xx: return error value in qd_probe()Bartlomiej Zolnierkiewicz2008-04-261-10/+15
| | | | | | | | Return error value in qd_probe() and use it in qd65xx_init() instead of checking ide_hwifs[].chipset. Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ht6560b: use driver name for resource allocationBartlomiej Zolnierkiewicz2008-04-261-1/+2
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* umc8672: don't use ide_hwifs[] in umc_set_pio_mode()Bartlomiej Zolnierkiewicz2008-04-261-2/+2
| | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* scc_pata: store 'hwif' pointer in struct scc_portsBartlomiej Zolnierkiewicz2008-04-261-3/+3
| | | | | | | | | Replace 'unsigned char hwif_id' by 'ide_hwif_t *hwif' in struct scc_ports. This allows us to remove ide_hwifs[] usage from scc_remove(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* cmd640: use ide_find_port()Bartlomiej Zolnierkiewicz2008-04-261-10/+19
| | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* cmd640: remove cmd_drives[]Bartlomiej Zolnierkiewicz2008-04-261-40/+27
| | | | | | | | | | | * Pass 'ide_drive_t *drive' to check_prefetch(), set_prefetch_mode(), program_drive_counts() and cmd640_set_mode(). * Remove no longer needed cmd_drives[]. * Inline setup_device_ptrs() helper in cmd640x_init(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
OpenPOWER on IntegriCloud