mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-11-22 14:19:57 +08:00
CONFIG_NET_ETH_PKTSIZE includes the 14 byte Ethernet header but not the
4 byte FCS, so the IP MTU is PKTSIZE - 14. With 1518 the MTU was 1504,
larger than the 1500 bytes defined by RFC 894.
ETH header | IP packet (IP | UDP/TCP | payload)
14 | 1500
On the STM32H7 and STM32F7 Ethernet drivers the RX buffer stays 1536
bytes, so full-size frames incl. FCS still fit. ESP32 (Wi-Fi only) uses
the value only for its TX buffer.
Applied to all STM32H7, STM32F7 and ESP32 boards.
i.MX RT (ENET MAX_FL) and S32K3 (RX DMA buffer size) boards are left at 1518,
since there the value also sets hardware limits and 1514 would reject or
truncate full-size frames.
Signed-off-by: Marin Doetterer <marin@auterion.com>
Assisted-by: Claude Opus 5.5