Linux CIFS filesystem development
 help / color / mirror / Atom feed
From: Tom Talpey <tom@talpey.com>
To: smfrench@gmail.com, linux-cifs@vger.kernel.org
Cc: linkinjeon@kernel.org, senozhatsky@chromium.org,
	bmt@zurich.ibm.com, longli@microsoft.com, dhowells@redhat.com,
	Tom Talpey <tom@talpey.com>
Subject: [PATCH v2 6/6] Fix formatting of client smbdirect RDMA logging
Date: Fri, 23 Sep 2022 21:54:00 +0000	[thread overview]
Message-ID: <01a4ede1bf68bcbc2ee99cdd00ea229bbc618bb9.1663961449.git.tom@talpey.com> (raw)
In-Reply-To: <cover.1663961449.git.tom@talpey.com>

Make the debug logging more consistent in formatting of addresses,
lengths, and bitfields.

Signed-off-by: Tom Talpey <tom@talpey.com>
---
 fs/cifs/smbdirect.c | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/fs/cifs/smbdirect.c b/fs/cifs/smbdirect.c
index 6ac424d26fe6..90789aaa6567 100644
--- a/fs/cifs/smbdirect.c
+++ b/fs/cifs/smbdirect.c
@@ -270,7 +270,7 @@ static void send_done(struct ib_cq *cq, struct ib_wc *wc)
 	struct smbd_request *request =
 		container_of(wc->wr_cqe, struct smbd_request, cqe);
 
