One more thing. On 25.04.2019 2:47, William Tu wrote: > +#define unlikely OVS_UNLIKELY > +#define likely OVS_LIKELY > +#define barrier() __asm__ __volatile__("": : :"memory") > +#define smp_rmb() barrier() > +#define smp_wmb() barrier()
You may probably use something like this: #include "ovs-atomic.h" #define barrier() atomic_signal_fence(memory_order_acq_rel) #define smp_rmb() atomic_thread_fence(memory_order_acq_rel) #define smp_wmb() atomic_thread_fence(memory_order_acq_rel) Note: atomic_thread_fence(memory_order_acq_rel) should be a bit stronger than smp_{w,r}mb(), but it's a fair replacement and should be equal to compiler_barrier() on x86 anyway. Best regards, Ilya Maximets. _______________________________________________ dev mailing list d...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-dev