[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.44L0.1207031618450.29825-100000@netrider.rowland.org>
Date: Tue, 3 Jul 2012 16:25:05 -0400 (EDT)
From: Alan Stern <stern@...land.harvard.edu>
To: James Bottomley <James.Bottomley@...senPartnership.com>
cc: Matthew Wilcox <matthew@....cx>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Hans de Goede <hdegoede@...hat.com>,
Ben Hutchings <ben@...adent.org.uk>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"stable@...r.kernel.org" <stable@...r.kernel.org>,
"akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
"alan@...rguk.ukuu.org.uk" <alan@...rguk.ukuu.org.uk>,
Matthew Dharm <mdharm-usb@...-eyed-alien.net>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
linux-scsi <linux-scsi@...r.kernel.org>
Subject: Re: [ 38/48] SCSI & usb-storage: add try_rc_10_first flag
On Wed, 4 Jul 2012, James Bottomley wrote:
> > The reason for the try_rc_10_first flag is that some devices return
> > bogus data in response to RC16. Like, an 800 GB device claiming to
> > have 3 exabytes.
>
> So we could easily send both and only believe RC10 if the device is
> under 2TB.
More precisely, if RC10 indicates the device is under 2 TB then ignore
the RC16 capacity. Or maybe issue a warning if it disagrees with the
RC10 capacity.
> However, what about all the extra flags we read out of RC16,
> like trim, large sector size and DIF capability? If the device lies
> about its capacity, won't we get bogus values for those as well, which
> is going to cause other screw ups?
That seems quite likely. I don't know the answer for any individual
cases, however.
For the greatest safety, I suppose we could disbelieve all the fields
in the RC16 response if the RC16 capacity disagrees with the RC10
capacity and the RC10 capacity is under 2 TB.
Alan Stern
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists