From: Florian Fainelli Date: Wed, 25 Jan 2017 17:10:41 +0000 (-0800) Subject: net: dsa: Bring back device detaching in dsa_slave_suspend() X-Git-Tag: v4.9.8~20 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9f42bc4f9c1c968ce7f87b451544a119600e3666;p=platform%2Fkernel%2Flinux-amlogic.git net: dsa: Bring back device detaching in dsa_slave_suspend() [ Upstream commit f154be241d22298d2b63c9b613f619fa1086ea75 ] Commit 448b4482c671 ("net: dsa: Add lockdep class to tx queues to avoid lockdep splat") removed the netif_device_detach() call done in dsa_slave_suspend() which is necessary, and paired with a corresponding netif_device_attach(), bring it back. Fixes: 448b4482c671 ("net: dsa: Add lockdep class to tx queues to avoid lockdep splat") Signed-off-by: Florian Fainelli Reviewed-by: Andrew Lunn Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- diff --git a/net/dsa/slave.c b/net/dsa/slave.c index 30e2e21..3ff9d97 100644 --- a/net/dsa/slave.c +++ b/net/dsa/slave.c @@ -1201,6 +1201,8 @@ int dsa_slave_suspend(struct net_device *slave_dev) { struct dsa_slave_priv *p = netdev_priv(slave_dev); + netif_device_detach(slave_dev); + if (p->phy) { phy_stop(p->phy); p->old_pause = -1;