Hi, From: Jiawei(Jonny) Wang <jiaw...@nvidia.com> Sent: Friday, July 5, 2024 4:05 PM To: Bing Zhao; Slava Ovsiienko; Dariusz Sosnowski; Ori Kam; Suanming Mou; Matan Azrad; Alexander Kozyrev Cc: dev@dpdk.org; Raslan Darawsheh; sta...@dpdk.org Subject: [PATCH] net/mlx5: fix data access race condition for shared Rx queue
The rxq_data resources were shared for shared Rx queue with the same group and queue ID. The cq_ci:24 of rxq_data was unalignment with other fields in the one 32-bit data, like the dynf_meta and delay_drop. 32bit: xxxx xxxI IIII IIII IIII IIII IIII IIIx ^ .... .... .... .... ...^ | cq_ci | The issue is that while the control thread updates the dynf_meta:1 or delay_drop:1 value during port start, another data thread updates the cq_ci at the same time, it causes the bytes race condition with different thread, and cq_ci value may be overwritten and updated the abnormal value into HW CQ DB. This patch separates the cq_ci from the configuration data spaces, and adds checking for delay_drop and dynf_meta if shared Rx queue if started. Fixes: 02a6195cbe ("net/mlx5: support enhanced CQE compression in Rx burst") Cc: sta...@dpdk.org Signed-off-by: Jiawei Wang <jiaw...@nvidia.com> Acked-by: Bing Zhao <bi...@nvidia.com> Acked-by: Viacheslav Ovsiienko <viachesl...@nvidia.com> Patch applied to next-net-mlx, Kindest regards, Raslan Darawsheh