Tool/software: Linux
Hi,
Latest SDK Linux-rt 05.01.00.11 CPSW driver drop minimum size (64 byte) Ethernet packets, report them as misaligned/code error packets, but the previous version 04.02.00.09 does not have this issue. Compare the driver code (cpsw.c), I found this is cause by the change of minimum and maximum packet size definition in cpsw.c:
cpsw.c 04.02.00.09 compared with 05.01.00.11:
123,124c124,128
< #define CPSW_MIN_PACKET_SIZE 60
< #define CPSW_MAX_PACKET_SIZE (1500 + 14 + 4 + 4)
---
> #define CPSW_RX_VLAN_ENCAP_HDR_SIZE 4
> #define CPSW_MIN_PACKET_SIZE (VLAN_ETH_ZLEN)
> #define CPSW_MAX_PACKET_SIZE (VLAN_ETH_FRAME_LEN +\
> ETH_FCS_LEN +\
> CPSW_RX_VLAN_ENCAP_HDR_SIZE)
Here VLAN_ETH_ZLEN is 64, so CPSW_MIN_PACKET_SIZE changed from 60 to 64, that cause the problem.
BTW, I think CPSW_MAX_PACKET_SIZE is also wrong, it changed from 1522 to 1526, the reason is checksum length counted twice.
Please check.
Regards,
Jun