hpsa: decrement h->commands_outstanding in fail_all_outstanding_cmds
authorStephen Cameron <stephenmcameron@gmail.com>
Thu, 23 Apr 2015 14:32:11 +0000 (09:32 -0500)
committerJames Bottomley <JBottomley@Odin.com>
Sun, 31 May 2015 18:23:26 +0000 (11:23 -0700)
make tracking of outstanding commands more robust

Reviewed-by: Scott Teel <scott.teel@pmcs.com>
Reviewed-by: Kevin Barnett <kevin.barnett@pmcs.com>
Reviewed-by: Tomas Henzl <thenzl@redhat.com>
Reviewed-by: Hannes Reinecke <hare@Suse.de>
Signed-off-by: Don Brace <don.brace@pmcs.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: James Bottomley <JBottomley@Odin.com>
drivers/scsi/hpsa.c

index ae9d9e17da37d8cc3afd29ec71533a00a8696b2c..d5a5a6413b6db16c411d8cdbdecd105fcfab4f7d 100644 (file)
@@ -6892,6 +6892,7 @@ static void fail_all_outstanding_cmds(struct ctlr_info *h)
                if (refcount > 1) {
                        c->err_info->CommandStatus = CMD_CTLR_LOCKUP;
                        finish_cmd(c);
+                       atomic_dec(&h->commands_outstanding);
                        failcount++;
                }
                cmd_free(h, c);