Re: [PATCH net-next 6/7] net/faraday: Fix phy link irq on Aspeed G5 SoCs

From: Benjamin Herrenschmidt
Date: Wed Sep 21 2016 - 06:43:36 EST

On Wed, 2016-09-21 at 18:48 +0930, Joel Stanley wrote:
> > What line is it out of the PHY ? The PHY IRQ ? If yes then it's meant
> > to be telling you to go look at the PHY registers for a link status
> > change, but only works if the PHY has also been configured
> > appropriately...
> Yep, PHY IRQ.
> > Mostly we ignore those things in Linux and just poll the PHY.
> That's simpler. It's what we're doing on Aspeed systems when using NSCI already.
> The driver is already polling the PHY, I propose we mask out this
> interrupt for all systems. I gave that a run on my ast2500evb and it
> behaved itself.

Right it's the easiest way.

If we want to use interrupts without polling in order to maybe
insignificantly reduce the load in the system, we should then make sure
we configure the IRQ with a matching polarity between the PHY and the
NIC *and* in a way that matches the pull up/down's on the board.

The above is possible but tricky as all the parts have to be right, and
the IRQ configuration of PHYs is basically PHY model specific.

So I'd start with just masking it out.