I have tried the following under several Linux kernels and builds for the AM335x and seen the same behavior. The board that I am using is the Beaglebone.
The sequence is:
- Connect Ethernet cable and verify that pinging other PCs works
- Disconnect Ethernet cable. See "PHY: 0:00 - Link is Down" message
- Run "ifdown eth0"
- Reconnect the Ethernet cable. Every once in a while, you'll see "PHY: 0:00 - Link is Up - 100/Full". If you see this, things will work.
- Run "ifup eth0".
- Check if pings work
Almost all of the time on step #4, I will not get the "Link is Up" message so steps 5 and 6 will fail. However, every once in a while, it does work. I haven't been able to characterize what I do differently between trials.
If "ifdown eth0" is not called, the cable can be removed and reconnected and pings will still work. Obviously, the interface isn't in the correct state when the cable is removed, but this at least works.
I was wondering whether this was a known problem on other AM335x boards or if a solution was available.
Thanks,
Frank