iscsi: replace printf()s with spdk/log.h calls
Change-Id: Ic2df5a410f5308bf8567058659d518052395fc36 Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
This commit is contained in:
parent
3c85e0a394
commit
ad6fa9f0d6
@ -610,18 +610,19 @@ spdk_iscsi_drop_conns(struct spdk_iscsi_conn *conn, const char *conn_match,
|
||||
* Only print this message before we report the
|
||||
* first dropped connection.
|
||||
*/
|
||||
printf("drop old connections %s by %s\n",
|
||||
conn->target->name, conn_match);
|
||||
SPDK_ERRLOG("drop old connections %s by %s\n",
|
||||
conn->target->name, conn_match);
|
||||
}
|
||||
|
||||
printf("exiting conn by %s(%s), ",
|
||||
xconn_match, xconn->initiator_addr);
|
||||
if (xconn->sess != NULL)
|
||||
printf("TSIH=%u, ", xconn->sess->tsih);
|
||||
else
|
||||
printf("TSIH=xx, ");
|
||||
SPDK_ERRLOG("exiting conn by %s (%s)",
|
||||
xconn_match, xconn->initiator_addr);
|
||||
if (xconn->sess != NULL) {
|
||||
SPDK_TRACELOG(SPDK_TRACE_ISCSI, "TSIH=%u\n", xconn->sess->tsih);
|
||||
} else {
|
||||
SPDK_TRACELOG(SPDK_TRACE_ISCSI, "TSIH=xx\n");
|
||||
}
|
||||
|
||||
printf("CID=%u\n", xconn->cid);
|
||||
SPDK_TRACELOG(SPDK_TRACE_ISCSI, "CID=%u\n", xconn->cid);
|
||||
xconn->state = ISCSI_CONN_STATE_EXITING;
|
||||
num++;
|
||||
}
|
||||
@ -629,8 +630,9 @@ spdk_iscsi_drop_conns(struct spdk_iscsi_conn *conn, const char *conn_match,
|
||||
|
||||
pthread_mutex_unlock(&g_conns_mutex);
|
||||
|
||||
if (num != 0)
|
||||
printf("exiting %d conns\n", num);
|
||||
if (num != 0) {
|
||||
SPDK_ERRLOG("exiting %d conns\n", num);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -957,7 +957,7 @@ spdk_iscsi_auth_params(struct spdk_iscsi_conn *conn,
|
||||
tgtmd5, SPDK_MD5DIGEST_LEN);
|
||||
|
||||
#if 0
|
||||
printf("tgtmd5=%s, resmd5=%s\n", in_val, response);
|
||||
SPDK_TRACELOG(SPDK_TRACE_ISCSI, "tgtmd5=%s, resmd5=%s\n", in_val, response);
|
||||
spdk_dump("tgtmd5", tgtmd5, SPDK_MD5DIGEST_LEN);
|
||||
spdk_dump("resmd5", resmd5, SPDK_MD5DIGEST_LEN);
|
||||
#endif
|
||||
@ -4659,7 +4659,7 @@ spdk_append_iscsi_sess(struct spdk_iscsi_conn *conn,
|
||||
return -1;
|
||||
}
|
||||
|
||||
printf("Connections(tsih %d): %d\n", sess->tsih, sess->connections);
|
||||
SPDK_TRACELOG(SPDK_TRACE_ISCSI, "Connections (tsih %d): %d\n", sess->tsih, sess->connections);
|
||||
conn->sess = sess;
|
||||
|
||||
/*
|
||||
|
@ -110,8 +110,8 @@ spdk_iscsi_tgt_node_allow_ipv6(const char *netmask, const char *addr)
|
||||
}
|
||||
|
||||
#if 0
|
||||
printf("input %s\n", addr);
|
||||
printf("mask %s / %d\n", mask, bits);
|
||||
SPDK_TRACELOG(SPDK_TRACE_ISCSI, "input %s\n", addr);
|
||||
SPDK_TRACELOG(SPDK_TRACE_ISCSI, "mask %s / %d\n", mask, bits);
|
||||
#endif
|
||||
|
||||
/* presentation to network order binary */
|
||||
|
Loading…
Reference in New Issue
Block a user