From: sagi@grimberg.me (Sagi Grimberg)
Subject: [PATCH for-4.11-rc 2/3] nvme-rdma: Fix sqsize wrong assignment based on ctrl MQES capability
Date: Thu, 6 Apr 2017 09:15:51 +0300 [thread overview]
Message-ID: <1491459352-28200-3-git-send-email-sagi@grimberg.me> (raw)
In-Reply-To: <1491459352-28200-1-git-send-email-sagi@grimberg.me>
both our sqsize and the controller MQES cap are a 0 based value,
so making it 1 based is wrong.
Reported-by: Trapp, Darren <Darren.Trapp at cavium.com>
Reported-by: Daniel Verkamp <daniel.verkamp at intel.com>
Signed-off-by: Sagi Grimberg <sagi at grimberg.me>
---
drivers/nvme/host/rdma.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nvme/host/rdma.c b/drivers/nvme/host/rdma.c
index 4aae363943e3..d674ca32ef02 100644
--- a/drivers/nvme/host/rdma.c
+++ b/drivers/nvme/host/rdma.c
@@ -1600,7 +1600,7 @@ static int nvme_rdma_configure_admin_queue(struct nvme_rdma_ctrl *ctrl)
}
ctrl->ctrl.sqsize =
- min_t(int, NVME_CAP_MQES(ctrl->cap) + 1, ctrl->ctrl.sqsize);
+ min_t(int, NVME_CAP_MQES(ctrl->cap), ctrl->ctrl.sqsize);
error = nvme_enable_ctrl(&ctrl->ctrl, ctrl->cap);
if (error)
--
2.7.4
next prev parent reply other threads:[~2017-04-06 6:15 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-06 6:15 [PATCH for-4.11-rc 0/3] Fix wrong sqsize settings in fabrics Sagi Grimberg
2017-04-06 6:15 ` [PATCH for-4.11-rc 1/3] nvme-loop: Fix sqsize wrong assignment based on ctrl MQES capability Sagi Grimberg
2017-04-06 6:15 ` Sagi Grimberg [this message]
2017-04-06 6:15 ` [PATCH for-4.11-rc 3/3] nvme-fc: " Sagi Grimberg
2017-04-06 8:44 ` [PATCH for-4.11-rc 0/3] Fix wrong sqsize settings in fabrics Christoph Hellwig
2017-04-09 12:29 ` Sagi Grimberg
2017-04-09 19:58 ` Jens Axboe
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=1491459352-28200-3-git-send-email-sagi@grimberg.me \
--to=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).