-	log_rdma_send(INFO, "smbd_request %p completed wc->status=%d\n",
+	log_rdma_send(INFO, "smbd_request 0x%p completed wc->status=%d\n",
 		request, wc->status);
 
 	if (wc->status != IB_WC_SUCCESS || wc->opcode != IB_WC_SEND) {
@@ -448,7 +448,7 @@ static void recv_done(struct ib_cq *cq, struct ib_wc *wc)
 	struct smbd_connection *info = response->info;
 	int data_length = 0;
 
-	log_rdma_recv(INFO, "response=%p type=%d wc status=%d wc opcode %d byte_len=%d pkey_index=%x\n",
+	log_rdma_recv(INFO, "response=0x%p type=%d wc status=%d wc opcode %d byte_len=%d pkey_index=%u\n",
 		      response, response->type, wc->status, wc->opcode,
 		      wc->byte_len, wc->pkey_index);
 
@@ -723,7 +723,7 @@ static int smbd_post_send_negotiate_req(struct smbd_connection *info)
 	send_wr.opcode = IB_WR_SEND;
 	send_wr.send_flags = IB_SEND_SIGNALED;
 
-	log_rdma_send(INFO, "sge addr=%llx length=%x lkey=%x\n",
+	log_rdma_send(INFO, "sge addr=0x%llx length=%u lkey=0x%x\n",
 		request->sge[0].addr,
 		request->sge[0].length, request->sge[0].lkey);
 
@@ -792,7 +792,7 @@ static int smbd_post_send(struct smbd_connection *info,
 
 	for (i = 0; i < request->num_sge; i++) {
 		log_rdma_send(INFO,
-			"rdma_request sge[%d] addr=%llu length=%u\n",
+			"rdma_request sge[%d] addr=0x%llx length=%u\n",
 			i, request->sge[i].addr, request->sge[i].length);
 		ib_dma_sync_single_for_device(
 			info->id->device,
@@ -1079,7 +1079,7 @@ static int smbd_negotiate(struct smbd_connection *info)
 
 	response->type = SMBD_NEGOTIATE_RESP;
 	rc = smbd_post_recv(info, response);
-	log_rdma_event(INFO, "smbd_post_recv rc=%d iov.addr=%llx iov.length=%x iov.lkey=%x\n",
+	log_rdma_event(INFO, "smbd_post_recv rc=%d iov.addr=0x%llx iov.length=%u iov.lkey=0x%x\n",
 		       rc, response->sge.addr,
 		       response->sge.length, response->sge.lkey);
 	if (rc)
@@ -1539,7 +1539,7 @@ static struct smbd_connection *_smbd_get_connection(
 
 	if (smbd_send_credit_target > info->id->device->attrs.max_cqe ||
 	    smbd_send_credit_target > info->id->device->attrs.max_qp_wr) {
-		log_rdma_event(ERR, "consider lowering send_credit_target = %d. Possible CQE overrun, device reporting max_cpe %d max_qp_wr %d\n",
+		log_rdma_event(ERR, "consider lowering send_credit_target = %d. Possible CQE overrun, device reporting max_cqe %d max_qp_wr %d\n",
 			       smbd_send_credit_target,
 			       info->id->device->attrs.max_cqe,
 			       info->id->device->attrs.max_qp_wr);
@@ -1548,7 +1548,7 @@ static struct smbd_connection *_smbd_get_connection(
 
 	if (smbd_receive_credit_max > info->id->device->attrs.max_cqe ||
 	    smbd_receive_credit_max > info->id->device->attrs.max_qp_wr) {
-		log_rdma_event(ERR, "consider lowering receive_credit_max = %d. Possible CQE overrun, device reporting max_cpe %d max_qp_wr %d\n",
+		log_rdma_event(ERR, "consider lowering receive_credit_max = %d. Possible CQE overrun, device reporting max_cqe %d max_qp_wr %d\n",
 			       smbd_receive_credit_max,
 			       info->id->device->attrs.max_cqe,
 			       info->id->device->attrs.max_qp_wr);
-- 
2.34.1


  parent reply	other threads:[~2022-09-23 21:54 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-23 21:53 [PATCH v2 0/6] Reduce SMBDirect RDMA SGE counts and sizes Tom Talpey
2022-09-23 21:53 ` [PATCH v2 1/6] Decrease the number of SMB3 smbdirect client SGEs Tom Talpey
2022-09-23 21:53 ` [PATCH v2 2/6] Decrease the number of SMB3 smbdirect server SGEs Tom Talpey
2022-09-27  0:37   ` Namjae Jeon
2022-09-23 21:53 ` [PATCH v2 3/6] Reduce client smbdirect max receive segment size Tom Talpey
2022-09-23 21:53 ` [PATCH v2 4/6] Reduce server smbdirect max send/receive segment sizes Tom Talpey
2022-09-25  3:40   ` Namjae Jeon
2022-09-25 15:41     ` Tom Talpey
2022-09-26  1:13       ` Namjae Jeon
2022-09-26 17:24         ` Tom Talpey
2022-09-27 14:59           ` Bernard Metzler
2022-09-28 14:53             ` Tom Talpey
2022-09-29  7:17               ` Bernard Metzler
2022-09-27  0:36   ` Namjae Jeon
2022-09-23 21:53 ` [PATCH v2 5/6] Handle variable number of SGEs in client smbdirect send Tom Talpey
2022-09-23 21:54 ` Tom Talpey [this message]
2022-09-25  3:45 ` [PATCH v2 0/6] Reduce SMBDirect RDMA SGE counts and sizes Namjae Jeon
2022-09-25 15:46   ` Tom Talpey
2022-09-29  5:02 ` Steve French
2022-09-29 15:15   ` Tom Talpey
2022-09-29 15:27     ` Steve French
2022-09-29 15:44       ` Tom Talpey
2022-10-04 18:42 ` Paulo Alcantara

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=01a4ede1bf68bcbc2ee99cdd00ea229bbc618bb9.1663961449.git.tom@talpey.com \
    --to=tom@talpey.com \
    --cc=bmt@zurich.ibm.com \
    --cc=dhowells@redhat.com \
    --cc=linkinjeon@kernel.org \
    --cc=linux-cifs@vger.kernel.org \
    --cc=longli@microsoft.com \
    --cc=senozhatsky@chromium.org \
    --cc=smfrench@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox