usb-storage/SCSI: Add broken_fua blacklist flag

Some buggy JMicron USB-ATA bridges don't know how to translate the FUA
bit in READs or WRITEs.  This patch adds an entry in unusual_devs.h
and a blacklist flag to tell the sd driver not to use FUA.

Signed-off-by: Alan Stern <[email protected]>
Reported-by: Michael Büsch <[email protected]>
Tested-by: Michael Büsch <[email protected]>
Acked-by: James Bottomley <[email protected]>
CC: Matthew Dharm <[email protected]>
CC: <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
Alan Stern 2014-06-30 11:04:21 -04:00 • committed by Greg Kroah-Hartman
commit b14bf2d0c0
5 changed files with 19 additions and 2 deletions

View file

@ -256,6 +256,10 @@ static int slave_configure(struct scsi_device *sdev)
if (us->fflags & US_FL_WRITE_CACHE)
sdev->wce_default_on = 1;
/* A few buggy USB-ATA bridges don't understand FUA */
if (us->fflags & US_FL_BROKEN_FUA)
sdev->broken_fua = 1;
} else {
/* Non-disk-type devices don't need to blacklist any pages

View file

@ -1936,6 +1936,13 @@ UNUSUAL_DEV( 0x14cd, 0x6600, 0x0201, 0x0201,
USB_SC_DEVICE, USB_PR_DEVICE, NULL,
US_FL_IGNORE_RESIDUE ),
/* Reported by Michael Büsch <[email protected]> */
UNUSUAL_DEV( 0x152d, 0x0567, 0x0114, 0x0114,
"JMicron",
"USB to ATA/ATAPI Bridge",
USB_SC_DEVICE, USB_PR_DEVICE, NULL,
US_FL_BROKEN_FUA ),
/* Reported by Alexandre Oliva <[email protected]>
* JMicron responds to USN and several other SCSI ioctls with a
* residue that causes subsequent I/O requests to fail. */