[PATCH] Don't retry SG_IO (REQ_BLOCK_PC) commands.

Patrick Mansfield
2003-11-20T16:56:08Z

On Thu, Nov 20, 2003 at 08:57:15AM -0700, Pat LaVarre wrote:

> This also could matter. In our kernel code who wrongly thinks we gave
> permission to retry SG_IO? This evidence echoes someone else's - may

sg.c looks OK, Dmitri must be using /dev/sdN. We need this fix, patch
is for the current scsi-bugfixes-2.6:

Don't retry SG_IO (REQ_BLOCK_PC) commands.

===== drivers/scsi/sd.c 1.138 vs edited =====
--- 1.138/drivers/scsi/sd.c Fri Oct 17 16:14:06 2003
+++ edited/drivers/scsi/sd.c Thu Nov 20 08:18:34 2003
@@ -347,9 +347,9 @@
*/
SCpnt->transfersize = sdp->sector_size;
SCpnt->underflow = this_count << 9;
+ SCpnt->allowed = SD_MAX_RETRIES;

queue:
- SCpnt->allowed = SD_MAX_RETRIES;
SCpnt->timeout_per_command = timeout;

/*