From: Shenwei Wang Date: Sat, 3 Aug 2024 11:30:44 +0000 (+0800) Subject: net: stmmac: Enable mac_managed_pm phylink config X-Git-Tag: v5.15.165~16 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=67a03645dc1dc797caefdd862a4f10c8136986ca;p=thirdparty%2Fkernel%2Fstable.git net: stmmac: Enable mac_managed_pm phylink config commit f151c147b3afcf92dedff53f5f0e965414e4fd2c upstream Enable the mac_managed_pm configuration in the phylink_config structure to avoid the kernel warning during system resume. Fixes: 744d23c71af3 ("net: phy: Warn about incorrect mdio_bus_phy_resume() state") Signed-off-by: Shenwei Wang Acked-by: Florian Fainelli Signed-off-by: David S. Miller Signed-off-by: Jisheng Zhang Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c index a5cbb495b5581..cd92b8e03a9a1 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c @@ -1286,6 +1286,8 @@ static int stmmac_phy_setup(struct stmmac_priv *priv) if (!fwnode) fwnode = dev_fwnode(priv->device); + priv->phylink_config.mac_managed_pm = true; + phylink = phylink_create(&priv->phylink_config, fwnode, mode, &stmmac_phylink_mac_ops); if (IS_ERR(phylink))