Commit c5c3e1bfc9e0 ("net: stmmac: Offload queueMaxSDU from tc-taprio")
was inspired by commit 92a0dcb8427d ("igc: offload queue max SDU from
tc-taprio"), but the igc change does not apply the check to AF_XDP.

xsk_tx_peek_desc() reserves a completion entry. Continuing without
queuing or completing the descriptor leaves the AF_XDP rings imbalanced,
so remove the check from the zero-copy path.

The assumptions is that AF_XDP zero-copy traffic bypasses the qdisc, so
taprio's queueMaxSDU check does not apply to this path.

Fixes: c5c3e1bfc9e0 ("net: stmmac: Offload queueMaxSDU from tc-taprio")
Signed-off-by: Stanislav Fomichev <[email protected]>
---
 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c 
b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index 62de03e65a90..4a82f4351303 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -2710,13 +2710,6 @@ static bool stmmac_xdp_xmit_zc(struct stmmac_priv *priv, 
u32 queue, u32 budget)
                if (!xsk_tx_peek_desc(pool, &xdp_desc))
                        break;
 
-               if (priv->est && priv->est->enable &&
-                   priv->est->max_sdu[queue] &&
-                   xdp_desc.len > priv->est->max_sdu[queue]) {
-                       priv->xstats.max_sdu_txq_drop[queue]++;
-                       continue;
-               }
-
                tx_desc = stmmac_get_tx_desc(priv, tx_q, entry);
                dma_addr = xsk_buff_raw_get_dma(pool, xdp_desc.addr);
                meta = xsk_buff_get_metadata(pool, xdp_desc.addr,
-- 
2.53.0-Meta

Reply via email to