diff options
author | Anil Veerabhadrappa <anilgv@broadcom.com> | 2009-07-30 00:49:48 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2009-08-22 18:52:11 -0400 |
commit | 534cc9c165017dd29ae0f4458832893dc8033c6f (patch) | |
tree | a531f0ee309e7b69dc3b01c2a6bf35efff77f1fe /drivers/scsi/bnx2i | |
parent | 1d1b88dc01e5fd2b3e2abb7aa42d0f1eca4c33ea (diff) |
[SCSI] bnx2i : Fix command session number jump issue seen during cable pull test
Without the fix bnx2i would fail tt->xmit_task() when link is down and
libiscsi would have already incremented session->cmdsn before calling bnx2i's
xmit_task() entry point and will just return the command to SCSI-ML when
xmit_task() fails. libiscsi does not retract the session->cmdsn as the command
was never sent on wire. It is generally good idea for LLD, bnx2i to accept
the scsi cmnd/nopout and let upper layer timeout and go though normal session
recovery process. When link is down, unsolicited nopout will not be accepted
by bnx2i and connection will never enter recovery state. This fix is required
for MPIO to work corectly
Signed-off-by: Anil Veerabhadrappa <anilgv@broadcom.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/bnx2i')
-rw-r--r-- | drivers/scsi/bnx2i/bnx2i_iscsi.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/scsi/bnx2i/bnx2i_iscsi.c b/drivers/scsi/bnx2i/bnx2i_iscsi.c index 98148f3f3c63..40120a242eff 100644 --- a/drivers/scsi/bnx2i/bnx2i_iscsi.c +++ b/drivers/scsi/bnx2i/bnx2i_iscsi.c | |||
@@ -1160,9 +1160,6 @@ static int bnx2i_task_xmit(struct iscsi_task *task) | |||
1160 | struct bnx2i_cmd *cmd = task->dd_data; | 1160 | struct bnx2i_cmd *cmd = task->dd_data; |
1161 | struct iscsi_cmd *hdr = (struct iscsi_cmd *) task->hdr; | 1161 | struct iscsi_cmd *hdr = (struct iscsi_cmd *) task->hdr; |
1162 | 1162 | ||
1163 | if (test_bit(ADAPTER_STATE_LINK_DOWN, &hba->adapter_state)) | ||
1164 | return -ENOTCONN; | ||
1165 | |||
1166 | if (!bnx2i_conn->is_bound) | 1163 | if (!bnx2i_conn->is_bound) |
1167 | return -ENOTCONN; | 1164 | return -ENOTCONN; |
1168 | 1165 | ||