public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH net 0/1] Prevent DSA tags from breaking COE
@ 2023-12-18 16:23 Romain Gantois
  2023-12-18 16:23 ` [PATCH net 1/1] net: stmmac: " Romain Gantois
                   ` (3 more replies)
  0 siblings, 4 replies; 22+ messages in thread
From: Romain Gantois @ 2023-12-18 16:23 UTC (permalink / raw)
  To: Alexandre Torgue, Jose Abreu
  Cc: Romain Gantois, David S. Miller, Eric Dumazet, Jakub Kicinski,
	Paolo Abeni, Maxime Coquelin, Miquel Raynal, Maxime Chevallier,
	Sylvain Girard, Pascal EBERHARD, Richard Tresidder, netdev,
	linux-stm32, linux-arm-kernel

Hello everyone,

This is a bugfix for an issue that was recently brought up in two
reports:

https://lore.kernel.org/netdev/c57283ed-6b9b-b0e6-ee12-5655c1c54495@bootlin.com/
https://lore.kernel.org/netdev/e5c6c75f-2dfa-4e50-a1fb-6bf4cdb617c2@electromag.com.au/

The Checksum Offloading Engine of some stmmac cores (e.g. DWMAC1000)
computes an incorrect checksum when presented with DSA-tagged packets. This
causes all TCP/UDP transfers to break when the stmmac device is connected
to the CPU port of a DSA switch.

The main change introduced by this series is a new stmmac dma feature that
stmmac_mac_link_up() can check to detect cores that have DSA-incompatible
COEs. If the flag is set and the netdevice uses DSA, stmmac_xmit() will
complete checksumming in software instead of offloading it.

I've run some iperf3 tests and the TX hotpath performance doesn't seem
to be degraded by the field added to dma_features.

Best Regards,

Romain

Romain Gantois (1):
  net: stmmac: Prevent DSA tags from breaking COE

 drivers/net/ethernet/stmicro/stmmac/common.h     |  1 +
 .../net/ethernet/stmicro/stmmac/dwmac1000_dma.c  |  1 +
 .../net/ethernet/stmicro/stmmac/stmmac_main.c    | 16 +++++++++++++++-
 3 files changed, 17 insertions(+), 1 deletion(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2025-10-20  9:58 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-18 16:23 [PATCH net 0/1] Prevent DSA tags from breaking COE Romain Gantois
2023-12-18 16:23 ` [PATCH net 1/1] net: stmmac: " Romain Gantois
2023-12-19 12:20   ` Vladimir Oltean
2023-12-19 13:07     ` Maxime Chevallier
2023-12-19 14:19       ` Linus Walleij
2023-12-19 16:29         ` Maxime Chevallier
2023-12-19 22:46           ` Vladimir Oltean
2023-12-20  0:43             ` Linus Walleij
2023-12-20 23:00               ` Linus Walleij
2023-12-29 16:11     ` Romain Gantois
2023-12-30 14:17       ` Vladimir Oltean
2023-12-18 16:41 ` [PATCH net 0/1] " Andrew Lunn
2023-12-19  9:50   ` Romain Gantois
2024-01-05  4:37     ` Richard Tresidder
2023-12-19 12:30 ` Vladimir Oltean
2023-12-21  7:40 ` Household Cang
2023-12-22 12:30   ` Vladimir Oltean
2023-12-22 13:22     ` Lucas Pereira
2023-12-22 13:46       ` Vladimir Oltean
2023-12-22 19:08     ` Household Cang
     [not found]     ` <SJ2PR22MB45547404DA1CA10A201B2BE0A294A@SJ2PR22MB4554.namprd22.prod.outlook.com>
2025-10-17  6:56       ` Proxy ARP NetNS Awareness Household Cang
2025-10-20  9:58         ` Nicolas Dichtel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox