diff options
author | Don Brace <don.brace@microchip.com> | 2021-02-15 23:26:57 +0100 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2021-02-23 04:43:48 +0100 |
commit | f749d8b7a9896bc6e5ffe104cc64345037e0b152 (patch) | |
tree | 03d73fa2eae33a9d49ba8d597912cd3e58476751 /drivers/scsi/hpsa_cmd.h | |
parent | scsi: sd: Fix Opal support (diff) | |
download | linux-f749d8b7a9896bc6e5ffe104cc64345037e0b152.tar.xz linux-f749d8b7a9896bc6e5ffe104cc64345037e0b152.zip |
scsi: hpsa: Correct dev cmds outstanding for retried cmds
Prevent incrementing device->commands_outstanding for ioaccel command
retries that are driver initiated. If the command goes through the retry
path, the device->commands_outstanding counter has already accounted for
the number of commands outstanding to the device. Only commands going
through function hpsa_cmd_resolve_events decrement this counter.
- ioaccel commands go to either HBA disks or to logical volumes comprised
of SSDs.
The extra increment is causing device resets to hang.
- Resets wait for all device outstanding commands to complete before
returning.
Replace unused field abort_pending with retry_pending. This is a
maintenance driver so these changes have the least impact/risk.
Link: https://lore.kernel.org/r/161342801747.29388.13045495968308188518.stgit@brunhilda
Tested-by: Joe Szczypek <jszczype@redhat.com>
Reviewed-by: Scott Benesh <scott.benesh@microchip.com>
Reviewed-by: Scott Teel <scott.teel@microchip.com>
Reviewed-by: Tomas Henzl <thenzl@redhat.com>
Signed-off-by: Don Brace <don.brace@microchip.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/hpsa_cmd.h')
-rw-r--r-- | drivers/scsi/hpsa_cmd.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/hpsa_cmd.h b/drivers/scsi/hpsa_cmd.h index 46df2e3ff89b..d126bb877250 100644 --- a/drivers/scsi/hpsa_cmd.h +++ b/drivers/scsi/hpsa_cmd.h @@ -448,7 +448,7 @@ struct CommandList { */ struct hpsa_scsi_dev_t *phys_disk; - int abort_pending; + bool retry_pending; struct hpsa_scsi_dev_t *device; atomic_t refcount; /* Must be last to avoid memset in hpsa_cmd_init() */ } __aligned(COMMANDLIST_ALIGNMENT); |