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:
Родитель
ee686ca919
Коммит
bc23283c7b
|
@ -134,8 +134,10 @@ int phy_scan_fixups(struct phy_device *phydev)
|
|||
|
||||
err = fixup->run(phydev);
|
||||
|
||||
if (err < 0)
|
||||
if (err < 0) {
|
||||
mutex_unlock(&phy_fixup_lock);
|
||||
return err;
|
||||
}
|
||||
}
|
||||
}
|
||||
mutex_unlock(&phy_fixup_lock);
|
||||
|
|
Загрузка…
Ссылка в новой задаче