From: Matthew Dharm <mdharm-kernel@one-eyed-alien.net>
To: Linus Torvalds <torvalds@transmeta.com>,
Alan Cox <alan@lxorguk.ukuu.org.uk>,
Kernel Developer List <linux-kernel@vger.kernel.org>
Subject: PATCH: scsi_scan.c: emulate windows behavior
Date: Tue, 13 Nov 2001 10:21:06 -0800 [thread overview]
Message-ID: <20011113102106.A23110@one-eyed-alien.net> (raw)
[-- Attachment #1.1: Type: text/plain, Size: 987 bytes --]
I would have sworn we already patched this, but now I can find no record of
it.
Attached is a one-liner patch to scsi_scan.c, which changes the length of
the INQUIRY data request from 255 bytes to 36 bytes. This subtle change
makes Linux act more like Win/MacOS and other popular OSes, and reduces
incompatibility with a broad range of out-of-spec devices that will simply
die if asked for more than the required minimum of 36 bytes.
Did we patch this before? I can't find it in the l-k archives, but I'm
almost positive we have. I remeber this because this problem plagues some
USB devices, which just crash if you ask for more than 36 bytes of data.
Patch is attached. Please apply.
Matt
--
Matthew Dharm Home: mdharm-usb@one-eyed-alien.net
Maintainer, Linux USB Mass Storage Driver
G: Let me guess, you started on the 'net with AOL, right?
C: WOW! d00d! U r leet!
-- Greg and Customer
User Friendly, 2/12/1999
[-- Attachment #1.2: scsi_scan.patch --]
[-- Type: text/plain, Size: 404 bytes --]
--- linux/drivers/scsi/scsi_scan.old Tue Nov 13 10:12:19 2001
+++ linux/drivers/scsi/scsi_scan.c Tue Nov 13 10:13:58 2001
@@ -543,7 +543,7 @@
scsi_cmd[1] = 0; /* SCSI_3 and higher, don't touch */
scsi_cmd[2] = 0;
scsi_cmd[3] = 0;
- scsi_cmd[4] = 255;
+ scsi_cmd[4] = 36; /* 36 bytes, just like Win/MacOS */
scsi_cmd[5] = 0;
SRpnt->sr_cmd_len = 0;
SRpnt->sr_data_direction = SCSI_DATA_READ;
[-- Attachment #2: Type: application/pgp-signature, Size: 232 bytes --]
next reply other threads:[~2001-11-13 18:21 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-11-13 18:21 Matthew Dharm [this message]
2001-11-13 19:49 ` Rob Turk
2001-11-13 20:08 ` Matthew Dharm
2001-11-13 18:02 ` Gérard Roudier
2001-11-13 23:26 ` Alan Cox
2001-11-14 1:44 ` Matthew Dharm
2001-11-14 0:45 ` Riley Williams
2001-11-13 22:52 ` Alan Cox
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20011113102106.A23110@one-eyed-alien.net \
--to=mdharm-kernel@one-eyed-alien.net \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®