summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sd_dif.c
diff options
context:
space:
mode:
authorJames Bottomley <James.Bottomley@HansenPartnership.com>2009-01-02 10:42:21 -0600
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2009-01-05 08:54:11 -0600
commit4f5299ac4e3a03d5c596c00d726fa932c600609d (patch)
treeab303d64c6df361fff4531801eaaedd9c473ea42 /drivers/scsi/sd_dif.c
parenta234b1103f7df35eacb1de7a9d15a636046e263b (diff)
downloadop-kernel-dev-4f5299ac4e3a03d5c596c00d726fa932c600609d.zip
op-kernel-dev-4f5299ac4e3a03d5c596c00d726fa932c600609d.tar.gz
[SCSI] scsi_lib: don't decrement busy counters when inserting commands
A bug was introduced by commit b60af5b0adf0da24c673598c8d3fb4d4189a15ce Author: Alan Stern <stern@rowland.harvard.edu> Date: Mon Nov 3 15:56:47 2008 -0500 [SCSI] simplify scsi_io_completion() because the simplification uses scsi_queue_insert(). The problem with this function is that it expects to be called from the completion path while the command is still outstanding, so it decrements the device and host busy counts to do the requeue. The problem is that scsi_io_completion() is a path executed well after these counts have *already* been decremented, leading to a double decrement if the command goes down any error path leading to ACTION_DELAYED_RETRY. The fix is to allow a private function __scsi_queue_insert() with a flag to say whether the busy counters should be decremented. This is made static to scsi_lib.c to discourage other use. Reported-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/sd_dif.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud