Re: scsi-sd fails with error "Invalid field in cdb" for SATA-to-USB adapter JMicron

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 19 Nov 2015, Dmitry Katsubo wrote:

> On 2015-11-17 19:18, Alan Stern wrote:
> > That line is completely inappropriate for uas; it applies only to 
> > usb-storage.  Don't add it.
> 
> I got it. My first thought was like you have said (every module uses its
> own structure), but I blindly tried to guess.
> 
> > Here you need to test devinfo->flags & US_FL_BROKEN_FUA.
> 
> Great, that worked!
> 
> scsi host6: uas
> scsi 6:0:0:0: Direct-Access     JMicron  Generic   0116 PQ: 0 ANSI: 6
> sd 6:0:0:0: Attached scsi generic sg2 type 0
> sd 6:0:0:0: [sdb] 312581808 512-byte logical blocks: (160 GB/149 GiB)
> sd 6:0:0:0: [sdb] 4096-byte physical blocks
> sd 6:0:0:0: [sdb] Write Protect is off
> sd 6:0:0:0: [sdb] Mode Sense: 53 00 10 08
> sd 6:0:0:0: [sdb] Disabling FUA
> sd 6:0:0:0: [sdb] Write cache: enabled, read cache: enabled, doesn't
> support DPO or FUA
> sd 6:0:0:0: [sdb] Attached SCSI disk

Good.

> Actually there is an entry in unusual_uas.h but there is a minor difference:
> 
> unusual_uas.h uses  UNUSUAL_DEV(0x152d, 0x0567, 0x0000, 0x9999, ...
> unusual_devs.h uses UNUSUAL_DEV(0x152d, 0x0567, 0x0114, 0x0116, ...
> 
> so uas module captures the wider set of devices (effectively ignores
> bcdDevice). Should it be left like that (then behaviour could be
> different for usb-storage vs uas driver) or it makes sense to align
> these two?

This is something we can never really answer, because it would require 
knowing what bugs the vendors will eliminate in future versions of 
their firmware.

For now I suggest making the minimum necessary changes, even if it 
means the two drivers are out of sync.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux