From: Bart Van Assche <bart.vanassche-XdAiOPVOjttBDgjK7y7TUQ@public.gmane.org>
To: Sagi Grimberg <sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>,
linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Cc: Stable <stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Re: [PATCH] IB/srp: Fix possible send queue overflow
Date: Thu, 15 Oct 2015 08:35:17 -0700 [thread overview]
Message-ID: <561FC7B5.8010103@sandisk.com> (raw)
In-Reply-To: <1444901206-27462-1-git-send-email-sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
On 10/15/2015 02:26 AM, Sagi Grimberg wrote:
> When using work request based memory registration (fast_reg)
> we must reserve SQ entries for registration and invalidation
> in addition to send operations. Each IO consumes 3 SQ entries
> (registration, send, invalidation) so we need to allocate 3x
> larger send-queue instead of 2x.
>
> Signed-off-by: Sagi Grimberg <sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
> CC: Stable <stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
> ---
> drivers/infiniband/ulp/srp/ib_srp.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/infiniband/ulp/srp/ib_srp.c b/drivers/infiniband/ulp/srp/ib_srp.c
> index d00f819..43b07f7 100644
> --- a/drivers/infiniband/ulp/srp/ib_srp.c
> +++ b/drivers/infiniband/ulp/srp/ib_srp.c
> @@ -488,7 +488,7 @@ static int srp_create_ch_ib(struct srp_rdma_ch *ch)
> struct ib_qp *qp;
> struct ib_fmr_pool *fmr_pool = NULL;
> struct srp_fr_pool *fr_pool = NULL;
> - const int m = 1 + dev->use_fast_reg;
> + const int m = dev->use_fast_reg ? 3 : 1;
> struct ib_cq_init_attr cq_attr = {};
> int ret;
>
Reviewed-by: Bart Van Assche <bart.vanassche-XdAiOPVOjttBDgjK7y7TUQ@public.gmane.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2015-10-15 15:35 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-15 9:26 [PATCH] IB/srp: Fix possible send queue overflow Sagi Grimberg
[not found] ` <1444901206-27462-1-git-send-email-sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2015-10-15 15:35 ` Bart Van Assche [this message]
2015-11-03 18:56 ` Sagi Grimberg
2015-11-05 10:23 ` Sagi Grimberg
2015-11-10 10:35 ` Sagi Grimberg
[not found] ` <5641C859.6070107-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
2015-11-22 13:37 ` Christoph Hellwig
[not found] ` <20151122133704.GA22831-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>
2015-11-24 1:11 ` Bart Van Assche
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=561FC7B5.8010103@sandisk.com \
--to=bart.vanassche-xdaiopvojttbdgjk7y7tuq@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
--cc=stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
/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).