From 4db7c0bebdff87e1c81ed4fbafc65cddec109e3d Mon Sep 17 00:00:00 2001 From: Wei Yongjun Date: Thu, 15 Sep 2016 10:12:05 +0000 Subject: [PATCH] staging: rtl8712: fix double lock bug in SetPSModeWorkItemCallback() Fix a double lock bug in SetPSModeWorkItemCallback(). Fixes: 5c2ba8b85e35 ("rtl8712: pwrctrl_priv: Replace semaphore lock with mutex") Signed-off-by: Wei Yongjun Signed-off-by: Greg Kroah-Hartman --- drivers/staging/rtl8712/rtl871x_pwrctrl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8712/rtl871x_pwrctrl.c b/drivers/staging/rtl8712/rtl871x_pwrctrl.c index 8f82d85178ab..d464c136dd98 100644 --- a/drivers/staging/rtl8712/rtl871x_pwrctrl.c +++ b/drivers/staging/rtl8712/rtl871x_pwrctrl.c @@ -145,7 +145,7 @@ static void SetPSModeWorkItemCallback(struct work_struct *work) mutex_lock(&pwrpriv->mutex_lock); if (pwrpriv->pwr_mode == PS_MODE_ACTIVE) r8712_set_rpwm(padapter, PS_STATE_S4); - mutex_lock(&pwrpriv->mutex_lock); + mutex_unlock(&pwrpriv->mutex_lock); } } -- 2.30.2