On Fri, 5 Nov 2021 17:10:47 -0500, Mike Christie wrote:
We can race where iscsi_session_recovery_timedout has woken up the error
handler thread and it's now setting the devices to offline, and
session_recovery_timedout's call to scsi_target_unblock is also trying to
set the device's state to transport-offline. We can then get a mix of
states.
For the case where we can't relogin we want the devices to be in
transport-offline so when we have repaired the connection
__iscsi_unblock_session can set the state back to running. So this patch
has us set the device state then call into libiscsi to wake up the error
handler.
[...]
Applied to 5.16/scsi-fixes, thanks!
[1/2] iscsi: Unblock session then wake up error handler
https://git.kernel.org/mkp/scsi/c/a0c2f8b6709a
[2/2] scsi: Fix hang when device state is set via sysfs
https://git.kernel.org/mkp/scsi/c/4edd8cd4e86d
--
Martin K. Petersen Oracle Linux Engineering