aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/bnx2i
diff options
context:
space:
mode:
authorNicholas Bellinger <nab@linux-iscsi.org>2011-05-27 07:16:33 -0400
committerNicholas Bellinger <nab@linux-iscsi.org>2011-07-25 03:18:45 -0400
commit123521830c0ea35055b900d2ff0b73bb129e08cb (patch)
treee0f2a4b46d6b7759a17b91f4953627b51ce20d5a /drivers/scsi/bnx2i
parentbbd9d6f7fbb0305c9a592bf05a32e87eb364a4ff (diff)
iscsi: Resolve iscsi_proto.h naming conflicts with drivers/target/iscsi
This patch renames the following iscsi_proto.h structures to avoid namespace issues with drivers/target/iscsi/iscsi_target_core.h: *) struct iscsi_cmd -> struct iscsi_scsi_req *) struct iscsi_cmd_rsp -> struct iscsi_scsi_rsp *) struct iscsi_login -> struct iscsi_login_req This patch includes useful ISCSI_FLAG_LOGIN_[CURRENT,NEXT]_STAGE*, and ISCSI_FLAG_SNACK_TYPE_* definitions used by iscsi_target_mod, and fixes the incorrect definition of struct iscsi_snack to following RFC-3720 Section 10.16. SNACK Request. Also, this patch updates libiscsi, iSER, be2iscsi, and bn2xi to use the updated structure definitions in a handful of locations. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Nicholas A. Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'drivers/scsi/bnx2i')
-rw-r--r--drivers/scsi/bnx2i/bnx2i_hwi.c8
-rw-r--r--drivers/scsi/bnx2i/bnx2i_iscsi.c2
2 files changed, 5 insertions, 5 deletions
diff --git a/drivers/scsi/bnx2i/bnx2i_hwi.c b/drivers/scsi/bnx2i/bnx2i_hwi.c
index 372d30c099cc..1b160e12afa3 100644
--- a/drivers/scsi/bnx2i/bnx2i_hwi.c
+++ b/drivers/scsi/bnx2i/bnx2i_hwi.c
@@ -328,11 +328,11 @@ int bnx2i_send_iscsi_login(struct bnx2i_conn *bnx2i_conn,
328{ 328{
329 struct bnx2i_cmd *bnx2i_cmd; 329 struct bnx2i_cmd *bnx2i_cmd;
330 struct bnx2i_login_request *login_wqe; 330 struct bnx2i_login_request *login_wqe;
331 struct iscsi_login *login_hdr; 331 struct iscsi_login_req *login_hdr;
332 u32 dword; 332 u32 dword;
333 333
334 bnx2i_cmd = (struct bnx2i_cmd *)task->dd_data; 334 bnx2i_cmd = (struct bnx2i_cmd *)task->dd_data;
335 login_hdr = (struct iscsi_login *)task->hdr; 335 login_hdr = (struct iscsi_login_req *)task->hdr;
336 login_wqe = (struct bnx2i_login_request *) 336 login_wqe = (struct bnx2i_login_request *)
337 bnx2i_conn->ep->qp.sq_prod_qe; 337 bnx2i_conn->ep->qp.sq_prod_qe;
338 338
@@ -1344,7 +1344,7 @@ static int bnx2i_process_scsi_cmd_resp(struct iscsi_session *session,
1344 struct bnx2i_cmd_response *resp_cqe; 1344 struct bnx2i_cmd_response *resp_cqe;
1345 struct bnx2i_cmd *bnx2i_cmd; 1345 struct bnx2i_cmd *bnx2i_cmd;
1346 struct iscsi_task *task; 1346 struct iscsi_task *task;
1347 struct iscsi_cmd_rsp *hdr; 1347 struct iscsi_scsi_rsp *hdr;
1348 u32 datalen = 0; 1348 u32 datalen = 0;
1349 1349
1350 resp_cqe = (struct bnx2i_cmd_response *)cqe; 1350 resp_cqe = (struct bnx2i_cmd_response *)cqe;
@@ -1371,7 +1371,7 @@ static int bnx2i_process_scsi_cmd_resp(struct iscsi_session *session,
1371 } 1371 }
1372 bnx2i_iscsi_unmap_sg_list(bnx2i_cmd); 1372 bnx2i_iscsi_unmap_sg_list(bnx2i_cmd);
1373 1373
1374 hdr = (struct iscsi_cmd_rsp *)task->hdr; 1374 hdr = (struct iscsi_scsi_rsp *)task->hdr;
1375 resp_cqe = (struct bnx2i_cmd_response *)cqe; 1375 resp_cqe = (struct bnx2i_cmd_response *)cqe;
1376 hdr->opcode = resp_cqe->op_code; 1376 hdr->opcode = resp_cqe->op_code;
1377 hdr->max_cmdsn = cpu_to_be32(resp_cqe->max_cmd_sn); 1377 hdr->max_cmdsn = cpu_to_be32(resp_cqe->max_cmd_sn);
diff --git a/drivers/scsi/bnx2i/bnx2i_iscsi.c b/drivers/scsi/bnx2i/bnx2i_iscsi.c
index 041928b23cb0..97ff47ce1840 100644
--- a/drivers/scsi/bnx2i/bnx2i_iscsi.c
+++ b/drivers/scsi/bnx2i/bnx2i_iscsi.c
@@ -1212,7 +1212,7 @@ static int bnx2i_task_xmit(struct iscsi_task *task)
1212 struct bnx2i_conn *bnx2i_conn = conn->dd_data; 1212 struct bnx2i_conn *bnx2i_conn = conn->dd_data;
1213 struct scsi_cmnd *sc = task->sc; 1213 struct scsi_cmnd *sc = task->sc;
1214 struct bnx2i_cmd *cmd = task->dd_data; 1214 struct bnx2i_cmd *cmd = task->dd_data;
1215 struct iscsi_cmd *hdr = (struct iscsi_cmd *) task->hdr; 1215 struct iscsi_scsi_req *hdr = (struct iscsi_scsi_req *)task->hdr;
1216 1216
1217 if (bnx2i_conn->ep->num_active_cmds + 1 > hba->max_sqes) 1217 if (bnx2i_conn->ep->num_active_cmds + 1 > hba->max_sqes)
1218 return -ENOMEM; 1218 return -ENOMEM;