DORMANTno replies

[RFC PATCH net] net: stmmac: Fix hardware TX timestamping on queue with tc-etf enabled

From: Vladimir Oltean <olteanv@gmail.com>
Date: 2021-03-10 15:11:29
Subsystem: networking drivers, stmmac ethernet driver, the rest · Maintainers: Andrew Lunn, "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Maxime Chevallier, Linus Torvalds

After commit 29d98f54a4fe ("net: enetc: allow hardware timestamping on
TX queues with tc-etf enabled"), I went through the other drivers that
offload tc-etf, and I believe I found a similar bug in stmmac.

Fixes: 579a25a854d4 ("net: stmmac: Initial support for TBS")
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
---
 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 1 +
 1 file changed, 1 insertion(+)
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index 208cae344ffa..1393898a7d6d 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -3636,6 +3636,7 @@ static netdev_tx_t stmmac_xmit(struct sk_buff *skb, struct net_device *dev)
 
 		tbs_desc = &tx_q->dma_entx[first_entry];
 		stmmac_set_desc_tbs(priv, tbs_desc, ts.tv_sec, ts.tv_nsec);
+		skb->tstamp = ktime_set(0, 0);
 	}
 
 	stmmac_set_tx_owner(priv, first);
-- 
2.25.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help