Commit 84b7901f authored by Atsushi Nemoto's avatar Atsushi Nemoto Committed by Jeff Garzik
Browse files

macb: Call phy_disconnect on removing



Call phy_disconnect() on remove routine.  Otherwise the phy timer
causes a kernel crash when unloading.

Signed-off-by: default avatarAtsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
parent 3d137fdd
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -1257,6 +1257,8 @@ static int __exit macb_remove(struct platform_device *pdev)

	if (dev) {
		bp = netdev_priv(dev);
		if (bp->phy_dev)
			phy_disconnect(bp->phy_dev);
		mdiobus_unregister(&bp->mii_bus);
		kfree(bp->mii_bus.irq);
		unregister_netdev(dev);