smsc911x: avoid PHY being resumed when interface is not up
authorWolfram Sang <wsa+renesas@sang-engineering.com>
Mon, 27 Mar 2023 08:31:38 +0000 (10:31 +0200)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 28 Mar 2023 11:39:47 +0000 (13:39 +0200)
commitf22c993f31fa9615df46e49cd768b713d39a852f
tree37073d374c76e08c405740c7032d3796983d30ac
parentb4c66d755e6d5620920168c15eb75f53394a952c
smsc911x: avoid PHY being resumed when interface is not up

SMSC911x doesn't need mdiobus suspend/resume, that's why it sets
'mac_managed_pm'. However, setting it needs to be moved from init to
probe, so mdiobus PM functions will really never be called (e.g. when
the interface is not up yet during suspend/resume).

Fixes: 3ce9f2bef755 ("net: smsc911x: Stop and start PHY during suspend and resume")
Suggested-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Link: https://lore.kernel.org/r/20230327083138.6044-1-wsa+renesas@sang-engineering.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/ethernet/smsc/smsc911x.c