Commit adbae389 authored by Shuhei Matsumoto's avatar Shuhei Matsumoto Committed by Ben Walker
Browse files

lib/iscsi: Set target node to the created session in create_iscsi_sess()



target had been set to the created session after returning from
create_iscsi_sess(). But create_iscsi_sess() has been used only in
a place and target has been already included in the arguments in
it. So set target to the created session in create_iscsi_sess().

Change-Id: Id65e6c5a1f76b995a7d0e9939ff3a2fce5daeb3f
Signed-off-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/450732


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
parent da98b92b
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -1643,7 +1643,6 @@ iscsi_op_login_set_conn_info(struct spdk_iscsi_conn *conn,
		conn->sess->initiator_port = initiator_port;
		conn->StatSN = from_be32(&rsph->stat_sn);
		conn->sess->isid = iscsi_get_isid(rsph->isid);
		conn->sess->target = target;

		/* Initiator port TransportID */
		spdk_scsi_port_set_iscsi_transport_id(conn->sess->initiator_port,
@@ -4749,7 +4748,7 @@ create_iscsi_sess(struct spdk_iscsi_conn *conn,
	sess->connections++;

	sess->params = NULL;
	sess->target = NULL;
	sess->target = target;
	sess->isid = 0;
	sess->session_type = session_type;
	sess->current_text_itt = 0xffffffffU;