I'm in a situation where my `RGMII TX_CLK` is seemingly stuck at 2.5MHz even when the PHY negotiates with a 100baseT or 1000baseT line and the link comes up. How is that even possible and what could be the cause for this? I'm usinfg a Microsemi VAC8531 PHY and it appears to work as it should.
The PHY receives the RX_CLK properly at 2.5, 25 or 125MHz (while the TX_CLK remains at 2.5MHz). I can use tcpdump and monitor traffic on the line at all speeds but am unable to send anything (not even when connected to a 10baseT peer, no data seem to go out onto the wire in TX direction)
I can see the network interface with `ifconfig` in Linux but its TX counters stay at 0 traffic gets sent to the `lo` interface instead where it just gets looped back, which makes it look like: # ifconfig eth0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500 metric 1 inet 192.168.1.123 netmask 255.255.255.0 broadcast 192.168.1.255 ether 0e:7a:54:e7:1a:ff txqueuelen 1000 (Ethernet) RX packets 84 bytes 9691 (9.4 KiB) RX errors 0 dropped 23 overruns 0 frame 0 TX packets 0 bytes 0 (0.0 B) TX errors 0 dropped 0 overruns 0 carrier 1 collisions 0 device interrupt 170 lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 metric 1 inet 127.0.0.1 netmask 255.0.0.0 loop txqueuelen 1000 (Local Loopback) RX packets 118 bytes 10336 (10.0 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 118 bytes 10336 (10.0 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
This is after I sent pings to the other host at `192.168.1.222` while my routing table looks all fine:
# route Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 192.168.1.0 * 255.255.255.0 U 0 0 0 eth0
I connected a host that I forced to 10baseT point-to-point and got a link up signal yet, no data would go onto the TX line on `eth0`.My `ethtool` line to set it to 10Mbps looked like:# ethtool -e eth0 speed 10 duplex half autoneg offand I confirmed link information with# mii-tool -vv eth0As for bad hardware, I doubt it, not broken anyways, it's possible that there is a hardware problem but I need to find out more details first, as it seems to "almost" work. What could be bad to get effects as described?I've also tried to fix to 100baseT:both peers: # ethtool -s eth0 speed 100 duplex half autoneg offthen:# mii-tool -vv eth0 Using SIOCGMIIPHY=0x8947 eth0: 100 Mbit, half duplex, link ok registers for MII PHY 0: 2000 794d 0007 0572 01e1 c021 0004 2001 6001 0300 4000 0000 0000 0000 0000 3000 9000 0000 00b8 0000 0000 0000 3201 1000 0000 a020 a000 0000 e00d 0021 0400 0000 product info: vendor 00:01:c1, model 23 rev 2 basic mode: 100 Mbit, half duplex basic status: link ok capabilities: 1000baseT-HD 1000baseT-FD 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD advertising: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD link partner: 10baseT-HDand I still measure a 2.5MHz clock on the RGMII TX_CLK pin from the MPU. I also tried a different set of hardware, just in case and I get the same frequency on the TX_CLK pin.
I then also found this:
and it would be very interesting to tap into every stage 1 - 6 to see what's going on, is that possible by any chance?
Just to be fully transparent, there's a parallel post on stackexchance already and I will keep replies in sync as they become available: networking - RGMII TX_CLK stuck at 2.5MHz - Super User
For the benefit of everyone who could be interested, this was solved by disabling interrupts, i.e. removing these lines:
interrupt-parent = <&pinctrl>; interrupts = <RZG2L_GPIO(1, 0) IRQ_TYPE_LEVEL_LOW>;
from the device tree.