Hi Andrew,

On Feb 5, 2024, at 8:11 AM, Boyer, Andrew <andrew.bo...@amd.com> wrote:
> 
> I see that cnxk has added inline assembly for the ARM "dsb st" barrier. We, 
> too, would like to add a use of this instruction. Can a helper function be 
> added to the atomics headers?
> 
>> drivers/ml/cnxk/cn10k_ml_dev.h:#define dsb_st ({ asm volatile("dsb st" : : : 
>> "memory"); })

This is not being used. I have submitted a patch to remove the unused code [1]

We have removed the use of ‘dsb *’ as architecture definition does not need it 
for DPDK use cases. rte_wmb() should be enough to guarantee the memory ordering 
while interacting with the devices in DPDK context. I can comment more if you 
can explain your use case.

[1] https://patchwork.dpdk.org/project/dpdk/list/?series=31032
> 
> What would the helper be named, rte_wsb()? I suppose it would be a NOP on all 
> other platforms.
> 
> Maybe we could add something for "dmb st" at the same time and get rid of 
> that assembly, too.
> 
> Thanks,
> Andrew


Reply via email to