[OpenWrt-Devel] [PATCH] ar71xx: fix 100/10mbps ethernet link issues on mynet range extender
chunkeey at googlemail.com
Tue Jun 9 15:24:41 EDT 2015
On Tuesday, June 09, 2015 09:05:46 AM Florian Fainelli wrote:
> On Jun 9, 2015 7:36 AM, "Christian Lamparter" <chunkeey at googlemail.com>
> > On Wednesday, June 03, 2015 05:20:22 PM Christian Lamparter wrote:
> > > The mynet range extender hardware is suffering from ethernet
> > > link loss when booting with a recent openwrt image. This only
> > > happens on 100mbps links, with 1Gbps speed the link was fine.
> > >
> > > The cause of the problem is that the AR8035 PHY (aka F1E)
> > > requires turning on and off the special TX delay setting
> > > depending on the speed of the link.
> > >
> > > The 10mbps mode only needed the proper pll value, which was
> > > extracted from the vendor code.
> > >
> > > Reported-by: Pascal Paradis
> > > Signed-off-by: Christian Lamparter <chunkeey at googlemail.com>
> > No comments so far (but also, no merge). Ping?
> Actually, I have one question, most PHY s should disable these kinds of
> delays when linking at 10/100Mbits/sec. Is not that working here because
> the registers used have a special behavior (force or override), or is it
> broken at the hardware level?
Oh boy, how can I check (without introducing any "doubt") if this is broken
at the hardware level (I think it is) without specialized hardware? From my
POV I would need something like an ethernet analyzer with 20k price tag.
If it helps: I can run experiments and maybe tell you something about the
device/situation and you can tell me if this code is acceptable (and can
be merged) or if this needs to be done differently.
Something to keep in mind about the device:
Both, the original vendor driver (Atheros' SDK) and the uboot's ethernet
driver, always enable/set the rx delay for every "link up". Both drivers
also modify the tx delay setting for 1000mbps (off) and 100/10mbps(on).
[I can point you to the relevant code in WD's source code if you want].
And now for the funny "bit" about why this problem wasn't discovered
The issue was first spotted in commit: r45439 .
Before this change: the PHY wasn't recognized and the generic phy driver
was used. The generic phy driver obviously doesn't mess with the tx/rx
=> uboot initialized the ethernet and linux simply kept the setting and
it would continue to work. Unless of course the user decided to
replugged the device while linux was running and a different speed
setting was negotiated.
After this change: The PHY is recognized as AT8035. The code in at803x.c
(vanilla source:  and patch ) now overwrites the uboot setting and
forces the tx and rx delay settings to what is supplied by a
=> The problem with the mynet device is that the tx delay needs to be
enabled for 100mbps/10mbps speed and disabled for 1000mbps. Not doing
so results in an unusable ethernet link (verified by Pascal and me).
This is why I think this is a hardware problem. (Furthermore, Sven
Eckelmann (CC'd, he wrote the support for the OM5P-AN - which also uses
the AT8035) doesn't mention any workaround in his commits.
What do you think?
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
More information about the openwrt-devel