Well, I've already done that -- notice that we don't use START_STOP
anymore...

EVPD INQUIRY, INQUIRY for bytes != 36, and MODE_SENSE are big offenders.

But, EVPD INQUIRY is something that's a problem.  Getting rid of it isn't
easy -- someone put it in there because they wanted/needed the data.

INQUIRY != 36 bytes has been discussed before.  Since low-level drivers
snoop the data past 36-bytes, we can't completely get rid of this -- tho I
think this really means that the LLDD need fixing.

MODE_SENSE is something that Linux uses to check for write-protect status.
I could chuck the entire thing, but then we would assume write-enabled for
all disk-like media.

Note that not all of these fall into the 'not-well tested' category.
Certainly, INQUIRY != 36 is something that we blacklist (for having a long
history of problems).  MODE_SENSE doesn't have any historical problems that
I know about.  EVPD certainly hasn't had much testing.... but can I just
get rid of it then?

Matt

On Sun, Mar 23, 2003 at 05:58:43PM -0800, Linus Torvalds wrote:
> 
> On Sun, 23 Mar 2003, Matthew Dharm wrote:
> 
> > On Sun, Mar 23, 2003 at 07:26:09PM -0600, James Bottomley wrote:
> > > The problem with this type of approach is that there's no unified list
> > > of "known good" commands that actually let you operate a device.  The
> > > SCSI and ATAPI standards have been gradually deprecating the commands
> > > that SCSI-1 (and sometimes even SCSI-2) regard as mandatory
> > > (READ_6/WRITE_6 springs to mind).
> > 
> > Actually, there is such a list.  It's the commands that the 'popular OS'
> > uses, and I have a pretty good idea exactly what those are.  That's why my
> > original approach was to just cut out the commands that fell outside that
> > definition.
> 
> Now _this_ is actually a valid approach, but then I would suggest you do
> what Andries Brouwer has done a few times: just make the Linux SCSI layer
> not use those commands _at_all_ - and instead use the sequences of
> commands that "that other OS" uses. That fixed a lot of the smartmedia 
> problems I used to have - doing simple things like _not_ trying to spin up 
> devices that reported themselves to be already active etc.
> 
> This isn't an "emulated vs native" thing, btw, it's a much more generic 
> "don't use commands that haven't gotten much testing" approach, and should 
> probably be done both on emulated devices _and_ on "real" SCSI devices.
> 
> After all, "real" devices have problems too - I bet a lot of our
> historical SCSI black-lists have been due to exactly the same issues you
> see on emulated USB, with devices just reacting badly to command sequences
> that they didn't expect and that hadn't been tested by the manufacturer.
> 
>                       Linus

-- 
Matthew Dharm                              Home: [EMAIL PROTECTED] 
Maintainer, Linux USB Mass Storage Driver

I'm seen in many forms.  Now open your mouth.  It's caffeine time.
                                        -- Cola Man to Greg
User Friendly, 10/28/1998

Attachment: pgp00000.pgp
Description: PGP signature

Reply via email to