summaryrefslogtreecommitdiff
path: root/drivers/scsi/bnx2i
diff options
context:
space:
mode:
authorNilesh Javali <nilesh.javali@qlogic.com>2015-05-19 05:51:58 -0400
committerJames Bottomley <JBottomley@Odin.com>2015-06-02 17:15:24 -0700
commit35843048e7e979df3b7b9f2ad49e21797a11386b (patch)
treed5a3da6137c62296738dd1b0c690378f7476b28c /drivers/scsi/bnx2i
parent5fc956c243852608db1e4ef74b92bb4445313912 (diff)
downloadlwn-35843048e7e979df3b7b9f2ad49e21797a11386b.tar.gz
lwn-35843048e7e979df3b7b9f2ad49e21797a11386b.zip
bnx2i: Fix call trace while device reset
The driver waits for command completion event while cleanup of task within the frwd lock and back locks. The frwd lock was still held which caused the call trace while issuing a device reset. Release the frwd lock along with the back lock to avoid waiting in the lock context. Signed-off-by: Nilesh Javali <nilesh.javali@qlogic.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <JBottomley@Odin.com>
Diffstat (limited to 'drivers/scsi/bnx2i')
-rw-r--r--drivers/scsi/bnx2i/bnx2i_iscsi.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/scsi/bnx2i/bnx2i_iscsi.c b/drivers/scsi/bnx2i/bnx2i_iscsi.c
index 1b8a9710e701..72894378ffcf 100644
--- a/drivers/scsi/bnx2i/bnx2i_iscsi.c
+++ b/drivers/scsi/bnx2i/bnx2i_iscsi.c
@@ -1173,8 +1173,10 @@ static void bnx2i_cleanup_task(struct iscsi_task *task)
bnx2i_send_cmd_cleanup_req(hba, task->dd_data);
spin_unlock_bh(&conn->session->back_lock);
+ spin_unlock_bh(&conn->session->frwd_lock);
wait_for_completion_timeout(&bnx2i_conn->cmd_cleanup_cmpl,
msecs_to_jiffies(ISCSI_CMD_CLEANUP_TIMEOUT));
+ spin_lock_bh(&conn->session->frwd_lock);
spin_lock_bh(&conn->session->back_lock);
}
bnx2i_iscsi_unmap_sg_list(task->dd_data);