On 06/01/2017 06:45 AM, Zefir Kurtisi wrote:
I guess we need to decide whether we generally need to handle permanent aneg
failures on the SGMII link. If we expect that it must not fail (like we assumed
until we saw it failing), I agree with Timur and support reverting of the 
related
commit f62265b53e. If otherwise we want this potential failure to be handled
correctly, things become arbitrary complex. Essentially, we need to handle such
PHYs as a combination of their two sides (copper + SGMII) as virtual sub-PHYs. 
The
phylib might support that in a future version, but for now this seems like a lot
of work required to handle a rare problem.

I'm about to post a patch that removes interrupt support from the EMAC driver and relies on software polling of the PHY. With this patch, we don't see the "link is not okay" message from that at803x driver any more.

The link state is generally more reliable now, even when the at803x driver doesn't complain.

My theory is that the hardware polling of the PHY is just too aggressive. I think it continuously reads the PHY status register at maximum speed and immediately issues an interrupt when the PHY says that it's up.

So I think we're okay with leaving the at803x driver as-is, since we appear to be no longer getting any false failures.

--
Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the
Code Aurora Forum, a Linux Foundation Collaborative Project.

Reply via email to