diff options
author | Florian Fainelli <florian.fainelli@broadcom.com> | 2024-02-15 10:27:31 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2024-02-18 11:32:10 +0000 |
commit | 5b76d928f8b779a1b19c5842e7cabee4cbb610c3 (patch) | |
tree | 434ad19762ee02698306efc8d27a2070d1482646 | |
parent | 398b7c3770c23de9a7d1a680960025fa8b014784 (diff) | |
download | linux-5b76d928f8b779a1b19c5842e7cabee4cbb610c3.tar.gz |
net: bcmasp: Indicate MAC is in charge of PHY PM
Avoid the PHY library call unnecessarily into the suspend/resume
functions by setting phydev->mac_managed_pm to true. The ASP driver
essentially does exactly what mdio_bus_phy_resume() does.
Fixes: 490cb412007d ("net: bcmasp: Add support for ASP2.0 Ethernet controller")
Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com>
Signed-off-by: Justin Chen <justin.chen@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Notes
Fixes: 490cb412007d ("net: bcmasp: Add support for ASP2.0 Ethernet controller") # v6.6-rc1
Stable: ae24a16a8343 # v6.6.19
Lore: https://lore.kernel.org/r/20240215182732.1536941-2-justin.chen@broadcom.com # lkml, netdev
Lore: https://lore.kernel.org/r/20240227131633.680254534@linuxfoundation.org # linux-patches, stable
Lore: https://lore.kernel.org/r/20240227131639.737999817@linuxfoundation.org # linux-patches, stable
-rw-r--r-- | drivers/net/ethernet/broadcom/asp2/bcmasp_intf.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/broadcom/asp2/bcmasp_intf.c b/drivers/net/ethernet/broadcom/asp2/bcmasp_intf.c index f59557b0cd5152..6ad1366270f79c 100644 --- a/drivers/net/ethernet/broadcom/asp2/bcmasp_intf.c +++ b/drivers/net/ethernet/broadcom/asp2/bcmasp_intf.c @@ -1050,6 +1050,9 @@ static int bcmasp_netif_init(struct net_device *dev, bool phy_connect) netdev_err(dev, "could not attach to PHY\n"); goto err_phy_disable; } + + /* Indicate that the MAC is responsible for PHY PM */ + phydev->mac_managed_pm = true; } else if (!intf->wolopts) { ret = phy_resume(dev->phydev); if (ret) |