Commit fac8e55
scsi: core: Fix passthrough retry counter handling
Passthrough users will set the scsi_cmnd->allowed value and were expecting
up to $allowed retries. The problem is that before:
commit 6aded12 ("scsi: core: Remove struct scsi_request")
we used to set the retries on the scsi_request then copy them over to
scsi_cmnd->allowed in scsi_setup_scsi_cmnd. With that patch we now set
scsi_cmnd->allowed to 0 in scsi_prepare_cmd and overwrite what the
passthrough user set.
This moves the allowed initialization to after the blk_rq_is_passthrough()
check so it's only done for the non-passthrough path where the ULD
init_command will normally set an allowed value it prefers.
Link: https://lore.kernel.org/r/[email protected]
Fixes: 6aded12 ("scsi: core: Remove struct scsi_request")
Reviewed-by: Christoph Hellwig <[email protected]>
Signed-off-by: Mike Christie <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>1 parent 8f2c964 commit fac8e55
1 file changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1548 | 1548 | | |
1549 | 1549 | | |
1550 | 1550 | | |
1551 | | - | |
1552 | 1551 | | |
1553 | 1552 | | |
1554 | 1553 | | |
| |||
1599 | 1598 | | |
1600 | 1599 | | |
1601 | 1600 | | |
| 1601 | + | |
| 1602 | + | |
1602 | 1603 | | |
1603 | 1604 | | |
1604 | 1605 | | |
| |||
0 commit comments