Re: [PATCH] USB enclosures seem to require read(16) with >2TB drives

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

 



On Fri, 2012-11-09 at 16:33 +0000, Elliott, Robert (Server Storage)
wrote:
> I recommend broadening this patch.  T10 is discussing making READ
> (10), WRITE (10), etc. obsolete in SBC-4 in favor of their 16-byte CDB
> counterparts.  
> 
> The algorithm should be:
> 1. During discovery, determine if 16-byte CDBs are supported.  There
> are several ways to determine this:
> a) REPORT SUPPORTED OPERATION CODES command succeeds and reports that
> READ (16) et al are supported.
> b) READ (16) command specifying a Transfer Length of zero succeeds.
> c) READ CAPACITY (16) command succeeds and reports that the capacity
> is > 2 TiB.
> d) (future) INQUIRY command succeeds fetching the Block Device
> Characteristics VPD page and notices a new field added by the SBC-4
> simplified SCSI feature set proposal.

When you consider the problem that we must support all devices (which
means the older ones as well), including the annoying USB ones which
crash on unexpected commands, you can see that d) is about the only
viable option.

We can also force RC16 if the capacity is over 2^32 blocks, because the
command will be required, so that's probably the place to start.

James

> Since REPORT SUPPORTED OPERATION CODES is optional, it won't always
> work. READ CAPACITY (16) used to be optional for < 2 TiB drives, so it
> won't always work either. READ (16) will always work, but requires the
> drive to be spun up beforehand (e.g., with START STOP UNIT).
>  
> 2. if 16-byte CDBs are supported, then use them; only drop down to
> 10-byte CDBs if 16-byte CDBs are unavailable.  Don't make the decision
> by comparing the LBA on every IO.
> 


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


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux