From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: yicongsrfy@163.com
Cc: andrew@lunn.ch, davem@davemloft.net, edumazet@google.com,
hkallweit1@gmail.com, kuba@kernel.org,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
pabeni@redhat.com, yicong@kylinos.cn
Subject: Re: [PATCH] net: phy: avoid config_init failure on unattached PHY during resume
Date: Wed, 10 Sep 2025 10:57:32 +0100 [thread overview]
Message-ID: <aMFLjHDH71fTwLwj@shell.armlinux.org.uk> (raw)
In-Reply-To: <20250910093100.3578130-1-yicongsrfy@163.com>
On Wed, Sep 10, 2025 at 05:31:00PM +0800, yicongsrfy@163.com wrote:
> One more point: in the suspend flow as shown below:
> `mdio_bus_phy_suspend`
> => `mdio_bus_phy_may_suspend`
> there is also a check whether `phydev->attached_dev` is NULL.
Yes, it checks, but only to bypass checking for things that are
dependent on whether a netdev exists. It doesn't _stop_ a netdev-less
PHY being suspended. What you're proposing _stops_ a netdev-less PHY
being resumed. You are proposing to break stuff.
> Therefore, my idea is to make this modification to maintain consistency in the logic.
No, it's making inconsistency. mdio_bus_phy_resume() will only resume a
PHY that has previously been suspended by mdio_bus_phy_suspend(). See
the phydev->suspended_by_mdio_bus flag.
Fix the motorcomm driver.
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
next prev parent reply other threads:[~2025-09-10 9:57 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-10 2:58 [PATCH] net: phy: avoid config_init failure on unattached PHY during resume yicongsrfy
2025-09-10 8:15 ` Russell King (Oracle)
2025-09-10 9:17 ` yicongsrfy
2025-09-10 9:31 ` yicongsrfy
2025-09-10 9:57 ` Russell King (Oracle) [this message]
2025-09-10 9:54 ` Russell King (Oracle)
2025-09-11 11:25 ` yicongsrfy
2025-09-11 12:58 ` Andrew Lunn
2025-09-17 8:24 ` yicongsrfy
2025-09-17 10:06 ` Russell King (Oracle)
2025-09-19 7:38 ` yicongsrfy
2025-09-19 12:45 ` Andrew Lunn
2025-09-22 1:56 ` yicongsrfy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aMFLjHDH71fTwLwj@shell.armlinux.org.uk \
--to=linux@armlinux.org.uk \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=yicong@kylinos.cn \
--cc=yicongsrfy@163.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).