Re: [PATCH net v3 2/2] net/mlx5e: Prevent stale XSK buffer release on MPWQE refill retry

Jerome Tollet <[email protected]>
Newsgroups org.kernel.vger.linux-rdma,org.kernel.vger.bpf,org.kernel.vger.linux-kernel,org.kernel.vger.netdev,org.kernel.vger.stable
Message-ID <[email protected]>
Hi Dragos,

Agreed, thanks. I changed the patch to set all skip_release_bitmap bits in
the common error path of mlx5e_xsk_alloc_rx_mpwqe(), consistently with
mlx5e_alloc_rx_mpwqe().

I tested both early and partial allocation failures. With three consecutive
failures on the same MPWQE, the original 16 XSK buffers were released only
once. Retries observed a full bitmap, and a later successful allocation
cleared it. The partial case allocated 8 of 16 replacement buffers before
unwinding.

I also ran a 20-second AF_XDP zero-copy striding-RQ pressure test with the
clean patch. It exercised 1,575,262 XSK buffer allocation failures and
reported no invalid descriptors, WQE errors, or kernel warnings.

I'll send v4 with this change.

Thanks,
Jerome
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.