From 4ee15cd2391c72fe1e7d99f05ebc7d0c4a990b4b Mon Sep 17 00:00:00 2001 From: Stephen Oost Date: Fri, 10 Feb 2023 13:11:08 -0800 Subject: [PATCH] prov/tcp: add debug prints for connection targets Signed-off-by: Stephen Oost --- prov/tcp/src/xnet_cm.c | 4 ++++ prov/tcp/src/xnet_ep.c | 3 ++- prov/tcp/src/xnet_rdm_cm.c | 3 +++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/prov/tcp/src/xnet_cm.c b/prov/tcp/src/xnet_cm.c index e51ab1b8aae..4c02d7f81e7 100644 --- a/prov/tcp/src/xnet_cm.c +++ b/prov/tcp/src/xnet_cm.c @@ -227,6 +227,10 @@ void xnet_run_conn(struct xnet_conn_handle *conn, bool pin, bool pout, bool perr if (ret) goto freeinfo; + ofi_straddr_dbg(&xnet_prov, FI_LOG_EP_CTRL, "conn req from dest", + cm_entry.info->dest_addr); + ofi_straddr_dbg(&xnet_prov, FI_LOG_EP_CTRL, "conn req for src", + cm_entry.info->src_addr); conn->endian_match = (msg.hdr.conn_data == 1); cm_entry.info->handle = &conn->fid; datalen = ntohs(msg.hdr.seg_size); diff --git a/prov/tcp/src/xnet_ep.c b/prov/tcp/src/xnet_ep.c index dcb7dcae02e..88e1a9169ce 100644 --- a/prov/tcp/src/xnet_ep.c +++ b/prov/tcp/src/xnet_ep.c @@ -203,7 +203,8 @@ static int xnet_ep_connect(struct fid_ep *ep_fid, const void *addr, struct xnet_ep *ep; int ret; - FI_DBG(&xnet_prov, FI_LOG_EP_CTRL, "connecting endpoint\n"); + + ofi_straddr_dbg(&xnet_prov, FI_LOG_EP_CTRL, "connecting to", addr); ep = container_of(ep_fid, struct xnet_ep, util_ep.ep_fid); if (!addr || (ep->bsock.sock == INVALID_SOCKET) || (paramlen > XNET_MAX_CM_DATA_SIZE) || (ep->state != XNET_IDLE)) diff --git a/prov/tcp/src/xnet_rdm_cm.c b/prov/tcp/src/xnet_rdm_cm.c index 427d23cdef9..a436be268fa 100644 --- a/prov/tcp/src/xnet_rdm_cm.c +++ b/prov/tcp/src/xnet_rdm_cm.c @@ -225,6 +225,9 @@ static int xnet_rdm_connect(struct xnet_conn *conn) msg.resv = 0; msg.port = htons(ofi_addr_get_port(&conn->rdm->addr.sa)); + ofi_straddr_dbg(&xnet_prov, FI_LOG_EP_CTRL, "rdm addr", &conn->rdm->addr); + ofi_straddr_dbg(&xnet_prov, FI_LOG_EP_CTRL, "src addr", info->src_addr); + ret = fi_connect(&conn->ep->util_ep.ep_fid, info->dest_addr, &msg, sizeof msg); if (ret) {