diff options
author | Jack Wang <jinpu.wang@cloud.ionos.com> | 2021-06-14 12:03:33 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-07-14 17:56:23 +0300 |
commit | fcd8d6371a469aae96367f82a14870e4beef8b2f (patch) | |
tree | 78a02a24dc9d304a5c38f6c06c64b86cb323e1c1 /samples | |
parent | a9355b201d160aa777d1480911c9ee5c7deeb88b (diff) | |
download | linux-fcd8d6371a469aae96367f82a14870e4beef8b2f.tar.xz |
RDMA/rtrs-srv: Set minimal max_send_wr and max_recv_wr
[ Upstream commit 5e91eabf66c854f16ca2e954e5c68939bc81601e ]
Currently rtrs when create_qp use a coarse numbers (bigger in general),
which leads to hardware create more resources which only waste memory with
no benefits.
For max_send_wr, we don't really need alway max_qp_wr size when creating
qp, reduce it to cq_size.
For max_recv_wr, cq_size is enough.
With the patch when sess_queue_depth=128, per session (2 paths) memory
consumption reduced from 188 MB to 65MB
When always_invalidate is enabled, we need send more wr, so treat it
special.
Fixes: 9cb837480424e ("RDMA/rtrs: server: main functionality")
Link: https://lore.kernel.org/r/20210614090337.29557-2-jinpu.wang@ionos.com
Signed-off-by: Jack Wang <jinpu.wang@cloud.ionos.com>
Reviewed-by: Md Haris Iqbal <haris.iqbal@cloud.ionos.com>
Signed-off-by: Gioh Kim <gi-oh.kim@ionos.com>
Reviewed-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'samples')
0 files changed, 0 insertions, 0 deletions