net: axienet: add missing memory barriers
authorRobert Hancock <robert.hancock@calian.com>
Tue, 18 Jan 2022 21:41:27 +0000 (15:41 -0600)
committerDavid S. Miller <davem@davemloft.net>
Wed, 19 Jan 2022 11:29:14 +0000 (11:29 +0000)
commit95978df6fa328df619c15312e65ece469c2be2d2
tree44cda26598821c948e598ea2ad01195484948e4f
parent04cc2da39698efd7eb2e30c112538922d26f848e
net: axienet: add missing memory barriers

This driver was missing some required memory barriers:

Use dma_rmb to ensure we see all updates to the descriptor after we see
that an entry has been completed.

Use wmb and rmb to avoid stale descriptor status between the TX path and
TX complete IRQ path.

Fixes: 8a3b7a252dca9 ("drivers/net/ethernet/xilinx: added Xilinx AXI Ethernet driver")
Signed-off-by: Robert Hancock <robert.hancock@calian.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/xilinx/xilinx_axienet_main.c