All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chaitanya Kulkarni <kch@nvidia.com>
To: <sagi@grimberg.me>
Cc: <linux-nvme@lists.infradead.org>, <hch@lst.de>,
	Chaitanya Kulkarni <kch@nvidia.com>
Subject: [PATCH 1/2] nvme-tcp: don't initialize ret variable
Date: Tue, 22 Feb 2022 19:36:56 -0800	[thread overview]
Message-ID: <20220223033657.208747-2-kch@nvidia.com> (raw)
In-Reply-To: <20220223033657.208747-1-kch@nvidia.com>

No point in initializing ret variable to 0 in nvme_tcp_start_io_queue()
since it gets overwritten by a call to nvme_tcp_start_queue().

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

diff --git a/drivers/nvme/host/tcp.c b/drivers/nvme/host/tcp.c
index 6cbcc8b4daaf..bb03ae5ef11f 100644
--- a/drivers/nvme/host/tcp.c
+++ b/drivers/nvme/host/tcp.c
@@ -1674,7 +1674,7 @@ static void nvme_tcp_stop_io_queues(struct nvme_ctrl *ctrl)
 
 static int nvme_tcp_start_io_queues(struct nvme_ctrl *ctrl)
 {
-	int i, ret = 0;
+	int i, ret;
 
 	for (i = 1; i < ctrl->queue_count; i++) {
 		ret = nvme_tcp_start_queue(ctrl, i);
-- 
2.29.0



  reply	other threads:[~2022-02-23  3:37 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-23  3:36 [PATCH 0/2] nvme-tcp: small cleanup Chaitanya Kulkarni
2022-02-23  3:36 ` Chaitanya Kulkarni [this message]
2022-02-23 10:39   ` [PATCH 1/2] nvme-tcp: don't initialize ret variable Sagi Grimberg
2022-02-23  3:36 ` [PATCH 2/2] nvme-tcp: don't fold the line Chaitanya Kulkarni
2022-02-23 10:39   ` Sagi Grimberg
2022-03-07  3:48 ` [PATCH 0/2] nvme-tcp: small cleanup Chaitanya Kulkarni
2022-03-07  7:59 ` Christoph Hellwig

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=20220223033657.208747-2-kch@nvidia.com \
    --to=kch@nvidia.com \
    --cc=hch@lst.de \
    --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.