linux/drivers/usb/storage
Alan Stern 21c13a4f7b usb-storage: redo incorrect reads
Some USB mass-storage devices have bugs that cause them not to handle
the first READ(10) command they receive correctly.  The Corsair
Padlock v2 returns completely bogus data for its first read (possibly
it returns the data in encrypted form even though the device is
supposed to be unlocked).  The Feiya SD/SDHC card reader fails to
complete the first READ(10) command after it is plugged in or after a
new card is inserted, returning a status code that indicates it thinks
the command was invalid, which prevents the kernel from retrying the
read.

Since the first read of a new device or a new medium is for the
partition sector, the kernel is unable to retrieve the device's
partition table.  Users have to manually issue an "hdparm -z" or
"blockdev --rereadpt" command before they can access the device.

This patch (as1470) works around the problem.  It adds a new quirk
flag, US_FL_INVALID_READ10, indicating that the first READ(10) should
always be retried immediately, as should any failing READ(10) commands
(provided the preceding READ(10) command succeeded, to avoid getting
stuck in a loop).  The patch also adds appropriate unusual_devs
entries containing the new flag.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Tested-by: Sven Geggus <sven-usbst@geggus.net>
Tested-by: Paul Hartman <paul.hartman+linux@gmail.com>
CC: Matthew Dharm <mdharm-usb@one-eyed-alien.net>
CC: <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-06-07 09:05:42 -07:00
..
alauda.c
cypress_atacb.c
datafab.c
debug.c
debug.h
ene_ub6250.c
freecom.c
initializers.c
initializers.h
isd200.c [SCSI] usb-storage: do not increment cmd->serial_number 2011-05-01 10:23:09 -05:00
jumpshot.c
karma.c
Kconfig
libusual.c
Makefile
onetouch.c
option_ms.c
option_ms.h
protocol.c
protocol.h
realtek_cr.c
scsiglue.c
scsiglue.h
sddr09.c
sddr55.c
shuttle_usbat.c
sierra_ms.c
sierra_ms.h
transport.c usb-storage: redo incorrect reads 2011-06-07 09:05:42 -07:00
transport.h
uas.c
unusual_alauda.h
unusual_cypress.h
unusual_datafab.h
unusual_devs.h usb-storage: redo incorrect reads 2011-06-07 09:05:42 -07:00
unusual_ene_ub6250.h
unusual_freecom.h
unusual_isd200.h
unusual_jumpshot.h
unusual_karma.h
unusual_onetouch.h
unusual_realtek.h usb-storage: fix up the unusual_realtek device list 2011-05-17 11:56:28 -07:00
unusual_sddr09.h
unusual_sddr55.h
unusual_usbat.h
usb.c usb-storage: redo incorrect reads 2011-06-07 09:05:42 -07:00
usb.h usb-storage: redo incorrect reads 2011-06-07 09:05:42 -07:00
usual-tables.c