NET: phy_device, fix lock imbalance
Don't forget to unlock a mutex in phy_scan_fixups on a fail path. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
ee686ca919
commit
bc23283c7b
@ -134,10 +134,12 @@ int phy_scan_fixups(struct phy_device *phydev)
|
|||||||
|
|
||||||
err = fixup->run(phydev);
|
err = fixup->run(phydev);
|
||||||
|
|
||||||
if (err < 0)
|
if (err < 0) {
|
||||||
|
mutex_unlock(&phy_fixup_lock);
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
mutex_unlock(&phy_fixup_lock);
|
mutex_unlock(&phy_fixup_lock);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user