mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Wei Yongjun <weiyj.lk@gmail.com>
To: Larry.Finger@lwfinger.net, florian.c.schilhabel@googlemail.com,
	gregkh@linuxfoundation.org, binoy.jayan@linaro.org,
	arnd@arndb.de, luisbg@osg.samsung.com,
	raphael.beamonte@gmail.com
Cc: Wei Yongjun <weiyongjun1@huawei.com>,
	devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: [PATCH -next] staging: rtl8712: fix double lock bug in SetPSModeWorkItemCallback()
Date: Thu, 15 Sep 2016 10:12:05 +0000	[thread overview]
Message-ID: <1473934325-7578-1-git-send-email-weiyj.lk@gmail.com> (raw)

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);
 	}
 }

             reply	other threads:[~2016-09-15 10:12 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-15 10:12 Wei Yongjun [this message]
2016-09-16  8:01 ` Greg KH
2016-09-16  8:02   ` Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1473934325-7578-1-git-send-email-weiyj.lk@gmail.com \
    --to=weiyj.lk@gmail.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=arnd@arndb.de \
    --cc=binoy.jayan@linaro.org \
    --cc=devel@driverdev.osuosl.org \
    --cc=florian.c.schilhabel@googlemail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luisbg@osg.samsung.com \
    --cc=raphael.beamonte@gmail.com \
    --cc=weiyongjun1@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®