summaryrefslogtreecommitdiffstats
path: root/drivers
Commit message (Collapse)AuthorAgeFilesLines
* USB: pxa27x_udc: avoid compiler warnings and misbehavior on buggy hardwareEnrico Scholz2010-03-021-6/+13
| | | | | | | | | | | | | hardware reports wrong interrupt. Although such a situation should not happen, the compiler complains about this access. This patch adds a sanity check and generates warning to detect such issues. Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: fix occasional ULPI timeouts with ehci-mxcValentin Longchamp2010-03-021-12/+11
| | | | | | | | | | | | | | On various mxc boards, the intial ULPI reads resulted in a timeout which prevented the transceiver to be identified and thus the ehci device to be probed. Initializing the hardware lines connected to the transceiver (through pdata->init call) before actually enabling clocks and configuring registers in the devices fixes this problem. Signed-off-by: Valentin Longchamp <valentin.longchamp@epfl.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: ftdi_sio: remove support for 5 and 6 data bitsMark Adamson2010-03-021-3/+1
| | | | | | | | | | Removed CS5 and CS6 from data bits since these are not supported in FTDI hardware. Signed-off-by: Mark J. Adamson <mark.adamson@ftdichip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: ftdi_sio: fix initialisation of latency timeoutJohan Hovold2010-03-021-4/+5
| | | | | | | | | | Latency timeout was read but never stored on port probe. When ASYNC_LOW_LATENCY was cleared the device timeout would get set to 0 rather than the default 16ms. Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: serial: fix typo in debug messageJohan Hovold2010-03-021-1/+1
| | | | | | | Fixes confusing "serial_chars_in_buffer = port 0" messages. Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: ftdi_sio: remove obsolete commentJohan Hovold2010-03-021-2/+1
| | | | | | | | We always push characters to ldisc immediately regardless of ASYNC_LOW_LATENCY. Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: ftdi_sio: fix error message on closeJohan Hovold2010-03-021-1/+1
| | | | | | | | Resubmitting read urb fails with -EPERM if completion handler runs while urb is being killed on close. This should not be reported as an error. Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cxacru: increment driver versionSimon Arlott2010-03-021-1/+2
| | | | | | | | | | | | | | Changes: Return an empty string for modulation when there is no connection Fix sysfs unload race conditions Log firmware load process, remove delay Add new configuration interface Remove cxacru-cf.bin Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cxacru: remove cxacru-cf.bin loaderSimon Arlott2010-03-021-28/+3
| | | | | | | | | | | | | | | | | | | | This has never worked properly because wsize passed to cxacru_cm() is incorrectly set to the number of values instead of the data bytes. The maximum number of values that can be set at once is 7 which means the device will not get enough data to work with and none of the configuration values will be used. At least one existing cxacru-cf.bin file contains invalid data which will prevent the modem from syncing properly. Fixing it is likely to break existing systems, and the new sysfs interface for setting configuration parameters can provide the same functionality. A script is provided to convert from the original format. Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cxacru: add write-only sysfs attribute for modem configurationSimon Arlott2010-03-021-1/+75
| | | | | | | | | | | | | | | | | | | The modem can be configured using CM_REQUEST_CARD_DATA_SET, although CM_REQUEST_CARD_DATA_GET does not return any data. Tested by setting the modulation (0x0a) option. There is a list of parameters in the following archive, but the meaning of many of them is not well documented: http://sourceforge.net/project/shownotes.php?release_id=301825 This source also indicates that the highest parameter set is 0x4a but this varies by model so an arbitrary limit of 0x7f has been used (the index is a 32-bit integer). Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cxacru: firmware writes on OHCI are slow, log progressSimon Arlott2010-03-021-2/+6
| | | | | | | | | | | | | | | | Firmware writing takes 256ms per 4KB with OHCI, which is very slow compared to 7ms per 4KB with UHCI. Until I have access to a hardware USB analyser it may not be possible to determine why this happens. Instead of appearing to do nothing, log progress when writing firmware and then log the ATM device information when finished. Remove an unnecessary 4 second delay. Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cxacru: document how to interact with the flash memorySimon Arlott2010-03-021-0/+20
| | | | | | | | | | | | | These commands were found by accident... fortunately it still works even if the flash memory is erased, despite having no USB device IDs. Some example sysfs code for raw command access: http://simon.arlott.org/pub/cxacru/raw.c Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cxacru: check device isn't being removed during sysfs callsSimon Arlott2010-03-023-20/+44
| | | | | | | | | | | | | | | | | It is possible for usb_get_intfdata() to return NULL if sysfs is accessed while the module is being unloaded or the device is being removed. Move the access code to an inline function in usbatm.h, and return -ENODEV if any of the pointers are NULL. It should not be possible for the instance data or atm device to be invalid until after unbind() completes and the sysfs attributes have been removed. Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cxacru: check data length is not negativeSimon Arlott2010-03-021-1/+1
| | | | | | | | | | | | | | When attempting to read data that is not actually an array of values, the length may be negative which causes an Oops due to a likely access off the end of the data array. This bug should not occur under normal use unless the device returns an invalid response. Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cxacru: return an empty value for modulation if there is no connectionSimon Arlott2010-03-021-2/+2
| | | | | | | | | When there is no connection, return an empty string instead of "0" for the connection modulation. Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: MXC: Add i.MX21 specific USB host controller driver.Martin Fuzzey2010-03-026-0/+2766
| | | | | | | | | This driver is a Full / Low speed only USB host for the i.MX21. Signed-off-by: Martin Fuzzey <mfuzzey@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Merge branch 'davinci-for-linus' of ↵Linus Torvalds2010-03-012-20/+37
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-davinci * 'davinci-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-davinci: (40 commits) DaVinci DM365: Adding support for SPI EEPROM DaVinci DM365: Adding DM365 SPI support DaVinci DM355: Modifications to DM355 SPI support DaVinci: SPI: Adding header file for SPI support. davinci: dm646x: CDCE clocks: davinci_clk converted to clk_lookup davinci: clkdev cleanup: remove clk_lookup wrapper, use clkdev_add_table() DaVinci: DM365: Voice codec support for the DM365 SoC davinci: clock: let clk->set_rate function sleep Add SDA and SCL pin numbers to i2c platform data davinci: da8xx/omap-l1xx: Add EDMA platform data for da850/omap-l138 davinci: build list of unused EDMA events dynamically davinci: Fix edma_alloc_channel api for EDMA_CHANNEL_ANY case davinci: Keep count of channel controllers on a platform davinci: Correct return value of edma_alloc_channel api davinci: add CDCE949 support on DM6467 EVM davinci: add support for CDCE949 clock synthesizer davinci: da850/omap-l138 EVM: register for suspend support davinci: da850/omap-l138: add support for SoC suspend davinci: add power management support DaVinci: DM365: Changing default queue for DM365. ...
| * TI Davinci EMAC : Abstract Buffer address translation logic.Sriramakrishnan2010-02-041-17/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | When programming the DMA engine, the next pointers must be programmed with physical address as seen from the DMA master address space. This address may be different from physical address of the buffer RAM area. This patch abstracts the buffer address translation logic. Signed-off-by: Sriramakrishnan <srk@ti.com> Acked-by: Chaithrika U S <chaithrika@ti.com> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
| * TI Davinci EMAC : add platform specific interrupt enable/disable logic.Sriramakrishnan2010-02-041-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | On certain SOCs, the EMAC controller is interfaced with a wrapper logic for handling interrupts. This patch implements a platform specific hook to cater to platforms that require custom interrupt handling logic Signed-off-by: Sriramakrishnan <srk@ti.com> Acked-by: Chaithrika U S <chaithrika@ti.com> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
| * TI Davinci EMAC : Re-use driver for other platforms.Sriramakrishnan2010-02-042-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | The davinci EMAC peripheral is also available on other TI platforms -notably TI AM3517 SoC. This patch modifies the config option and the platform structure header files so that the driver can be reused on non-davinci platforms as well. Signed-off-by: Sriramakrishnan <srk@ti.com> Acked-by: Chaithrika U S <chaithrika@ti.com> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
* | Merge branch 'upstream-linus' of ↵Linus Torvalds2010-03-0146-414/+658
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev * 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev: (38 commits) sata_via: Delay on vt6420 when starting ATAPI DMA write ata: Detect Delkin Devices compact flash pata_efar: Enable parallel scanning pata_atiixp: enable parallel scan [libata] pata_atiixp: add locking for parallel scanning [libata] pata_efar: add locking for parallel scanning libata: Pass host flags into the pci helper [libata] pata_marvell: CONFIG_AHCI is really CONFIG_SATA_AHCI libata: Allow pata_legacy to be built on non-ISA but PCI systems pata_pdc202xx_old: fix UDMA mode for PDC2026x chipsets pata_pdc202xx_old: fix UDMA mode for Promise UDMA33 cards [libata] pata_at91: fix backslash-continued string pata_via: store UDMA masks in via_isa_bridges table pata_via: fix address setup timings underlocking pata_serverworks: fix error message pata_serverworks: fix PIO setup for the second channel pata_efar: fix secondary port support pata_cypress: fix PIO timings underclocking pata_cs5535: use correct values for PIO1 and PIO2 data timings pata_cmd64x: remove unused definitions ...
| * | sata_via: Delay on vt6420 when starting ATAPI DMA writeBart Hartgers2010-03-011-1/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When writing a disc on certain lite-on dvd-writers (also rebadged as optiarc/LG/...) connected to a vt6420, the ATAPI CDB ends up in the datastream and on the disc, causing silent corruption. Delaying between sending the CDB and starting DMA seems to prevent this. I do not know if there are burners that do not suffer from this, but the patch should be safe for those as well. There are many reports of this issue, but AFAICT no solution was found before. For example: http://lkml.indiana.edu/hypermail/linux/kernel/0802.3/0561.html Signed-off-by: Bart Hartgers <bart.hartgers@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_efar: Enable parallel scanningAlan Cox2010-03-011-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | Again originally proposed by Bartlomiej but this does it by using the generic helper logic instead. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_atiixp: enable parallel scanAlan Cox2010-03-011-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was originally proposed by Bartlomiej but as a device specific expansion of the init_one function rather than making the helper more generic. Enable the parallel scan via the generic flags. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | [libata] pata_atiixp: add locking for parallel scanningBartlomiej Zolnierkiewicz2010-03-011-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is similar change as commit 60c3be3 for ata_piix host driver and while pata_atiixp doesn't enable parallel scan yet the race could probably also be triggered by requesting re-scanning of both ports at the same time using SCSI sysfs interface. [Ported to current tree without other patch dependancies by Alan Cox] Original is Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> This one is Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | [libata] pata_efar: add locking for parallel scanningBartlomiej Zolnierkiewicz2010-03-011-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add clearing of UDMA enable bit also for PIO modes and then add extra locking for parallel scanning. This is similar change as commit 60c3be3 for ata_piix host driver and while pata_efar doesn't enable parallel scan yet the race could probably also be triggered by requesting re-scanning of both ports at the same time using SCSI sysfs interface. [Ported to current kernel without other patch dependancies by Alan Cox] Original is Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> This one is Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | libata: Pass host flags into the pci helperAlan Cox2010-03-0139-40/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows parallel scan and the like to be set without having to stop using the existing full helper functions. This patch merely adds the argument and fixes up the callers. It doesn't undo the special cases already in the tree or add any new parallel callers. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | [libata] pata_marvell: CONFIG_AHCI is really CONFIG_SATA_AHCIChristoph Egger2010-03-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The marvell driver comtains a fallback to ahci for the sata ports which is incorrectly checked as CONFIG_AHCI while the only AHCI config item is actually called SATA_AHCI (which also sounds sensible considering it's a fallback for the sata ports). Signed-off-by: Christoph Egger <siccegge@stud.informatik.uni-erlangen.de> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | libata: Allow pata_legacy to be built on non-ISA but PCI systemsAlan Cox2010-03-011-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | This is needed for some unsupported hardware setups on strange 64bit mainboards where crazy stuff has been done like putting flash ata adapters on the LPC bus, or where the real hardware is hidden/confused. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_pdc202xx_old: fix UDMA mode for PDC2026x chipsetsBartlomiej Zolnierkiewicz2010-03-011-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PDC2026x chipsets need the same treatment as PDC20246 one. This is completely untested but will hopefully fix UDMA issues that people have been reporting against pata_pdc202xx_old for the last couple of years. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_pdc202xx_old: fix UDMA mode for Promise UDMA33 cardsBartlomiej Zolnierkiewicz2010-03-011-1/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Monday 04 January 2010 02:30:24 pm Russell King wrote: > Found the problem - getting rid of the read of the alt status register > after the command has been written fixes the UDMA CRC errors on write: > > @@ -676,7 +676,8 @@ void ata_sff_exec_command(struct ata_port *ap, const struct > ata_taskfile *tf) > DPRINTK("ata%u: cmd 0x%X\n", ap->print_id, tf->command); > > iowrite8(tf->command, ap->ioaddr.command_addr); > - ata_sff_pause(ap); > + ndelay(400); > +// ata_sff_pause(ap); > } > EXPORT_SYMBOL_GPL(ata_sff_exec_command); > > > This rather makes sense. The PDC20247 handles the UDMA part of the > protocol. It has no way to tell the PDC20246 to wait while it suspends > UDMA, so that a normal register access can take place - the 246 ploughs > on with the register access without any regard to the state of the 247. > > If the drive immediately starts the UDMA protocol after a write to the > command register (as it probably will for the DMA WRITE command), then > we'll be accessing the taskfile in the middle of the UDMA setup, which > can't be good. It's certainly a violation of the ATA specs. Fix it by adding custom ->sff_exec_command method for UDMA33 chipsets. Debugged-by: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | [libata] pata_at91: fix backslash-continued stringJeff Garzik2010-03-011-2/+2
| | | | | | | | | | | | | | | | | | Noticed and rough patch by Joe Perches. Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_via: store UDMA masks in via_isa_bridges tableBartlomiej Zolnierkiewicz2010-03-011-110/+94
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * store UDMA masks in via_isa_bridges[] and while at it make "flags" field to be u8 instead of u16 * convert the driver to use UDMA masks from via_isa_bridges[] * remove no longer needed VIA_UDMA* defines Make some minor documentation and CodingStyle fixes while at it. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_via: fix address setup timings underlockingBartlomiej Zolnierkiewicz2010-03-011-2/+2
| | | | | | | | | | | | | | | | | | | | | Correct via_do_set_mode() documentation while at it. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_serverworks: fix error messageBartlomiej Zolnierkiewicz2010-03-011-1/+1
| | | | | | | | | | | | | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_serverworks: fix PIO setup for the second channelBartlomiej Zolnierkiewicz2010-03-011-1/+2
| | | | | | | | | | | | | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_efar: fix secondary port supportBartlomiej Zolnierkiewicz2010-03-011-2/+2
| | | | | | | | | | | | | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_cypress: fix PIO timings underclockingBartlomiej Zolnierkiewicz2010-03-011-4/+6
| | | | | | | | | | | | | | | | | | | | | | | | Timing registers should be programmed with the desired number of clocks minus one clock. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_cs5535: use correct values for PIO1 and PIO2 data timingsBartlomiej Zolnierkiewicz2010-03-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | There shouldn't be any problems with it as IDE cs5535 host driver has been using those values for years and they match values given in the (publicly available) datasheet. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_cmd64x: remove unused definitionsBartlomiej Zolnierkiewicz2010-03-011-11/+1
| | | | | | | | | | | | | | | | | | | | | s/ARTIM2/ARTTIM23/ in cmd648_bmdma_stop() while at it Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_cmd64x: cmd648_bmdma_stop() fixBartlomiej Zolnierkiewicz2010-03-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Clear the primary channel pending interrupt bit instead of the reserved one. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_cmd64x: fix handling of address setup timingsBartlomiej Zolnierkiewicz2010-03-011-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | Account for the requirements of the DMA mode currently used by the pair device. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_cmd64x: fix PIO setupBartlomiej Zolnierkiewicz2010-03-011-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Fix incorrect handling of recovery clocks value == 16 resulting in overclocked recovery timings & potentially underclocked active timings. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | pata_ali: documentation fixesBartlomiej Zolnierkiewicz2010-03-011-5/+3
| | | | | | | | | | | | | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | libata: fix CFA handling in ide_timing_compute()Bartlomiej Zolnierkiewicz2010-03-011-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | Use standard cycle timing for CFA PIO5 and PIO6 modes. Based on commit 74638c8 for IDE subsystem. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | sata_via: Correctly setup PIO/DMA for pata slave on vt6421.Bart Hartgers2010-03-011-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before only the timings for master were set. Datasheet can be found here: ftp://ftp.vtbridge.org/Docs/Storage/DS_VT6421A_100_CCPL.PDF Surprisingly, a slave drive works without this patch. According to the datasheet, the controller by default derives the DMA mode from the Set Features command issued to a drive. Not sure about the PIO timings, though. The real problem is that the timings for the master effectively are the ones tuned for the slave. If these support different UDMA-settings, there is trouble, especially when the slave supports a higher UDMA than the master. Anyhow, using the same mechanism for both master and slave seems like a good idea. Signed-off-by: Bart Hartgers <bart.hartgers@gmail.com> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | libata: make functions/variables staticRobert Hancock2010-03-012-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | Make some variables in ahci and a function in pata_pcmcia static, as found using sparse. Signed-off-by: Robert Hancock <hancockrwd@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | libata: implement spurious irq handling for SFF and apply it to piixTejun Heo2010-03-012-8/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Traditional IDE interface sucks in that it doesn't have a reliable IRQ pending bit, so if the controller raises IRQ while the driver is expecting it not to, the IRQ won't be cleared and eventually the IRQ line will be killed by interrupt subsystem. Some controllers have non-standard mechanism to indicate IRQ pending so that this condition can be detected and worked around. This patch adds an optional operation ->sff_irq_check() which will be called for each port from the ata_sff_interrupt() if an unexpected interrupt is received. If the operation returns %true, ->sff_check_status() and ->sff_irq_clear() will be cleared for the port. Note that this doesn't mark the interrupt as handled so it won't prevent IRQ subsystem from killing the IRQ if this mechanism fails to clear the spurious IRQ. This patch also implements ->sff_irq_check() for ata_piix. Note that this adds slight overhead to shared IRQ operation as IRQs which are destined for other controllers will trigger extra register accesses to check whether IDE interrupt is pending but this solves rare screaming IRQ cases and for some curious reason also helps weird BIOS related glitch on Samsung n130 as reported in bko#14314. http://bugzilla.kernel.org/show_bug.cgi?id=14314 * piix_base_ops dropped as suggested by Sergei. * Spurious IRQ detection doesn't kick in anymore if polling qc is in progress. This provides less protection but some controllers have possible data corruption issues if the wrong register is accessed while a command is in progress. Signed-off-by: Tejun Heo <tj@kernel.org> Reported-by: Johannes Stezenbach <js@sig21.net> Reported-by: Hans Werner <hwerner4@gmx.de> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | libata: cleanup ata_sff_interrupt()Tejun Heo2010-03-011-10/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | host->ports[i] is never NULL if i < host->n_ports and non-NULL return from ata_qc_from_tag() guarantees that the returned qc is active. Drop unnecessary tests. Superflous () dropped as suggested by Sergei. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
| * | ata_piix: IDE Mode SATA patch for Intel Cougar Point DeviceIDsSeth Heasley2010-03-011-0/+8
| | | | | | | | | | | | | | | Signed-off-by: Seth Heasley <seth.heasley@intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
OpenPOWER on IntegriCloud