diff options
author | Shenwei Wang <shenwei.wang@nxp.com> | 2023-05-12 16:38:43 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2023-05-15 10:43:30 +0300 |
commit | 6ead9c98cafcbc6992cf35f0ca393df2c03e3316 (patch) | |
tree | 54506443a7895a3de3c92714a8eed25a8995af6d /drivers/net | |
parent | c83b49383b595be50647f0c764a48c78b5f3c4f8 (diff) | |
download | linux-6ead9c98cafcbc6992cf35f0ca393df2c03e3316.tar.xz |
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: 26312c685ae0 ("net: fec: correct the counting of XDP sent frames")
Signed-off-by: Shenwei Wang <shenwei.wang@nxp.com>
Reviewed-by: Horatiu Vultur <horatiu.vultur@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ethernet/freescale/fec_main.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/net/ethernet/freescale/fec_main.c b/drivers/net/ethernet/freescale/fec_main.c index 241df41d500f..577d94821b3e 100644 --- a/drivers/net/ethernet/freescale/fec_main.c +++ b/drivers/net/ethernet/freescale/fec_main.c @@ -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; } |