On Wed, 23 Feb 2022 16:10:00 +0000
"ramin.ta...@gd-ms.com" <ramin.ta...@gd-ms.com> wrote:

> -----Original Message-----
> From: Stephen Hemminger <step...@networkplumber.org> 
> If this field is going to be referenced by other cores it needs to be done 
> inside lock or use atomic builtin primitives.
> 
> 
> Mbufs are passed from core to core via rings so in practice there will 1 core 
> accessing it at any time.
> Why should it be locked against multiple access?

More details please? which CPU type? and what type of ring?

If you are using DPDK rings, they use atomic operations which are equivalent to
locks.  

You should experiment with adding thread fence (__atomic_thread_fence) to make
sure this is not your problem.

Reply via email to