Subject: Re: [PATCH] net: mvneta: only do WoL speed down if the PHY is valid

From: Russell King - ARM Linux admin <[email-masked]>
Date: Thu, 21 May 2020 19:20:10 +0100

On Thu, May 21, 2020 at 05:55:13PM +0200, Andrew Lunn wrote:
> > I hope the patch adding pp->dev->phydev hasn't been merged as it's
> > almost certainly wrong.
> 
> Hi Russell
> 
> It was merged :-(
> 
> And it Oops when used with a switch.

Hmm, now that I have net-next updated, I think the original commit is
wrong but not as I thought.

The way this has been added, it means that if we have a PHY on a SFP,
we can end up changing the settings on the SFP PHY if there is one
present.  Do we want to support WoL on SFPs?

David, can you revert 5e3768a436bb70c9c3e27aaba6b73f8ef8f5dcf3 please?
It's a layering violation, and as Andrew has found, it causes kernel
oopses.

What we need instead is support in phylink for doing this, which isn't
going to be a couple of lines change to what was added to mvneta in
the referenced commit.

Thanks.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTC for 0.8m (est. 1762m) line in suburbia: sync at 13.1Mbps down 424kbps up