net/mlx5: fix synchronization on polling Rx completions
authorYongseok Koh <yskoh@mellanox.com>
Thu, 25 Jan 2018 21:02:50 +0000 (13:02 -0800)
committerThomas Monjalon <thomas@monjalon.net>
Sun, 28 Jan 2018 07:30:36 +0000 (08:30 +0100)
commit1742c2d9fab07e66209f2d14e7daa50829fc4423
treed2060a9091a45d9e1745c47134bf77902ab17009
parent4fe7f662ac5c71c8433d96e16b144719924dfceb
net/mlx5: fix synchronization on polling Rx completions

Polling a new packet is basically sensing the generation bit in a
completion entry. For some processors not having strongly-ordered memory
model, there has to be a memory barrier between reading the generation bit
and other fields of the entry in order to guarantee data is not stale.

Fixes: 570acdb1da8a ("net/mlx5: add vectorized Rx/Tx burst for ARM")
Cc: stable@dpdk.org
Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
drivers/net/mlx5/mlx5_rxtx.c
drivers/net/mlx5/mlx5_rxtx_vec_neon.h
drivers/net/mlx5/mlx5_rxtx_vec_sse.h