[PATCH net v2 0/2] net: stmmac: Limit the MTU of normal descriptors to one buffer

Arun Iyengar via B4 Relay devnull+aiyengar1990.gmail.com at kernel.org
Sun Nov 22 01:13:46 PST 2026


Normal descriptors take frames of at most one 2047-byte buffer, but
max_mtu allows 3712 on arm64. Patch 1 limits it in the core, patch 2
limits dwmac-sun8i further to the 2044 bytes its RX DMA fills.

Tested on an Orange Pi Zero2 (H616) on net/main. Without the patches,
MTU 2029 to 2100 is accepted and ping gets no reply. With patch 1 the
maximum is 2021, with both 2018. UDP and ping are lossless up to the
maximum, and larger MTUs are refused. Ring mode and other cores are
untested.

Claude (AI) helped write these patches; I reviewed and tested them.

Signed-off-by: Arun Iyengar <aiyengar1990 at gmail.com>
---
Changes in v2:
- Limit normal descriptors in the core (patch 1, Andrew Lunn, Maxime
  Chevallier), keep the lower sun8i limit as patch 2
- Link to v1: https://patch.msgid.link/20261121-sun8i-emac-mtu-limit-v1-1-22492842d318@gmail.com

---
Arun Iyengar (2):
      net: stmmac: Limit the MTU of normal descriptors to one buffer
      net: stmmac: dwmac-sun8i: Limit the MTU to 2018

 drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 1 +
 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 3 +++
 2 files changed, 4 insertions(+)
---
base-commit: 890f23ba87a7ca1aba97c8320770a686e3b689fb
change-id: 20261121-sun8i-emac-mtu-limit-66a936064965

Best regards,
--  
Arun Iyengar <aiyengar1990 at gmail.com>





More information about the linux-arm-kernel mailing list