Commit 61da6ac7 authored by Ong Boon Leong's avatar Ong Boon Leong Committed by Jakub Kicinski

net: stmmac: perserve TX and RX coalesce value during XDP setup

When XDP program is loaded, it is desirable that the previous TX and RX
coalesce values are not re-inited to its default value. This prevents
unnecessary re-configurig the coalesce values that were working fine
before.

Fixes: ac746c85 ("net: stmmac: enhance XDP ZC driver level switching performance")
Signed-off-by: default avatarOng Boon Leong <boon.leong.ong@intel.com>
Tested-by: Kurt Kanzenbach's avatarKurt Kanzenbach <kurt@linutronix.de>
Link: https://lore.kernel.org/r/20211124114019.3949125-1-boon.leong.ong@intel.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 739752d6
......@@ -6519,6 +6519,9 @@ int stmmac_xdp_open(struct net_device *dev)
tx_q->tx_tail_addr = tx_q->dma_tx_phy;
stmmac_set_tx_tail_ptr(priv, priv->ioaddr,
tx_q->tx_tail_addr, chan);
hrtimer_init(&tx_q->txtimer, CLOCK_MONOTONIC, HRTIMER_MODE_REL);
tx_q->txtimer.function = stmmac_tx_timer;
}
/* Enable the MAC Rx/Tx */
......@@ -6527,8 +6530,6 @@ int stmmac_xdp_open(struct net_device *dev)
/* Start Rx & Tx DMA Channels */
stmmac_start_all_dma(priv);
stmmac_init_coalesce(priv);
ret = stmmac_request_irq(dev);
if (ret)
goto irq_error;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment