iscsi: change connection messages to DEBUGLOGs

Printing messages every time an iSCSI connection logs in or
logs out/terminates is too noisy.  Make these DEBUGLOGs
instead.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Ifc1014e4f8dce414a1c4ef75ea6b6749954083cc
Reviewed-on: https://review.gerrithub.io/432606
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
Jim Harris 2018-11-09 09:13:20 -07:00
parent 0d8783cabc
commit 807c3a2b27
2 changed files with 24 additions and 24 deletions

View File

@ -343,7 +343,7 @@ error_return:
}
conn->logout_timer = NULL;
conn->shutdown_timer = NULL;
SPDK_NOTICELOG("Launching connection on acceptor thread\n");
SPDK_DEBUGLOG(SPDK_LOG_ISCSI, "Launching connection on acceptor thread\n");
conn->pending_task_cnt = 0;
conn->pending_activate_event = false;
@ -463,7 +463,8 @@ static void spdk_iscsi_remove_conn(struct spdk_iscsi_conn *conn)
sess->connections--;
}
SPDK_NOTICELOG("Terminating connections(tsih %d): %d\n", sess->tsih, sess->connections);
SPDK_DEBUGLOG(SPDK_LOG_ISCSI, "Terminating connections(tsih %d): %d\n",
sess->tsih, sess->connections);
if (sess->connections == 0) {
/* cleanup last connection */

View File

@ -1934,35 +1934,34 @@ static int
spdk_iscsi_op_login_notify_session_info(struct spdk_iscsi_conn *conn,
struct spdk_iscsi_pdu *rsp_pdu)
{
struct spdk_iscsi_portal *portal = conn->portal;
struct iscsi_bhs_login_rsp *rsph;
rsph = (struct iscsi_bhs_login_rsp *)&rsp_pdu->bhs;
if (conn->sess->session_type == SESSION_TYPE_NORMAL) {
/* normal session */
SPDK_NOTICELOG("Login from %s (%s) on %s tgt_node%d"
" (%s:%s,%d), ISID=%"PRIx64", TSIH=%u,"
" CID=%u, HeaderDigest=%s, DataDigest=%s\n",
conn->initiator_name, conn->initiator_addr,
conn->target->name, conn->target->num,
portal->host, portal->port, portal->group->tag,
conn->sess->isid, conn->sess->tsih, conn->cid,
(spdk_iscsi_param_eq_val(conn->params, "HeaderDigest", "CRC32C")
? "on" : "off"),
(spdk_iscsi_param_eq_val(conn->params, "DataDigest", "CRC32C")
? "on" : "off"));
SPDK_DEBUGLOG(SPDK_LOG_ISCSI, "Login from %s (%s) on %s tgt_node%d"
" (%s:%s,%d), ISID=%"PRIx64", TSIH=%u,"
" CID=%u, HeaderDigest=%s, DataDigest=%s\n",
conn->initiator_name, conn->initiator_addr,
conn->target->name, conn->target->num,
conn->portal->host, conn->portal->port, conn->portal->group->tag,
conn->sess->isid, conn->sess->tsih, conn->cid,
(spdk_iscsi_param_eq_val(conn->params, "HeaderDigest", "CRC32C")
? "on" : "off"),
(spdk_iscsi_param_eq_val(conn->params, "DataDigest", "CRC32C")
? "on" : "off"));
} else if (conn->sess->session_type == SESSION_TYPE_DISCOVERY) {
/* discovery session */
SPDK_NOTICELOG("Login(discovery) from %s (%s) on"
" (%s:%s,%d), ISID=%"PRIx64", TSIH=%u,"
" CID=%u, HeaderDigest=%s, DataDigest=%s\n",
conn->initiator_name, conn->initiator_addr,
portal->host, portal->port, portal->group->tag,
conn->sess->isid, conn->sess->tsih, conn->cid,
(spdk_iscsi_param_eq_val(conn->params, "HeaderDigest", "CRC32C")
? "on" : "off"),
(spdk_iscsi_param_eq_val(conn->params, "DataDigest", "CRC32C")
? "on" : "off"));
SPDK_DEBUGLOG(SPDK_LOG_ISCSI, "Login(discovery) from %s (%s) on"
" (%s:%s,%d), ISID=%"PRIx64", TSIH=%u,"
" CID=%u, HeaderDigest=%s, DataDigest=%s\n",
conn->initiator_name, conn->initiator_addr,
conn->portal->host, conn->portal->port, conn->portal->group->tag,
conn->sess->isid, conn->sess->tsih, conn->cid,
(spdk_iscsi_param_eq_val(conn->params, "HeaderDigest", "CRC32C")
? "on" : "off"),
(spdk_iscsi_param_eq_val(conn->params, "DataDigest", "CRC32C")
? "on" : "off"));
} else {
SPDK_ERRLOG("unknown session type\n");
/* Initiator error */