Commit 7ea3e77
scsi: hisi_sas: Rollback some operations if FLR failed
We obtain the semaphore and set HISI_SAS_RESETTING_BIT in
hisi_sas_reset_prepare_v3_hw(), block the scsi host and set
HISI_SAS_REJECT_CMD_BIT in hisi_sas_controller_reset_prepare(), released
them in hisi_sas_controller_reset_done(). However, if the HW reset failure
in FLR results in early return, the semaphore and flag bits will not be
release.
Rollback some operations including clearing flags / releasing semaphore
when FLR is failed.
Fixes: e5ea480 ("scsi: hisi_sas: Implement handlers of PCIe FLR for v3 hw")
Signed-off-by: Yihang Li <liyihang9@huawei.com>
Signed-off-by: Xiang Chen <chenxiang66@hisilicon.com>
Link: https://lore.kernel.org/r/1702525516-51258-5-git-send-email-chenxiang66@hisilicon.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>1 parent 8dd1029 commit 7ea3e77
1 file changed
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4968 | 4968 | | |
4969 | 4969 | | |
4970 | 4970 | | |
| 4971 | + | |
4971 | 4972 | | |
4972 | 4973 | | |
4973 | 4974 | | |
| |||
4976 | 4977 | | |
4977 | 4978 | | |
4978 | 4979 | | |
| 4980 | + | |
| 4981 | + | |
| 4982 | + | |
| 4983 | + | |
4979 | 4984 | | |
4980 | 4985 | | |
4981 | 4986 | | |
| |||
0 commit comments