aboutsummaryrefslogtreecommitdiff
path: root/drivers/ide
AgeCommit message (Collapse)Author
2008-07-14Merge branch 'bkl-removal' of git://git.lwn.net/linux-2.6Linus Torvalds
* 'bkl-removal' of git://git.lwn.net/linux-2.6: (146 commits) IB/umad: BKL is not needed for ib_umad_open() IB/uverbs: BKL is not needed for ib_uverbs_open() bf561-coreb: BKL unneeded for open() Call fasync() functions without the BKL snd/PCM: fasync BKL pushdown ipmi: fasync BKL pushdown ecryptfs: fasync BKL pushdown Bluetooth VHCI: fasync BKL pushdown tty_io: fasync BKL pushdown tun: fasync BKL pushdown i2o: fasync BKL pushdown mpt: fasync BKL pushdown Remove BKL from remote_llseek v2 Make FAT users happier by not deadlocking x86-mce: BKL pushdown vmwatchdog: BKL pushdown vmcp: BKL pushdown via-pmu: BKL pushdown uml-random: BKL pushdown uml-mmapper: BKL pushdown ...
2008-07-14Merge commit 'v2.6.26' into bkl-removalJonathan Corbet
2008-07-14Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6Linus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6: (23 commits) pcmcia: Fix ide-cs sparse warning pcmcia: ide-cs debugging bugfix pcmcia: allow for longer CIS firmware files pcmcia: cm40x0 cdev lock_kernel() pushdown pcmcia: (re)move {pcmcia,pccard}_get_status pcmcia: kill IN_CARD_SERVICES pcmcia: Remove unused header file code pcmcia: remove unused bulkmem.h pcmcia: simplify pccard_validate_cis pcmcia: carve out ioctl adjust function to pcmcia_ioctl pcmcia: irq probe can be done without risking an IRQ storm pcmcia: Fix ti12xx_2nd_slot_empty always failing pcmcia: check for pointer instead of pointer address pcmcia: switch cm4000_cs.c to unlocked_ioctl pcmcia: simplify rsrc_nonstatic attributes pcmcia: add support CompactFlash PCMCIA support for Blackfin. pcmcia: remove version.h pcmcia: cs: kill thread_wait pcmcia: i82365.c: check request_irq return value pcmcia: fix Alchemy warnings ...
2008-07-14pcmcia: Fix ide-cs sparse warningLarry Finger
Sparse shows the following warning: CHECK drivers/ide/legacy/ide-cs.c drivers/ide/legacy/ide-cs.c:378:6: warning: symbol 'ide_release' was not declared. Should it be static? Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> CC: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
2008-07-13pcmcia: ide-cs debugging bugfixLarry Finger
The code in module ide-cs does not conform to the current standard if setting CONFIG_PCMCIA_DEBUG to "y", and loading the module with the option "pc_debug=N". When that is fixed, then a warning results that version is defined but not used. This patch fixes both situations. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> CC: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
2008-07-08it8213: fix return value in it8213_init_one()Bartlomiej Zolnierkiewicz
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-07-08palm_bk3710: fix IDECLK period calculationSergei Shtylyov
The driver uses completely bogus rounding formula for calculating period from the IDECLK frequency which gives one-off period values (e.g. 11 ns with 100 MHz IDECLK) which in turn can lead to overclocked IDE transfer timings. Actually, rounding is just wrong in this case, so use a mere division for a safe result. While at it, also: - give 'ide_palm_clk' variable a more suitable name; - get rid of the useless 'ideclkp' variable; - drop the LISP stype 'p' postfix from the 'clkp' variable's name. :-) Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Cc: mcherkashin@ru.mvista.com Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-07-08ide: add __ide_default_irq() inline helperBartlomiej Zolnierkiewicz
Add __ide_default_irq() inline helper and use it instead of ide_default_irq() in ide-probe.c and ns87415.c (all host drivers except IDE PCI ones always setup hwif->irq so it is enough to check only for I/O bases 0x1f0 and 0x170). This fixes post-2.6.25 regression since ide_default_irq() define could shadow ide_default_irq() inline. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-07-05ide: ide_unregister() locking bugfixBartlomiej Zolnierkiewicz
Holding ide_lock for ide_release_dma_engine() call is unnecessary and triggers WARN_ON(irqs_disabled()) in dma_free_coherent(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-07-05ide: ide_unregister() warm-plug bugfixBartlomiej Zolnierkiewicz
Fix ide_unregister() to work for ports with no devices attached to them. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-07-05ide: fix hwif->gendev refcountingBartlomiej Zolnierkiewicz
class->dev_release is called by device_release() iff dev->release is not present so ide_port_class_release() is never called and the last hwif->gendev reference is not dropped. Fix it by removing ide_port_class_release() and get_device() call from ide_register_port() (device_create_drvdata() takes a hwif->gendev reference anyway). This patch fixes hang on wait_for_completion(&hwif->gendev_rel_comp) in ide_unregister() reported by Pavel Machek. Cc: Pavel Machek <pavel@suse.cz> Cc: "Rafael J. Wysocki" <rjw@sisk.pl> Cc: Greg KH <greg@kroah.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-30ide: fix /proc/ide/ide?/mate reportingBartlomiej Zolnierkiewicz
Now that we support warm-plug mate port will be registered even if there are no devices attached to it. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-30Revert "BAST: Remove old IDE driver"Bartlomiej Zolnierkiewicz
This reverts commit ac1623625c5818bbdf5c68973098ba386ba7a004. It was premature to remove it now, we will do it post-2.6.26. Thanks to Russell King for noticing the issue. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-20ide-tape: cdev lock_kernel() pushdownJonathan Corbet
->release() already has explicit lock_kernel() calls... Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2008-06-20BAST: Remove old IDE driverBen Dooks
Remove the old BAST IDE driver, as we are now using the platform-pata support. Signed-off-by: Ben Dooks <ben-linux@fluff.org> Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-20pcmcia ide kingston compactflash's have a new manufacturer idChristophe Niclaes
Up to now, Kingston compactflash cards (ab)used the Toshiba Manufacturer's ID, In their new CF cards, they use a new one. Let's the ide subsystem recognize CF cards with the new id. Signed-off-by: Christophe Niclaes <cniclaes@develtech.com> Acked-by: Philippe De Muyter <phdm@macqel.be> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Cc: Dominik Brodowski <linux@dominikbrodowski.net> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-20pcmcia: add another pata/ide IDKristoffer Ericson
Addition of Transcend 1GB 45x id so that it is properly detected. [bart: fix typo in ide-cs's ID spotted by Alan Cox] Signed-off-by: William Peters <w1ll14@gmail.com> Signed-off-by: Kristoffer Ericson <Kristoffer_e1@hotmail.com> CC: Alan Cox <alan@lxorguk.ukuu.org.uk> CC: linux-ide@vger.kernel.org Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-20pcmcia: add an pata/ide IDMatt Reimer
Add an id for: product info: "M-Systems", "CF300", "" manfid: 0x000a, 0x0000 function: 4 (fixed disk) Signed-off-by: Matt Reimer <mreimer@vpop.net> CC: Alan Cox <alan@lxorguk.ukuu.org.uk> CC: linux-ide@vger.kernel.org Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-20ide: increase timeout in wait_drive_not_busy()Bartlomiej Zolnierkiewicz
Some ATAPI devices take longer than the current max timeout value to become ready (i.e. TEAC DV-W28ECW takes 6 ms) so increase the timeout value to 10 ms. This fixes kernel.org bugzilla bug #10887: http://bugzilla.kernel.org/show_bug.cgi?id=10887 Reported-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-20palm_bk3710: fix resource managementSergei Shtylyov
The driver expected a *virtual* address in the IDE platform device's memory resource and didn't request the memory region for the register block. Fix this taking into account the fact that DaVinci SoC devices are fixed-mapped to the virtual memory early and we can get their virtual addresses using IO_ADDRESS() macro, not having to call ioremap()... While at it, also do some cosmetic changes... Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15ide-generic: don't probe all legacy ISA IDE ports by defaultBartlomiej Zolnierkiewicz
We can't probe all legacy ISA IDE ports by default as the resources may be occupied by other ISA devices. Add "probe_mask" module parameter and probe only first two ISA IDE ports by default leaving the decision about probing the rest to the user (systems with ISA ide2-6 should be very, very rare). This fixes a regression caused by: commit 343a3451e20314d5959b59b992e33fbaadfe52bf Author: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Date: Tue Jun 10 20:56:36 2008 +0200 ide-generic: add missing hwif->chipset setup ... Reported-by: Mikael Pettersson <mikpe@it.uu.se> Bisected-by: Mikael Pettersson <mikpe@it.uu.se> Tested-by: Mikael Pettersson <mikpe@it.uu.se> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15ide-cs: fix releasing I/O resourcesBartlomiej Zolnierkiewicz
hwif content is already freed after ide_release() call so cache hwif->io_ports.{data,ctl}_addr in local variables in ide_detach(). This fixes post-2.6.25 regression. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15ide-cs: fix probing and add warm-plug supportBartlomiej Zolnierkiewicz
* Fix probing by using ide_port_scan() and moving "retry loop" from ide_config() to idecs_register(). * Don't fail probe if there are no devices attached to a port. * Remove (now redundant) error message from ide_config(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15ide-pmac: remove bogus comment about pmac_ide_setup_device()Bartlomiej Zolnierkiewicz
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15ide-pmac: add ->cable_detect methodBartlomiej Zolnierkiewicz
Add ->cable_detect method and remove no longer needed pmif->cable_80 flag (there is also no need to mask ->udma_mask now). This fixes: - forced ignoring of cable detection (needed for some CF devices & debug) - cable detection for warm-plug Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15opti621: add PIO 4 supportBartlomiej Zolnierkiewicz
* Add PIO 4 support. While at it: * Use a single struct ide_port_info instance for OPTi621 and OPTi621X. Based on a bugreport from Juergen Kosel & inspired by pata_opti.c code. Tested-by: Juergen Kosel <juergen.kosel@gmx.de> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15opti621: use pre-calculated PIO timingsBartlomiej Zolnierkiewicz
* Use pre-calculated PIO timings in ->set_pio_mode. * Remove no longer needed compute_clocks(), cmpt_clk(), struct pio_clocks_s, PIO_* defines and OPTI621_DEBUG define. There should be no functional changes caused by this patch. Based on a bugreport from Juergen Kosel & inspired by pata_opti.c code. Tested-by: Juergen Kosel <juergen.kosel@gmx.de> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15opti621: program devices timings separately in ->set_pio_modeBartlomiej Zolnierkiewicz
* Set drive->drive_data to 'pio + XFER_PIO_0' instead of 'pio', then simplify selecting maximum adress setup timing. * Remove no longer needed compute_pios() and opti621_port_init_devs(). * Program devices timings separately in ->set_pio_mode. Based on a bugreport from Juergen Kosel & inspired by pata_opti.c code. Tested-by: Juergen Kosel <juergen.kosel@gmx.de> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15opti621: use PCI clock value provided by controllerBartlomiej Zolnierkiewicz
Use PCI clock value provided by controller instead of depending on a default (or user supplied) value. Based on a bugreport from Juergen Kosel & inspired by pata_opti.c code. Tested-by: Juergen Kosel <juergen.kosel@gmx.de> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15opti621: remove DMA supportBartlomiej Zolnierkiewicz
These controllers don't support DMA. Based on a bugreport from Juergen Kosel & inspired by pata_opti.c code. Tested-by: Juergen Kosel <juergen.kosel@gmx.de> Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-15opti621: disable read prefetchBartlomiej Zolnierkiewicz
This fixes 2.6.25 regression (kernel.org bugzilla bug #10723) caused by: commit 912fb29a36a7269ac1c4a4df45bc0ac1d2637972 Author: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Date: Fri Oct 19 00:30:11 2007 +0200 opti621: always tune PIO ... Based on a bugreport from Juergen Kosel & inspired by pata_opti.c code. Bisected-by: Juergen Kosel <juergen.kosel@gmx.de> Tested-by: Juergen Kosel <juergen.kosel@gmx.de> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10fix BLK_DEV_HD_ONLY on ARM dependenciesAdrian Bunk
This patch limits BLK_DEV_HD_ONLY to the ARM platforms offering IRQ_HARDDISK, fixing the following compile error on others: <-- snip --> ... CC drivers/ide/legacy/hd.o ... /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/ide/legacy/hd.c: In function 'hd_times_out': /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/ide/legacy/hd.c:542: error: 'IRQ_HARDDISK' undeclared (first use in this function) /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/ide/legacy/hd.c:542: error: (Each undeclared identifier is reported only once /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/ide/legacy/hd.c:542: error: for each function it appears in.) /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/ide/legacy/hd.c: In function 'do_hd_request': /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/ide/legacy/hd.c:661: error: 'IRQ_HARDDISK' undeclared (first use in this function) /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/ide/legacy/hd.c: In function 'hd_init': /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/ide/legacy/hd.c:765: error: 'IRQ_HARDDISK' undeclared (first use in this function) make[3]: *** [drivers/ide/legacy/hd.o] Error 1 <-- snip --> Reported-by: Adrian Bunk <bunk@kernel.org> Cc: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10ide: export ide_doublerAdrian Bunk
This patch fixes the following build error: <-- snip --> ... Building modules, stage 2. MODPOST 1204 modules ERROR: "ide_doubler" [drivers/ide/ide-core.ko] undefined! ... make[2]: *** [__modpost] Error 1 <-- snip --> Reported-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10palm_bk3710: add warm-plug supportBartlomiej Zolnierkiewicz
Don't fail the probe if there are no devices attached to the controller. Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10delkin_cb: add missing __init/__exit tagsBartlomiej Zolnierkiewicz
Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10delkin_cb: add warm-plug supportBartlomiej Zolnierkiewicz
Don't fail the probe if there are no devices attached to the controller. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10delkin_cb: use struct ide_port_infoBartlomiej Zolnierkiewicz
Convert the driver to use struct ide_port_info - as a nice side-effect this fixes racy setup of ->io_32bit/unmask settings (after ide_device_add() call device can be already in use). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10delkin_cb: set proper hwif->gendev.parent valueBartlomiej Zolnierkiewicz
hwif->dev was set too late (after ide_device_add() call) so hwif->gendev.parent was not initialized properly. Fix it by setting hw.dev and letting ide_init_port_hw() do the rest. Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10ide: fix host drivers missing hwif->chipset initializationBartlomiej Zolnierkiewicz
ide_find_port() now depends on ->chipset being set for occupied ide_hwifs[] slots so all host drivers have to initialize hwif->chipset properly. This patch fixes a regression on hosts with > 1 port or with a single port but no devices attached to it for an affected host drivers. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10ide-generic: add missing hwif->chipset setupBartlomiej Zolnierkiewicz
hwif->chipset need to be set properly or ide-generic driver will break once we make a final step in fixing host drivers' dependence on ide_hwifs[]. Problem was catched early thanks to IDE tree exposure in -mm / -next trees and reported by people listed people (thank you guys!). Reported-by: "John Keller" <jpk@sgi.com> Reported-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com> Reported-by: Mel Gorman <mel@csn.ul.ie> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10sis5513: add missing pci_enable_device() callBartlomiej Zolnierkiewicz
Cc: Riccardo Gori <goric@trivenet.it> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-06-10ide: remove the ide_etrax100 chipset typeAdrian Bunk
I forgot to remove the ide_etrax100 chipset type when removing the ETRAX_IDE driver. Reported-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-05-20ide: fix race in device_createGreg Kroah-Hartman
There is a race from when a device is created with device_create() and then the drvdata is set with a call to dev_set_drvdata() in which a sysfs file could be open, yet the drvdata will be NULL, causing all sorts of bad things to happen. This patch fixes the problem by using the new function, device_create_drvdata(). Cc: Kay Sievers <kay.sievers@vrfy.org> Acked-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-05-18m68k: macide doesnt check for MacGeert Uytterhoeven
The Macintosh IDE driver (macide) doesn't check whether it's actually running on Mac hardware, causing a crash if it isn't. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-05-14cs5520: disable VDMABartlomiej Zolnierkiewicz
Disable Virtual DMA support for now (it causes system hangs). Thanks to TAKADA Yoshihito for the help with debugging the problem. Reported-by: TAKADA Yoshihito <takada@mbf.nifty.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-05-14ide/Kconfig: couple of fixesBartlomiej Zolnierkiewicz
* Don't ask to enable no longer existing config options ("Use DMA by default when available" and "Special UDMA Feature"). * PIIX host driver doesn't support Victory66 chipset. * "ide0=cmd640_vlb" -> "cmd640.probe_vlb" * "ide=doubler" -> "gayle.doubler" * Amiga IDE doubler support is a feature for gayle host driver not a separate host driver. * Remove Andre's mail. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-05-14alim15x3: remove WDC_ALI15X3 config optionBartlomiej Zolnierkiewicz
There is "wdc_udma" module parameter now. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-05-14alim15x3: add "wdc_udma" module parameterBartlomiej Zolnierkiewicz
Add "wdc_udma" module parameter for allowing UDMA transfers on M1543C-E chipset for WDC disks. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-05-14alim15x3: remove stale warning about ATI RS100 northbridgeBartlomiej Zolnierkiewicz
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-05-14alim15x3: trivial cleanup for ali_set_pio_mode()Bartlomiej Zolnierkiewicz
Remove commented out code and stale comment. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>