FS#687 - Meraki MR24: Ethernet interface not detected correctly if cable not plugged at boot time #5800
Meraki MR24 (apm821xx)
Tested reboot-3921-g3169a6a7ad, but it's been a problem since at least last September.
Disconnect ethernet cable, apply power, wait until device has booted, plug in ethernet, check for interfaces, no eth0 is listed.
This appears to be a problem during probing of the AR8035 Phy chip. When ethernet has no link, the phy detection fails, and eth0 is not created. Plugging ethernet later has no effect, because there is no interface as far as the kernel is concerned. The relevant part of the boot log looks like this:
this is the failing case:
and the succeeding case:
The text was updated successfully, but these errors were encountered:
I don't have a MR24 myself. But I know that the MyBook Live. (Same single RGMII PHY setup, but with a Broadcom PHY BCM54610) doesn't have a problem with detecting the PHY during startup, even if no ethernet cable is connected to it. I've tested todays image from downloads.lede-project.org: r3925-64175ff
Since I think this is something specific to the MR24 and since you said "but it’s been a problem since at least last September.". I think it must have been a issue from the beginning. Is this correct? Or do you remember an older version, were this was working as intended?
As for debugging this. Is this phy detection error just a problem during boot-time? Or does it persist? I think you could test this by unbinding and rebinding the emac driver as root when the MR24 has finished booting and is running:
If the PHY is still not detected, then it has to be something else.
(maybe the bootloader disables the PHY via GPIO? Does Cisco advertise such a feature? In that case a dump of /sys/kernel/debug/gpio with and w/o ethernet cable attached during boot might help).
I am unaware if it ever worked. I think my initial foray into MR24 things dates from the same September period.
I tried the bind/unbind. With ethernet unplugged at boot time, then plugged in, and running the suggested command, I get this:
With ethernet plugged at boot time, I see this:
With the MR24 booted with no ethernet, the GPIOs dump as follows:
With ethernet plugged at boot time, I get these GPIOs:
I see gpio-497 has s different state, which is interesting.
When booted with ethernet unplugged:
Then trying to bind:
When booted with ethernet plugged:
Then unbind, ls, bind with cable still plugged:
Now, remove the ethernet and repeat:
Chris Blake was also able to reproduce this issue with his unit. Problem is we are currently stuck on what's going on with regards to the AR8035.
It's likely that the u-boot is powering down the (inactive) phy before handing
I think in order to debug this, it will be necessary to look what is happening to the phy chip. Can you probe the individual pins of the chip with a digital oscilloscope? The most important pins would be the reset pin (Pin 1), the XI clocks (Pin 5 and Pin 4). Of course it would be better, if you can also probe the MDC/MDIO(pin 40 and pin 39) and see if u-boot is disabling the PHY and how.
you can find a datasheet with the pinout with google
The Pinout is on page 4. The Power-on Sequence is explained on page 26.
Note: We looked into meraki-linux's source as well. But there are no modifications to the emac driver, apart from adding the PHY to the list of known phys. I don't have a MR24 myself, but given this information, I wonder what Meraki's stock firmware is doing in this case. Can you reflash the original firmware and provide a bootlog? Just in case there's some note or hint in it.