I have 2 Boundary Devices SABRE Lite boards with the latest and greatest Freescale L3.0.35_4.0.0 kernel installed on both. But, I'm having a problem establishing network connectivity on one of my boards because it keeps reporting "Link is up" and then "Link is down" (i've tried switching out ethernet cables and checking the switch that the devices a plugged into to make sure it was working). It eventually stops reporting "Links is up" and "Link is down" after some time, with a "MDIO read timeout mii_id=6" error within the system log. Here are two things that I notice when comparing the 2 boards:
I did google this issue and found that others were having this issue 1-2 years ago on the Freescale 2.6.35 kernel, but patches were created/submitted and the problem resolved. I looked at some of the patches to see if I could apply them, but a lot has changed in the kernel since 2.6.35 and 3.0.35. So I didn't bother.
Has anyone else experience this issue on this device with the latest Freescale kernel? Could this possibly be a regression? Any insight and/or guidance would be greatly appreciated. Thanks in advance.
Is the Freescale 3.0.35 kernel (and associated drivers) not related to iMX? Because it is looking liked the kernel's ethernet driver has a bug of some kind. I've done some more experiments and it's looking like a kernel regression for the ethernet driver.
Message was edited by: Donald Poole, Jr.
Message was edited by: Donald Poole, Jr.
but if you see the same messages on your x86 host, why do you think it is iMX related? Perhaps I am not understanding the problem correctly. Regarding the Kernel, there are many iMX's commits, specially on the driver area.
My error in misunderstanding your earlier question. I actually don't see the same messages repeatedly reported on my x86 host. Just on one of my iMX ARM SABRE Lite boards (boundary devices). I was trying to see if anyone else experienced the same issue on the SABRE Lite with a Debian rootfs and the latest Freescale Kernel (4.0.0).
No clue, but we've had multiple reports of this, and always from those using Debian.
My best guess at the moment is that Debian is either hitting the PHY driver differently from other distributions or that it's doing this on purpose for some reason.
I'm going to grab a Debian HF image and test this out.
Meanwhile, Donald, can you forward the syslog output of a boot when this is happening? That may provide some clues.
Just for grins, I install the ubuntu 13.04 hard-float image with the Freescale 4.0.0 kernel, and the same issue was exhibited. So, I did some further digging and swapped my switch for another switch (both switches are 10/100) and the same issue occured (I tested this on both SABRE Lite boards I have). I then found a Gigabit switch and the problem went away (both SABRE Lite boards masterfully established a Gigabit link). So, it seems that the Freescale driver has a problem negotiating link speeds for anything less than a Gigabit connection. But, the driver does support 10/100/1000 link speeds. Unfortunately, I just can't switch to my Gigabit switch because my current project doesn't call for one.
Is there a known issue with the ethernet driver for the SABRE Lite not being able to properly negotiate links speeds less than a Gigabit?
There aren't any known issues with 10/100, though the time-to-link is generally higher on 10/100 switches.
There is a U-Boot environment variable called 'disable_giga' that will disable Gb and might help:
U-Boot > setenv disable_giga 1 U-Boot > saveenv && reset
Thanks for the info regarding the disable_giga environment variable, but it still didn't help. I'm still getting the "Link is up" / "Link is down" issue. Your correct that the time-to-link is higher (several orders of magnitude higher), but even if/when the link is established, it drops it randomly (I've verified this on several 10/100 switches). I'm completely out of ideas on how to resolve this issue, but I really need a stable 10/100 link to move forward on my project.
Do you have any other ideas for me to try or any other insight?
Thanks for your response. This issue is occurring right after booting the kernel and bringing up the network interface. So, the board should be "cold" if not at operating temperature. But, the board that I left running over the weekend reports 61. I'm assuming this number is units of celsius?
I'm unable to repeat this.
I grabbed this image:
As discussed on this page:
And overlaid this kernel:
Things just worked on several boards.
Note that I did have to add a line into /etc/inittab to get a serial login:
T0:23:respawn:/sbin/getty -L ttymxc1 115200 vt100
I also had to add an entry into /etc/network/interfaces for each new board I booted.
auto eth1 iface eth1 inet dhcp auto eth2 iface eth2 inet dhcp
To test, I grabbed iperf and saw a pretty stable 450+Mb/s upload and 550+Mb/s download.
Can you confirm the origin of your Debian image?
I deployed the http://s3.armhf.com/debian/wheezy/imx/debian-wheezy-7.0.0-armhf-minfs-3.9.1-imx4.img.xz and overlaid this kernel you pointed to, but I still get the "Link is up" / "Link is down" messages in my syslog as seen here. Although, it behaves a little different with that image. Before, the board would display the link up/down messages and eventually (after 1-3 minutes) establish a link and keep the link. Now, with the new Debian image, and the Freescale Kernel, the board will keep dropping and re-establishing its link. It's very strange.