From: "Wunderlich, Mark" <mark.wunderlich@intel.com>
To: "linux-nvme@lists.infradead.org" <linux-nvme@lists.infradead.org>
Cc: Sagi Grimberg <sagi@grimberg.me>
Subject: [PATCH] nvme/host/tcp.c: fix use of time_after()
Date: Wed, 18 Sep 2019 00:53:20 +0000 [thread overview]
Message-ID: <B33B37937B7F3D4CB878107E305D4916D339CC@ORSMSX104.amr.corp.intel.com> (raw)
nvme/host/tcp.c: fix use of time_after()
From: Mark Wunderlich <mark.wunderlich@intel.com>
The values provided to time_after() call used to terminate
do/while loop were reversed, causing loop to always exit
after single pass. Believe intent was to give the worker
a 1 msec time quota.
Signed-off-by: Mark Wunderlich <mark.wunderlich@intel.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 08a2501..8f4a3f84 100644
--- a/drivers/nvme/host/tcp.c
+++ b/drivers/nvme/host/tcp.c
@@ -1057,7 +1057,7 @@ static void nvme_tcp_io_work(struct work_struct *w)
if (!pending)
return;
- } while (time_after(jiffies, start)); /* quota is exhausted */
+ } while (time_after(start, jiffies)); /* quota is exhausted */
queue_work_on(queue->io_cpu, nvme_tcp_wq, &queue->io_work);
}
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
next reply other threads:[~2019-09-18 0:53 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-18 0:53 Wunderlich, Mark [this message]
2019-09-18 1:40 ` [PATCH] nvme/host/tcp.c: fix use of time_after() Sagi Grimberg
2019-09-18 18:20 ` Wunderlich, Mark
2019-09-18 18:21 ` Bart Van Assche
2019-09-18 18:55 ` Sagi Grimberg
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=B33B37937B7F3D4CB878107E305D4916D339CC@ORSMSX104.amr.corp.intel.com \
--to=mark.wunderlich@intel.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).