* [PATCH] IB/srp: Fix possible send queue overflow
@ 2015-10-15 9:26 Sagi Grimberg
[not found] ` <1444901206-27462-1-git-send-email-sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2015-11-03 18:56 ` Sagi Grimberg
0 siblings, 2 replies; 7+ messages in thread
From: Sagi Grimberg @ 2015-10-15 9:26 UTC (permalink / raw)
To: linux-rdma; +Cc: Stable
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@mellanox.com>
CC: Stable <stable@vger.kernel.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;
--
1.7.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] IB/srp: Fix possible send queue overflow
[not found] ` <1444901206-27462-1-git-send-email-sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
@ 2015-10-15 15:35 ` Bart Van Assche
0 siblings, 0 replies; 7+ messages in thread
From: Bart Van Assche @ 2015-10-15 15:35 UTC (permalink / raw)
To: Sagi Grimberg, linux-rdma-u79uwXL29TY76Z2rM5mHXA; +Cc: Stable
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
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] IB/srp: Fix possible send queue overflow
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-11-03 18:56 ` Sagi Grimberg
2015-11-05 10:23 ` Sagi Grimberg
1 sibling, 1 reply; 7+ messages in thread
From: Sagi Grimberg @ 2015-11-03 18:56 UTC (permalink / raw)
To: Doug Ledford; +Cc: linux-rdma, Stable
On 15/10/2015 12:26, 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@mellanox.com>
> CC: Stable <stable@vger.kernel.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;
>
>
Hi Doug,
Kind reminder for picking this up for 4.4
Cheers,
Sagi
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] IB/srp: Fix possible send queue overflow
2015-11-03 18:56 ` Sagi Grimberg
@ 2015-11-05 10:23 ` Sagi Grimberg
2015-11-10 10:35 ` Sagi Grimberg
0 siblings, 1 reply; 7+ messages in thread
From: Sagi Grimberg @ 2015-11-05 10:23 UTC (permalink / raw)
To: Doug Ledford; +Cc: linux-rdma, Stable
>
> Hi Doug,
>
> Kind reminder for picking this up for 4.4
Doug?
Are you planning to pick this up? Note that this patch
is stable material as well.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] IB/srp: Fix possible send queue overflow
2015-11-05 10:23 ` Sagi Grimberg
@ 2015-11-10 10:35 ` Sagi Grimberg
[not found] ` <5641C859.6070107-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
0 siblings, 1 reply; 7+ messages in thread
From: Sagi Grimberg @ 2015-11-10 10:35 UTC (permalink / raw)
To: Doug Ledford; +Cc: linux-rdma, Stable
>>
>> Hi Doug,
>>
>> Kind reminder for picking this up for 4.4
>
> Doug?
>
> Are you planning to pick this up? Note that this patch
> is stable material as well.
Doug? any plans for this patch?
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] IB/srp: Fix possible send queue overflow
[not found] ` <5641C859.6070107-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
@ 2015-11-22 13:37 ` Christoph Hellwig
[not found] ` <20151122133704.GA22831-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>
0 siblings, 1 reply; 7+ messages in thread
From: Christoph Hellwig @ 2015-11-22 13:37 UTC (permalink / raw)
To: Sagi Grimberg; +Cc: Doug Ledford, linux-rdma-u79uwXL29TY76Z2rM5mHXA, Stable
On Tue, Nov 10, 2015 at 12:35:05PM +0200, Sagi Grimberg wrote:
> >Are you planning to pick this up? Note that this patch
> >is stable material as well.
>
> Doug? any plans for this patch?
We should really get this in an into -stable. Bart, can you resend
the series and if it doesn't get picked up next week send it directly
to Linus?
--
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
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] IB/srp: Fix possible send queue overflow
[not found] ` <20151122133704.GA22831-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>
@ 2015-11-24 1:11 ` Bart Van Assche
0 siblings, 0 replies; 7+ messages in thread
From: Bart Van Assche @ 2015-11-24 1:11 UTC (permalink / raw)
To: Christoph Hellwig, Sagi Grimberg
Cc: Doug Ledford, linux-rdma-u79uwXL29TY76Z2rM5mHXA, Stable
On 11/22/2015 05:37 AM, Christoph Hellwig wrote:
> On Tue, Nov 10, 2015 at 12:35:05PM +0200, Sagi Grimberg wrote:
>>> Are you planning to pick this up? Note that this patch
>>> is stable material as well.
>>
>> Doug? any plans for this patch?
>
> We should really get this in an into -stable. Bart, can you resend
> the series and if it doesn't get picked up next week send it directly
> to Linus?
Hi Christoph,
Are you referring to Sagi's patch only or also to my patch series that
fixes error handling ?
Thanks,
Bart.
--
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
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2015-11-24 1:11 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
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
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
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).