staging: mt7621-eth: Lock is never unlocked.
authorNeilBrown <neil@brown.name>
Fri, 4 May 2018 04:58:35 +0000 (14:58 +1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 7 May 2018 02:09:23 +0000 (19:09 -0700)
mtk_phy_link_adjust takes a spinlock and disables
interrupts, but never unlocks.
This can leave interrupts disabled on one CPU and
various things stop working.

Signed-off-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/mt7621-eth/mdio.c

index 9d71307..c6db11a 100644 (file)
@@ -57,6 +57,7 @@ static void mtk_phy_link_adjust(struct net_device *dev)
                        }
                }
        }
+       spin_unlock_irqrestore(&eth->phy->lock, flags);
 }
 
 int mtk_connect_phy_node(struct mtk_eth *eth, struct mtk_mac *mac,