* [PATCH] call correct scsi_done function in scsi_dispatch_cmd
@ 2005-04-30 0:20 Mike Christie
0 siblings, 0 replies; only message in thread
From: Mike Christie @ 2005-04-30 0:20 UTC (permalink / raw)
To: linux-scsi
[-- Attachment #1: Type: text/plain, Size: 406 bytes --]
scsi_dispatch_cmd currently calls scsi_done when the device is in the
SDEV_DEL state, but at this point the command has not had a timer added
to it (this is done a couple lines down) so scsi_done just returns and
the command is lost. The attached patch made against 2.6.12-rc3 calls
__scsi_done in this case so the comamnd will be returned upwards.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
[-- Attachment #2: call-correct-done.patch --]
[-- Type: text/x-patch, Size: 465 bytes --]
--- linux-2.6.12-rc3/drivers/scsi/scsi.c.orig 2005-04-29 17:05:01.323994458 -0700
+++ linux-2.6.12-rc3/drivers/scsi/scsi.c 2005-04-29 17:05:18.406145282 -0700
@@ -542,7 +542,7 @@ int scsi_dispatch_cmd(struct scsi_cmnd *
* that the device is no longer present */
cmd->result = DID_NO_CONNECT << 16;
atomic_inc(&cmd->device->iorequest_cnt);
- scsi_done(cmd);
+ __scsi_done(cmd);
/* return 0 (because the command has been processed) */
goto out;
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-04-30 0:20 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-04-30 0:20 [PATCH] call correct scsi_done function in scsi_dispatch_cmd Mike Christie
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox