[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aa2e700d-83f9-1105-ca3a-a060c5da734a@microchip.com>
Date: Fri, 12 Feb 2021 11:43:20 +0000
From: <Claudiu.Beznea@...rochip.com>
To: <hkallweit1@...il.com>, <andrew@...n.ch>, <linux@...linux.org.uk>,
<kuba@...nel.org>, <davem@...emloft.net>
CC: <netdev@...r.kernel.org>
Subject: Re: [PATCH net] net: phy: consider that suspend2ram may cut off PHY
power
On 11.02.2021 23:32, Heiner Kallweit wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
>
> Claudiu reported that on his system S2R cuts off power to the PHY and
> after resuming certain PHY settings are lost. The PM folks confirmed
> that cutting off power to selected components in S2R is a valid case.
> Therefore resuming from S2R, same as from hibernation, has to assume
> that the PHY has power-on defaults. As a consequence use the restore
> callback also as resume callback.
> In addition make sure that the interrupt configuration is restored.
> Let's do this in phy_init_hw() and ensure that after this call
> actual interrupt configuration is in sync with phydev->interrupts.
> Currently, if interrupt was enabled before hibernation, we would
> resume with interrupt disabled because that's the power-on default.
>
> This fix applies cleanly only after the commit marked as fixed.
>
> I don't have an affected system, therefore change is compile-tested
> only.
>
> [0] https://lore.kernel.org/netdev/1610120754-14331-1-git-send-email-claudiu.beznea@microchip.com/
>
> Fixes: 611d779af7ca ("net: phy: fix MDIO bus PM PHY resuming")
> Reported-by: Claudiu Beznea <claudiu.beznea@...rochip.com>
> Signed-off-by: Heiner Kallweit <hkallweit1@...il.com>
Hi Heiner,
I tested it on a system w/ SAMA7G5 and KSZ9131 PHY, with a S2R mode that
cuts the PHY's power and connectivity was good after resume. Thank you for
your patch!
Tested-by: Claudiu Beznea <claudiu.beznea@...rochip.com>
Powered by blists - more mailing lists