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>
This commit is contained in:
@ -360,7 +360,7 @@ static int iscsi_prep_scsi_cmd_pdu(struct iscsi_task *task)
|
||||
struct iscsi_conn *conn = task->conn;
|
||||
struct iscsi_session *session = conn->session;
|
||||
struct scsi_cmnd *sc = task->sc;
|
||||
struct iscsi_cmd *hdr;
|
||||
struct iscsi_scsi_req *hdr;
|
||||
unsigned hdrlength, cmd_len;
|
||||
itt_t itt;
|
||||
int rc;
|
||||
@ -374,7 +374,7 @@ static int iscsi_prep_scsi_cmd_pdu(struct iscsi_task *task)
|
||||
if (rc)
|
||||
return rc;
|
||||
}
|
||||
hdr = (struct iscsi_cmd *) task->hdr;
|
||||
hdr = (struct iscsi_scsi_req *)task->hdr;
|
||||
itt = hdr->itt;
|
||||
memset(hdr, 0, sizeof(*hdr));
|
||||
|
||||
@ -830,7 +830,7 @@ static void iscsi_scsi_cmd_rsp(struct iscsi_conn *conn, struct iscsi_hdr *hdr,
|
||||
struct iscsi_task *task, char *data,
|
||||
int datalen)
|
||||
{
|
||||
struct iscsi_cmd_rsp *rhdr = (struct iscsi_cmd_rsp *)hdr;
|
||||
struct iscsi_scsi_rsp *rhdr = (struct iscsi_scsi_rsp *)hdr;
|
||||
struct iscsi_session *session = conn->session;
|
||||
struct scsi_cmnd *sc = task->sc;
|
||||
|
||||
|
Reference in New Issue
Block a user