From: <Claudiu.Beznea@microchip.com>
To: <Sergiu.Moga@microchip.com>, <Nicolas.Ferre@microchip.com>,
<davem@davemloft.net>, <edumazet@google.com>, <kuba@kernel.org>,
<pabeni@redhat.com>, <linux@armlinux.org.uk>,
<f.fainelli@gmail.com>, <Tudor.Ambarus@microchip.com>
Cc: <netdev@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2] net: macb: Specify PHY PM management done by MAC
Date: Thu, 20 Oct 2022 08:14:29 +0000 [thread overview]
Message-ID: <3078193e-2df2-bfcf-f1e9-302ec7841eb7@microchip.com> (raw)
In-Reply-To: <20221019120929.63098-1-sergiu.moga@microchip.com>
On 19.10.2022 15:09, Sergiu Moga wrote:
> The `macb_resume`/`macb_suspend` methods already call the
> `phylink_start`/`phylink_stop` methods during their execution so
> explicitly say that the PM of the PHY is done by MAC by using the
> `mac_managed_pm` flag of the `struct phylink_config`.
>
> This also fixes the warning message issued during resume:
> WARNING: CPU: 0 PID: 237 at drivers/net/phy/phy_device.c:323 mdio_bus_phy_resume+0x144/0x148
>
> Depends-on: 96de900ae78e ("net: phylink: add mac_managed_pm in phylink_config structure")
> Fixes: 744d23c71af3 ("net: phy: Warn about incorrect mdio_bus_phy_resume() state")
> Signed-off-by: Sergiu Moga <sergiu.moga@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
> ---
>
>
> v1 -> v2:
> - Add Depends-on: tag
>
>
> drivers/net/ethernet/cadence/macb_main.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/net/ethernet/cadence/macb_main.c b/drivers/net/ethernet/cadence/macb_main.c
> index 51c9fd6f68a4..4f63f1ba3161 100644
> --- a/drivers/net/ethernet/cadence/macb_main.c
> +++ b/drivers/net/ethernet/cadence/macb_main.c
> @@ -806,6 +806,7 @@ static int macb_mii_probe(struct net_device *dev)
>
> bp->phylink_config.dev = &dev->dev;
> bp->phylink_config.type = PHYLINK_NETDEV;
> + bp->phylink_config.mac_managed_pm = true;
>
> if (bp->phy_interface == PHY_INTERFACE_MODE_SGMII) {
> bp->phylink_config.poll_fixed_state = true;
next prev parent reply other threads:[~2022-10-20 8:14 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-19 12:09 [PATCH v2] net: macb: Specify PHY PM management done by MAC Sergiu Moga
2022-10-19 23:37 ` Florian Fainelli
2022-10-20 8:14 ` Claudiu.Beznea [this message]
2022-10-21 5:10 ` patchwork-bot+netdevbpf
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=3078193e-2df2-bfcf-f1e9-302ec7841eb7@microchip.com \
--to=claudiu.beznea@microchip.com \
--cc=Nicolas.Ferre@microchip.com \
--cc=Sergiu.Moga@microchip.com \
--cc=Tudor.Ambarus@microchip.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=f.fainelli@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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