All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chaitanya Kulkarni <kch@nvidia.com>
To: <linux-nvme@lists.infradead.org>
Cc: <kbusch@kernel.org>, <axboe@fb.com>, <hch@lst.de>,
	<sagi@grimberg.me>, Chaitanya Kulkarni <kch@nvidia.com>
Subject: [PATCH 3/3] nvme-tcp:  use helper to reduce common code
Date: Wed, 26 Apr 2023 05:31:19 -0700	[thread overview]
Message-ID: <20230426123119.8738-3-kch@nvidia.com> (raw)
In-Reply-To: <20230426123119.8738-1-kch@nvidia.com>

Instaed of duplicating same code in every transport to print
ctrl->io_queues, use helper for nvme-tcp transport to remove
repetative code.

Signed-off-by: Chaitanya Kulkarni <kch@nvidia.com>
---
 drivers/nvme/host/tcp.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/drivers/nvme/host/tcp.c b/drivers/nvme/host/tcp.c
index 273c1f2760a4..1d775ecc6aa4 100644
--- a/drivers/nvme/host/tcp.c
+++ b/drivers/nvme/host/tcp.c
@@ -2464,11 +2464,7 @@ static void nvme_tcp_map_queues(struct blk_mq_tag_set *set)
 		blk_mq_map_queues(&set->map[HCTX_TYPE_POLL]);
 	}
 
-	dev_info(ctrl->ctrl.device,
-		"mapped %d/%d/%d default/read/poll queues.\n",
-		ctrl->io_queues[HCTX_TYPE_DEFAULT],
-		ctrl->io_queues[HCTX_TYPE_READ],
-		ctrl->io_queues[HCTX_TYPE_POLL]);
+	nvme_ctrl_print_io_queues(&ctrl->ctrl, ctrl->io_queues);
 }
 
 static int nvme_tcp_poll(struct blk_mq_hw_ctx *hctx, struct io_comp_batch *iob)
-- 
2.40.0



  parent reply	other threads:[~2023-04-26 12:32 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-26 12:31 [PATCH 1/3] nvme-pci: add and use print io-queues helper Chaitanya Kulkarni
2023-04-26 12:31 ` [PATCH 2/3] nvme-rdma: use helper to reduce common code Chaitanya Kulkarni
2023-04-26 12:31 ` Chaitanya Kulkarni [this message]
2023-04-26 12:59 ` [PATCH 1/3] nvme-pci: add and use print io-queues helper Chaitanya Kulkarni
2023-04-26 16:37 ` Niklas Cassel

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=20230426123119.8738-3-kch@nvidia.com \
    --to=kch@nvidia.com \
    --cc=axboe@fb.com \
    --cc=hch@lst.de \
    --cc=kbusch@kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=sagi@grimberg.me \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.