[PATCH net-next 0/2] net: axienet: fix DMA Tx error

Andy Chiu andy.chiu at sifive.com
Sun Jun 12 20:42:00 PDT 2022


We ran into multiple DMA TX errors while writing files over a network
block device running on top of a DMA-connected AXI Ethernet device on
64-bit RISC-V machines. The errors indicated that the DMA had fetched a
null descriptor and we found that the reason for this is that AXI DMA had
unexpectedly processed a partially updated tail descriptor pointer. To
fix it, we suggest that the driver should use one 64-bit write instead
of two 32-bit writes to perform such update if possible. For those
archectures where double-word load/stores are unavailable, e.g. 32-bit
archectures, force a driver probe failure if the driver finds 64-bit
capability on DMA.

Andy Chiu (2):
  net: axienet: make the 64b addresable DMA depends on 64b archectures
  net: axienet: Use iowrite64 to write all 64b descriptor pointers

 drivers/net/ethernet/xilinx/xilinx_axienet.h  | 51 +++++++++++++++++++
 .../net/ethernet/xilinx/xilinx_axienet_main.c | 28 ++--------
 2 files changed, 55 insertions(+), 24 deletions(-)

-- 
2.36.0




More information about the linux-arm-kernel mailing list