macb: Fix tx completion check
PATCH 1/1 macb: Fix tx completion check
Check the send completion bit for the current packet in the descriptor ring, instead of just the first entry in the ring.
This fixes issues when sending multiple small packets in quick succession, such as with netconsole.
--- drivers/net/macb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/macb.c +1 -1
@@ -132,7 +132,7 @@ static int macb_send(struct eth_device *edev, void *packet, start =get_time_ns (); ret = -ETIMEDOUT ; do { - ctrl = readl(&macb->tx_ring[0].ctrl); + ctrl = readl(&macb->tx_ring[tx_head].ctrl); if (ctrl & MACB_BIT(TX_USED)) { ret = 0; break;
---
base-commit: 1a3be5bdf6329e4e691f1d39461f5157767c7e72
change-id: 20250126-fix-macb-send-3600780f5de8
Best regards,
Signature · 1 line
David Dgien <[email protected]>
Sascha Hauer
AppliedQuoted 8 lines · David Dgien
Check the send completion bit for the current packet in the descriptor ring, instead of just the first entry in the ring.
This fixes issues when sending multiple small packets in quick succession, such as with netconsole.
[...]
Applied, thanks!
[1/1] macb: Fix tx completion check
https://git.pengutronix.de/cgit/barebox/commit/?id=b661aa5ba735 (link may not be stable)
Best regards,
Signature · 1 line
Sascha Hauer <[email protected]>