RE: [PATCH] scsi: relax PAGE LENGTH check for thin provisioning UNMAP support

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

 



In the early 90s, when the SCSI INQUIRY - ANSI Version field had only 2 values, I worked on a host that, because SCSI-1 and SCSI-2 were incompatible, did the following:

If ( ANSI_VERSION == 2 ) {use SCSI-2 protocol} else {use SCSI-1 protocol}

When the first SCSI-3 device came along, this host fell over dead because the SCSI-1 protocol did not work on that SCSI-3 device.  They had to delay support for that device until they fixed their code (change == to >=), and they could NOT support that device in older versions, even thought it would have worked if not for the above "bug".

There are no guarantees about what the T10 committee will do to that page in the draft, or in any future versions of SBC.

In reality, any value > 32 (20h) will mean that you probably have all the data you want to look at today.  YES, any device that puts such a small value into the page length field is non-compliant (and therefore, the contents of those fields may be non-compliant as well).  So, allowing a value less than 3Ch would be risky.

But, a compliant SBC-4/5/... device might put 200 (or other > 3Ch value) into that field, while the existing values all still remain valid.  It would be a shame to disable feature "A" just because a device added the implementation of feature "X".

Future proofing is never guaranteed, but it is good to at least try.

	Fred

-----Original Message-----
From: Mike Snitzer [mailto:snitzer@xxxxxxxxxx] 
Sent: Thursday, May 06, 2010 7:24 AM
To: Martin K. Petersen
Cc: linux-scsi@xxxxxxxxxxxxxxx; Christoph Hellwig; Knight, Frederick
Subject: Re: [PATCH] scsi: relax PAGE LENGTH check for thin provisioning UNMAP support

On Thu, May 6, 2010 at 12:28 AM, Martin K. Petersen
<martin.petersen@xxxxxxxxxx> wrote:
>>>>>> "Mike" == Mike Snitzer <snitzer@xxxxxxxxxx> writes:
>
> Mike> Thin Provisioning fields are assumed available in the BLOCK LIMITS
> Mike> VPD page if PAGE LENGTH is 0x3c.  The BLOCK LIMITS VPD page may be
> Mike> extended over time.  Allow for the possibility that the PAGE
> Mike> LENGTH exceeds 0x3c.
>
> SBC3 states that:
>
> "If the device server supports thin provisioning, then the device server
> shall set the PAGE LENGTH field to 3Ch."
>
> That's a "shall".  That's a non-negotiable requirement in standards
> speak.  And besides, only half of that mandated page length is currently
> spoken for.  So I wonder what motivated your change?  Do you have any
> examples of devices with a bigger page length?

I forgot to cc Fred Knight on my patch, but Fred was/is attending the
most recent T10.  Based on the discussions there, and me having shared
with him the PAGE LENGTH == 0x3c constraint before, he sent me private
mail sharing that SBC3 is not yet final nor approved.  And that at
this recent T10 meeting they were talking of extending the BLOCK
LIMITS VPD.  If not for SBC3 then for SBC4.

So coming full circle: why impose a precise PAGE LENGTH of 0x3c?
It'll only cause compatibility problems for us down the road when new
devices do come to market.

Mike
--
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