提交 bc23283c 编写于 作者: J Jiri Slaby 提交者: David S. Miller

NET: phy_device, fix lock imbalance

Don't forget to unlock a mutex in phy_scan_fixups on a fail path.
Signed-off-by: NJiri Slaby <jirislaby@gmail.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 ee686ca9
......@@ -134,10 +134,12 @@ 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);
return 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册