mirror of
https://github.com/torvalds/linux.git
synced 2026-12-02 11:34:58 +00:00
net: fec: remove the xdp_return_frame when lack of tx BDs
In the implementation, the sent_frame count does not increment when
transmit errors occur. Therefore, bq_xmit_all() will take care of
returning the XDP frames.
Fixes: 26312c685a ("net: fec: correct the counting of XDP sent frames")
Signed-off-by: Shenwei Wang <[email protected]>
Reviewed-by: Horatiu Vultur <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
committed by
David S. Miller
parent
c83b49383b
commit
6ead9c98ca
@@ -3798,7 +3798,6 @@ static int fec_enet_txq_xmit_frame(struct fec_enet_private *fep,
|
||||
entries_free = fec_enet_get_free_txdesc_num(txq);
|
||||
if (entries_free < MAX_SKB_FRAGS + 1) {
|
||||
netdev_err(fep->netdev, "NOT enough BD for SG!\n");
|
||||
xdp_return_frame(frame);
|
||||
return NETDEV_TX_BUSY;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user