Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
scsi: Add intermediate STARGET_REMOVE state to scsi_target_state
Add intermediate STARGET_REMOVE state to scsi_target_state to avoid running into the BUG_ON() in scsi_target_reap(). The STARGET_REMOVE state is only valid in the path from scsi_remove_target() to scsi_target_destroy() indicating this target is going to be removed. This re-fixes the problem introduced in commits bc3f02a ("[SCSI] scsi_remove_target: fix softlockup regression on hot remove") and 4099819 ("scsi: restart list search after unlock in scsi_remove_target") in a more comprehensive way. [mkp: Included James' fix for scsi_target_destroy()] Signed-off-by: Johannes Thumshirn <[email protected]> Fixes: 4099819 Cc: [email protected] Reported-by: Sergey Senozhatsky <[email protected]> Tested-by: Sergey Senozhatsky <[email protected]> Reviewed-by: Ewan D. Milne <[email protected]> Reviewed-by: Hannes Reinecke <[email protected]> Reviewed-by: James Bottomley <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
- Loading branch information