Re: [PATCH net-next 0/2] net/smc: transition to RDMA core CQ pooling
From: Mahanta Jambigi
Date: Fri Jun 12 2026 - 01:11:37 EST
On 03/06/26 2:33 am, Jakub Kicinski wrote:
> On Thu, 28 May 2026 16:48:17 +0800 D. Wythe wrote:
>> This series transitions SMC-R completion handling to RDMA core CQ pooling
>> via the ib_cqe API. The new completion model improves scalability by
>> allowing per-link completion processing across multiple cores and enables
>> DIM-based interrupt moderation.
>>
>> As a side effect, the increased concurrency can amplify contention for TX
>> slots on the shared wait queue. Patch 2 addresses this by switching TX slot
>> allocation from non-exclusive wait_event() to prepare_to_wait_exclusive(),
>> which avoids thundering-herd wakeups under contention.
>>
>> Patch 1 replaces the global per-device CQ and manual tasklet polling model
>> with RDMA core CQ pooling.
>> Patch 2 reduces TX slot contention by using exclusive wait queue entries
>> during allocation.
>
> Sashiko reports a couple of issues on patch 1:
> https://sashiko.dev/#/patchset/20260528084819.6059-2-alibuda@xxxxxxxxxxxxxxxxx
> Are these legit?
>
> Either way - would be good to get some reviews here from (ohter) SMC
> maintainers.
D Wythe - Thank you for addressing Sashiko's comments.
I've reviewed the three issues raised by Sashiko for Patch 1 and your
responses:
Issue #1: Acknowledged, will be fixed in v3. I agree with your proposal
of using "max_send_wr = 3 * lnk->lgr->max_send_wr + *3*;"
Issue #2: I agree this is a pre-existing issue unrelated to this patch
series. The potential memory leak and NULL pointer de-reference in
smc_wr_tx_put_slot() should be addressed in a separate patch to keep the
scope focused.
Issue #3: Acknowledged, will be fixed in v3. I agree that ib_drain_qp()
introduced in this patch does open a UAF window.
I am looking forward for v3.