summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorRajkumar Manoharan <rmanohar@qca.qualcomm.com>2012-06-11 12:19:30 +0530
committerJohn W. Linville <linville@tuxdriver.com>2012-06-13 14:35:51 -0400
commit8389fb3fd7c0bbe3289578f698917f594e0b6fc9 (patch)
tree122a849c495d8401a2206521aac63fc10b7e3f84 /drivers
parentcec429dd65ef1ccc693e5fa1468b0a12982b4283 (diff)
downloadlinux-3.10-8389fb3fd7c0bbe3289578f698917f594e0b6fc9.tar.gz
linux-3.10-8389fb3fd7c0bbe3289578f698917f594e0b6fc9.tar.bz2
linux-3.10-8389fb3fd7c0bbe3289578f698917f594e0b6fc9.zip
ath9k: restore power state on set channel failure
Not doing so, could cause imbalance in powersave count. Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/ath/ath9k/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c
index c0f478b0a9a..e655f2a907b 100644
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
@@ -1258,6 +1258,7 @@ static int ath9k_config(struct ieee80211_hw *hw, u32 changed)
if (ath_set_channel(sc, hw, &sc->sc_ah->channels[pos]) < 0) {
ath_err(common, "Unable to set channel\n");
mutex_unlock(&sc->mutex);
+ ath9k_ps_restore(sc);
return -EINVAL;
}