public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] staging: rtl8712: fix double lock bug in SetPSModeWorkItemCallback()
@ 2016-09-15 10:12 Wei Yongjun
  2016-09-16  8:01 ` Greg KH
  0 siblings, 1 reply; 3+ messages in thread
From: Wei Yongjun @ 2016-09-15 10:12 UTC (permalink / raw)
  To: Larry.Finger, florian.c.schilhabel, gregkh, binoy.jayan, arnd,
	luisbg, raphael.beamonte
  Cc: Wei Yongjun, devel, linux-kernel

From: Wei Yongjun <weiyongjun1@huawei.com>

Fix a double lock bug in SetPSModeWorkItemCallback().

Fixes: 5c2ba8b85e35 ("rtl8712: pwrctrl_priv: Replace semaphore lock
with mutex")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 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 8f82d85..d464c13 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);
 	}
 }

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-09-16  8:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-15 10:12 [PATCH -next] staging: rtl8712: fix double lock bug in SetPSModeWorkItemCallback() Wei Yongjun
2016-09-16  8:01 ` Greg KH
2016-09-16  8:02   ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox