diff options
Diffstat (limited to 'drivers/scsi/bnx2i/bnx2i_iscsi.c')
-rw-r--r-- | drivers/scsi/bnx2i/bnx2i_iscsi.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/drivers/scsi/bnx2i/bnx2i_iscsi.c b/drivers/scsi/bnx2i/bnx2i_iscsi.c index a46ccc380ab1..fb50efbce087 100644 --- a/drivers/scsi/bnx2i/bnx2i_iscsi.c +++ b/drivers/scsi/bnx2i/bnx2i_iscsi.c | |||
@@ -1078,11 +1078,9 @@ static int bnx2i_iscsi_send_generic_request(struct iscsi_task *task) | |||
1078 | buf = bnx2i_conn->gen_pdu.req_buf; | 1078 | buf = bnx2i_conn->gen_pdu.req_buf; |
1079 | if (data_len) | 1079 | if (data_len) |
1080 | rc = bnx2i_send_iscsi_nopout(bnx2i_conn, task, | 1080 | rc = bnx2i_send_iscsi_nopout(bnx2i_conn, task, |
1081 | RESERVED_ITT, | ||
1082 | buf, data_len, 1); | 1081 | buf, data_len, 1); |
1083 | else | 1082 | else |
1084 | rc = bnx2i_send_iscsi_nopout(bnx2i_conn, task, | 1083 | rc = bnx2i_send_iscsi_nopout(bnx2i_conn, task, |
1085 | RESERVED_ITT, | ||
1086 | NULL, 0, 1); | 1084 | NULL, 0, 1); |
1087 | break; | 1085 | break; |
1088 | case ISCSI_OP_LOGOUT: | 1086 | case ISCSI_OP_LOGOUT: |
@@ -1955,6 +1953,9 @@ int bnx2i_hw_ep_disconnect(struct bnx2i_endpoint *bnx2i_ep) | |||
1955 | if (!cnic) | 1953 | if (!cnic) |
1956 | return 0; | 1954 | return 0; |
1957 | 1955 | ||
1956 | if (bnx2i_ep->state == EP_STATE_IDLE) | ||
1957 | return 0; | ||
1958 | |||
1958 | if (!bnx2i_ep_tcp_conn_active(bnx2i_ep)) | 1959 | if (!bnx2i_ep_tcp_conn_active(bnx2i_ep)) |
1959 | goto destroy_conn; | 1960 | goto destroy_conn; |
1960 | 1961 | ||
@@ -1998,11 +1999,13 @@ int bnx2i_hw_ep_disconnect(struct bnx2i_endpoint *bnx2i_ep) | |||
1998 | else | 1999 | else |
1999 | close_ret = cnic->cm_abort(bnx2i_ep->cm_sk); | 2000 | close_ret = cnic->cm_abort(bnx2i_ep->cm_sk); |
2000 | 2001 | ||
2002 | /* No longer allow CFC delete if cm_close/abort fails the request */ | ||
2001 | if (close_ret) | 2003 | if (close_ret) |
2002 | bnx2i_ep->state = EP_STATE_DISCONN_COMPL; | 2004 | printk(KERN_ALERT "bnx2i: %s close/abort(%d) returned %d\n", |
2003 | 2005 | bnx2i_ep->hba->netdev->name, close, close_ret); | |
2004 | /* wait for option-2 conn teardown */ | 2006 | else |
2005 | wait_event_interruptible(bnx2i_ep->ofld_wait, | 2007 | /* wait for option-2 conn teardown */ |
2008 | wait_event_interruptible(bnx2i_ep->ofld_wait, | ||
2006 | bnx2i_ep->state != EP_STATE_DISCONN_START); | 2009 | bnx2i_ep->state != EP_STATE_DISCONN_START); |
2007 | 2010 | ||
2008 | if (signal_pending(current)) | 2011 | if (signal_pending(current)) |