scsi: iscsi: Get ref to conn during reset handling
authorMike Christie <michael.christie@oracle.com>
Tue, 25 May 2021 18:18:05 +0000 (13:18 -0500)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 2 Jun 2021 05:28:21 +0000 (01:28 -0400)
commitfda290c5ae98b591797c96e55a2cfbd30d46a706
tree1c78c0d9f7e9be96fd432b33273e09b3a84d7f3b
parentd39df158518ccc3bf24ee18082b5e100c8f014aa
scsi: iscsi: Get ref to conn during reset handling

The comment in iscsi_eh_session_reset is wrong and we don't wait for the
EH to complete before tearing down the conn. This has us get a ref to the
conn when we are not holding the eh_mutex/frwd_lock so it does not get
freed from under us.

Link: https://lore.kernel.org/r/20210525181821.7617-13-michael.christie@oracle.com
Reviewed-by: Lee Duncan <lduncan@suse.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/libiscsi.c