summaryrefslogtreecommitdiff
path: root/include/linux/platform_data
diff options
context:
space:
mode:
authorQuanye Yang <quanyeyang@proton.me>2026-10-05 02:01:15 -0700
committerLeon Romanovsky <leon@kernel.org>2026-10-11 06:55:56 -0400
commit3255d6b83491574b115806ec958d8f6ca090fa9c (patch)
treeb7f30a52ba2d0c9b6fa66816e57d8fcd75689dc4 /include/linux/platform_data
parentd2c08575500145dc5cb55075cd9b177626531613 (diff)
downloadlinux-next-3255d6b83491574b115806ec958d8f6ca090fa9c.tar.gz
linux-next-3255d6b83491574b115806ec958d8f6ca090fa9c.zip
RDMA/rtrs-clt: Fix recv repost to satisfy ib_drain_rq
On disconnect the client error recovery path calls ib_drain_qp(), which requires one free RQ slot and that no recv WQEs are posted while the queue is being drained. When the server is loaded with always_invalidate=N, the path does not advertise RTRS_MSG_NEW_RKEY_F. A client-requested invalidation is then a standalone SEND_WITH_INV. The recv completion path did not repost that WQE; it posted two empty recv WQEs later, when the RDMA-with-IMM response carried RTRS_IO_RSP_W_INV_IMM. If the invalidate receive never arrived, each such response increased RQ occupancy by one until ib_post_recv() started returning -ENOMEM and __ib_drain_rq() failed with: failed to drain recv queue: -12 Repost one empty recv WQE for every receive completion, including SEND_WITH_INV completions on the always_invalidate=N path, and only while the path is still connected so CQ polling cannot race with ib_drain_qp(). Size IO connection RQs to 2 * queue_depth + 1 to match the posted recv count and leave the drain slot. Tested with a synthetic RTRS client flooding unpaired RTRS_IO_RSP_W_INV_IMM messages; error recovery no longer triggers __ib_drain_rq() warnings. Fixes: 6a98d71daea1 ("RDMA/rtrs: client: main functionality") Signed-off-by: Quanye Yang <quanyeyang@proton.me> Link: https://lore.kernel.org/linux-rdma/CA+0ovCihE2_pxLimjmmR8NMz4g-ie8dvvq1jmAj-Om33y3Vzfg@mail.gmail.com Link: https://patch.msgid.link/20261005-rtrs-fix-ib-drain-rq-v2-1-35535a3ed115@proton.me Tested-by: Quanye Yang <quanyeyang@proton.me> Reported-by: Farhad Alemi <farhad.alemi@berkeley.edu> Acked-by: Jack Wang <jinpu.wang@cloud.ionos.com> Signed-off-by: Leon Romanovsky <leon@kernel.org>
Diffstat (limited to 'include/linux/platform_data')
0 files changed, 0 insertions, 0 deletions