projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9011cd2
)
iwlwifi: missing unlock on error path
author
Dan Carpenter
<error27@gmail.com>
Tue, 15 Mar 2011 07:01:58 +0000
(10:01 +0300)
committer
John W. Linville
<linville@tuxdriver.com>
Mon, 21 Mar 2011 19:17:14 +0000
(15:17 -0400)
We should unlock here instead of returning -EINVAL directly.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/iwlwifi/iwl-agn.c
patch
|
blob
|
history
diff --git
a/drivers/net/wireless/iwlwifi/iwl-agn.c
b/drivers/net/wireless/iwlwifi/iwl-agn.c
index 581dc9f102738a3433da6f56438ea242484eaf6c..321b18b591356b36899fef26e267c6ce25400d39 100644
(file)
--- a/
drivers/net/wireless/iwlwifi/iwl-agn.c
+++ b/
drivers/net/wireless/iwlwifi/iwl-agn.c
@@
-3009,14
+3009,17
@@
static int iwl_mac_offchannel_tx_cancel_wait(struct ieee80211_hw *hw)
mutex_lock(&priv->mutex);
- if (!priv->_agn.offchan_tx_skb)
- return -EINVAL;
+ if (!priv->_agn.offchan_tx_skb) {
+ ret = -EINVAL;
+ goto unlock;
+ }
priv->_agn.offchan_tx_skb = NULL;
ret = iwl_scan_cancel_timeout(priv, 200);
if (ret)
ret = -EIO;
+unlock:
mutex_unlock(&priv->mutex);
return ret;