projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
493ff4e
)
[SCSI] scsi_lib: stricter checks for clearing use_10_for_rw
author
Jens Axboe
<axboe@suse.de>
Tue, 29 Nov 2005 20:03:34 +0000
(21:03 +0100)
committer
James Bottomley
<jejb@mulgrave.(none)>
Wed, 14 Dec 2005 01:11:11 +0000
(18:11 -0700)
Check the asc and ascq for being "invalid command opcode" as well.
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
drivers/scsi/scsi_lib.c
patch
|
blob
|
history
diff --git
a/drivers/scsi/scsi_lib.c
b/drivers/scsi/scsi_lib.c
index ce9d73a292e2a0f273992efd56e7cb7370f2bbc0..1f2782767ca9685b02db14845bff4b4a78c74624 100644
(file)
--- a/
drivers/scsi/scsi_lib.c
+++ b/
drivers/scsi/scsi_lib.c
@@
-884,7
+884,8
@@
void scsi_io_completion(struct scsi_cmnd *cmd, unsigned int good_bytes,
* system where READ CAPACITY failed, we may have read
* past the end of the disk.
*/
- if (cmd->device->use_10_for_rw &&
+ if ((cmd->device->use_10_for_rw &&
+ sshdr.asc == 0x20 && sshdr.ascq == 0x00) &&
(cmd->cmnd[0] == READ_10 ||
cmd->cmnd[0] == WRITE_10)) {
cmd->device->use_10_for_rw = 0;