forked from luck/tmp_suning_uos_patched
[WATCHDOG] w83697ug, fix lock imbalance
Don't forget to unlock io_lock when w83697ug_select_wd_register fails in wdt_ctrl. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
This commit is contained in:
parent
b86a6c6c7b
commit
db5d2d8a5d
|
@ -149,8 +149,10 @@ static void wdt_ctrl(int timeout)
|
|||
{
|
||||
spin_lock(&io_lock);
|
||||
|
||||
if (w83697ug_select_wd_register() < 0)
|
||||
if (w83697ug_select_wd_register() < 0) {
|
||||
spin_unlock(&io_lock);
|
||||
return;
|
||||
}
|
||||
|
||||
outb_p(0xF4, WDT_EFER); /* Select CRF4 */
|
||||
outb_p(timeout, WDT_EFDR); /* Write Timeout counter to CRF4 */
|
||||
|
|
Loading…
Reference in New Issue
Block a user