[PATCH net v3 2/3] net: stmmac: check if MAC needs to attach to a PHY

Russell King (Oracle) linux at armlinux.org.uk
Wed Apr 5 10:08:30 PDT 2023


On Wed, Apr 05, 2023 at 10:02:16AM -0700, Guenter Roeck wrote:
> Hi,
> 
> On Fri, Mar 24, 2023 at 04:16:55PM +0800, Michael Sit Wei Hong wrote:
> > After the introduction of the fixed-link support, the MAC driver
> > no longer attempt to scan for a PHY to attach to. This causes the
> > non fixed-link setups to stop working.
> > 
> > Using the phylink_expects_phy() to check and determine if the MAC
> > should expect and attach a PHY.
> > 
> > Fixes: ab21cf920928 ("net: stmmac: make mdio register skips PHY scanning for fixed-link")
> > Signed-off-by: Michael Sit Wei Hong <michael.wei.hong.sit at intel.com>
> > Signed-off-by: Lai Peter Jun Ann <peter.jun.ann.lai at intel.com>
> 
> With this patch in linux-next, the orangepi-pc qemu emulation fails to
> bring up the Ethernet interface. The following error is seen.
> 
> [   12.482401] dwmac-sun8i 1c30000.ethernet eth0: Register MEM_TYPE_PAGE_POOL RxQ-0
> [   12.487789] dwmac-sun8i 1c30000.ethernet eth0: PHY [mdio_mux-0.1:01] driver [Generic PHY] (irq=POLL)
> [   12.488177] dwmac-sun8i 1c30000.ethernet eth0: no phy found
> [   12.488295] dwmac-sun8i 1c30000.ethernet eth0: __stmmac_open: Cannot attach to PHY (error: -19)
> 
> Reverting this patch fixes the problem.

Please see 20230405093945.3549491-1-michael.wei.hong.sit at intel.com
for the fix.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!



More information about the linux-arm-kernel mailing list