summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@armlinux.org.uk>2017-11-30 13:59:26 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-02-25 11:07:57 +0100
commit86659fbb32a5f6d4c97e6f9058bf3f65d7501049 (patch)
tree61c37813f2df047ba5399d9c30148b10b5df7f13
parent778e7124f71dc42e0863c21aefd99b7c2155a4b8 (diff)
phylink: ensure we take the link down when phylink_stop() is called
[ Upstream commit 2012b7d6b2868c532f22d9172c8b24611637eb48 ] Ensure that we tell the MAC to take the link down when phylink_stop() is called, and that this completes prior to phylink_stop() returns. Reported-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <alexander.levin@verizon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/net/phy/phylink.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/phy/phylink.c b/drivers/net/phy/phylink.c
index cb85307f125b..1b2fe74a44ea 100644
--- a/drivers/net/phy/phylink.c
+++ b/drivers/net/phy/phylink.c
@@ -772,6 +772,7 @@ void phylink_stop(struct phylink *pl)
sfp_upstream_stop(pl->sfp_bus);
set_bit(PHYLINK_DISABLE_STOPPED, &pl->phylink_disable_state);
+ queue_work(system_power_efficient_wq, &pl->resolve);
flush_work(&pl->resolve);
}
EXPORT_SYMBOL_GPL(phylink_stop);