On Thu, Oct 15, 2020 at 5:10 PM Eli Britstein <el...@nvidia.com> wrote: > > The cited commit introduced functions with 'int memory_order' argument. > The C11 standard section 7.17.1.4 defines 'memory_order' as the > "enumerated type whose enumerators identify memory ordering constraints". > > A compilation error occurs: > error: declaration of 'memory_order' shadows a global declaration > [-Werror=shadow] > rte_atomic_thread_fence(int memory_order) > > This issue was hit when trying to compile OVS with gcc 4.8.5. This > compiler version does not provide stdatomic.h, so enum memory_order is > redefined in OVS code. > In another case, if the compiler does provide stdatomic.h header, > passing -Wsystem-headers in the CFLAGS will also cause that failure. > > Fix it by changing the argument name 'memory_order' to 'memorder'. > > Fixes: 672a15056380 ("eal: add wrapper for C11 atomic thread fence") > > Signed-off-by: Eli Britstein <el...@nvidia.com>
Please, report previous review/acks, and thread replies with original. Reviewed-by: Asaf Penso <as...@nvidia.com> Acked-by: Thomas Monjalon <tho...@monjalon.net> Acked-by: David Marchand <david.march...@redhat.com> Reviewed-by: Honnappa Nagarahalli <honnappa.nagaraha...@arm.com> Applied, thanks. -- David Marchand