* [PATCH net-next v2] net: phy: micrel: Add ksz9131_resume()
@ 2025-07-11 5:40 Biju Das
2025-07-11 12:56 ` Andrew Lunn
2025-07-15 0:30 ` patchwork-bot+netdevbpf
0 siblings, 2 replies; 3+ messages in thread
From: Biju Das @ 2025-07-11 5:40 UTC (permalink / raw)
To: Andrew Lunn, Heiner Kallweit, David S. Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni
Cc: Biju Das, Russell King, netdev, linux-kernel, Geert Uytterhoeven,
Prabhakar Mahadev Lad, Biju Das, linux-renesas-soc
The Renesas RZ/G3E SMARC EVK uses KSZ9131RNXC phy. On deep power state,
PHY loses the power and on wakeup the rgmii delays are not reconfigured
causing it to fail.
Replace the callback kszphy_resume()->ksz9131_resume() for reconfiguring
the rgmii_delay when it exits from PM suspend state.
Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
---
v1->v2:
* Added ksz9131-specific phy_driver->resume to reconfigure the rgmii
delays on exit from PM suspend state.
* Replaced 'priv->is_suspended'->'phydev->suspended' for checking
exit from PM state.
* Updated commit description.
Ref:
https://patchwork.kernel.org/project/linux-renesas-soc/patch/20250705170326.106073-1-biju.das.jz@bp.renesas.com/#26459627
---
drivers/net/phy/micrel.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/net/phy/micrel.c b/drivers/net/phy/micrel.c
index 74fd6ff32c6c..f678c1bdacdf 100644
--- a/drivers/net/phy/micrel.c
+++ b/drivers/net/phy/micrel.c
@@ -5633,6 +5633,14 @@ static int lan8841_suspend(struct phy_device *phydev)
return kszphy_generic_suspend(phydev);
}
+static int ksz9131_resume(struct phy_device *phydev)
+{
+ if (phydev->suspended && phy_interface_is_rgmii(phydev))
+ ksz9131_config_rgmii_delay(phydev);
+
+ return kszphy_resume(phydev);
+}
+
static struct phy_driver ksphy_driver[] = {
{
.phy_id = PHY_ID_KS8737,
@@ -5879,7 +5887,7 @@ static struct phy_driver ksphy_driver[] = {
.get_strings = kszphy_get_strings,
.get_stats = kszphy_get_stats,
.suspend = kszphy_suspend,
- .resume = kszphy_resume,
+ .resume = ksz9131_resume,
.cable_test_start = ksz9x31_cable_test_start,
.cable_test_get_status = ksz9x31_cable_test_get_status,
.get_features = ksz9477_get_features,
--
2.43.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH net-next v2] net: phy: micrel: Add ksz9131_resume()
2025-07-11 5:40 [PATCH net-next v2] net: phy: micrel: Add ksz9131_resume() Biju Das
@ 2025-07-11 12:56 ` Andrew Lunn
2025-07-15 0:30 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 3+ messages in thread
From: Andrew Lunn @ 2025-07-11 12:56 UTC (permalink / raw)
To: Biju Das
Cc: Heiner Kallweit, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Russell King, netdev, linux-kernel,
Geert Uytterhoeven, Prabhakar Mahadev Lad, Biju Das,
linux-renesas-soc
On Fri, Jul 11, 2025 at 06:40:21AM +0100, Biju Das wrote:
> The Renesas RZ/G3E SMARC EVK uses KSZ9131RNXC phy. On deep power state,
> PHY loses the power and on wakeup the rgmii delays are not reconfigured
> causing it to fail.
>
> Replace the callback kszphy_resume()->ksz9131_resume() for reconfiguring
> the rgmii_delay when it exits from PM suspend state.
>
> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Andrew
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH net-next v2] net: phy: micrel: Add ksz9131_resume()
2025-07-11 5:40 [PATCH net-next v2] net: phy: micrel: Add ksz9131_resume() Biju Das
2025-07-11 12:56 ` Andrew Lunn
@ 2025-07-15 0:30 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2025-07-15 0:30 UTC (permalink / raw)
To: Biju Das
Cc: andrew, hkallweit1, davem, edumazet, kuba, pabeni, linux, netdev,
linux-kernel, geert+renesas, prabhakar.mahadev-lad.rj,
biju.das.au, linux-renesas-soc
Hello:
This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Fri, 11 Jul 2025 06:40:21 +0100 you wrote:
> The Renesas RZ/G3E SMARC EVK uses KSZ9131RNXC phy. On deep power state,
> PHY loses the power and on wakeup the rgmii delays are not reconfigured
> causing it to fail.
>
> Replace the callback kszphy_resume()->ksz9131_resume() for reconfiguring
> the rgmii_delay when it exits from PM suspend state.
>
> [...]
Here is the summary with links:
- [net-next,v2] net: phy: micrel: Add ksz9131_resume()
https://git.kernel.org/netdev/net-next/c/f25a7eaa897f
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-07-15 0:30 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-11 5:40 [PATCH net-next v2] net: phy: micrel: Add ksz9131_resume() Biju Das
2025-07-11 12:56 ` Andrew Lunn
2025-07-15 0:30 ` patchwork-bot+netdevbpf
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).