AM6442: Ethernet sometimes not transmitting icssg-prueth, Marvell 88E1510 PHY

Part Number: AM6442

Tool/software:

Sometimes, after a reboot, the system enters a mode where the ethernet does not transmit any packets.

This happens once in every 500 reboot approximately.

We are using:
phyCORE-AM64x module
TI SDK version: 10.01.10
Linux kernel version: 6.12.43
The driver is icssg-prueth from upstream linux kernel without changes.
The problem is observed on icssg ethernet using the Marvell 88E1510 PHY.

This is the output of "dmesg|grep mdio":

[ 2.267948] davinci_mdio 300b2400.mdio: Configuring MDIO in manual mode
[ 2.301883] davinci_mdio 300b2400.mdio: davinci mdio revision 1.7, bus freq 1000000
[ 2.331776] davinci_mdio 8000f00.mdio: Configuring MDIO in manual mode
[ 2.365887] davinci_mdio 8000f00.mdio: davinci mdio revision 9.7, bus freq 1000000
[ 2.416637] davinci_mdio 300b2400.mdio: Configuring MDIO in manual mode
[ 2.449883] davinci_mdio 300b2400.mdio: davinci mdio revision 1.7, bus freq 1000000
[ 2.477761] davinci_mdio 300b2400.mdio: phy[0]: device 300b2400.mdio:00, driver Marvell 88E1510
[ 2.477774] davinci_mdio 300b2400.mdio: phy[1]: device 300b2400.mdio:01, driver Marvell 88E1510
[ 2.480584] davinci_mdio 8000f00.mdio: Configuring MDIO in manual mode
[ 2.513883] davinci_mdio 8000f00.mdio: davinci mdio revision 9.7, bus freq 1000000
[ 2.527707] davinci_mdio 8000f00.mdio: phy[1]: device 8000f00.mdio:01, driver TI DP83867
[ 37.808149] Marvell 88E1510 300b2400.mdio:01: attached PHY driver (mii_bus:phy_addr=300b240
0.mdio:01, irq=POLL)
[ 37.921228] Marvell 88E1510 300b2400.mdio:00: attached PHY driver (mii_bus:phy_addr=300b240
0.mdio:00, irq=POLL)
[ 39.192357] am65-cpsw-nuss 8000000.ethernet eth2: PHY [8000f00.mdio:01] driver [TI DP83867]
(irq=461)

The Problem:

When I try to ping another device, the ARP request is sent to the ethernet interface and it is seen with tcpdump but it does not arrive on the other computer.

When I ping the AM6442 device form another computer, the ping request arrives on the am6442 and it replies with the ICMP reply (they are both seen with tcpdump running on am6442) but the response does not arrive on the other computer.

In short, receives appear to work but transmits do not work.

I do not know of any way to recover from this state other than reboot.

Here are ip link stats:
4: eth0: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 1500 qdisc mq master bond0 state UP mode DEFAULT group default qlen 1000
link/ether f0:bd:2e:ff:00:a2 brd ff:ff:ff:ff:ff:ff
RX: bytes packets errors dropped missed mcast
55314 613 0 0 0 613
RX errors: length crc frame fifo overrun
0 0 0 0 0
TX: bytes packets errors dropped carrier collsns
87790 942 0 1 0 0

And these are ethtool -S stats:
NIC statistics:
rx_broadcast_frames: 0
rx_mii_error_frames: 0
rx_odd_nibble_frames: 0
rx_max_size_error_frames: 0
rx_min_size_error_frames: 171
rx_class0_hits: 798
rx_class1_hits: 0
rx_class2_hits: 0
rx_class3_hits: 0
rx_class4_hits: 0
rx_class5_hits: 0
rx_class6_hits: 0
rx_class7_hits: 0
rx_class8_hits: 798
rx_class9_hits: 798
rx_class10_hits: 0
rx_class11_hits: 0
rx_class12_hits: 0
rx_class13_hits: 0
rx_class14_hits: 0
rx_class15_hits: 0
rx_smd_frags: 0
rx_tx_total_bytes: 154029
tx_broadcast_frames: 6
tx_multicast_frames: 100
tx_odd_nibble_frames: 0
tx_underflow_errors: 0
tx_max_size_error_frames: 0
tx_min_size_error_frames: 0

This issue is related to another issue. The setup sometimes triggers this TX problem or the RX problem described in the other issue:
AM6442: Ethernet fails to receive ipv6 neighbour solicitation packets (1 out of 50 reboots on average) - Processors forum - Processors - TI E2E support forums