From: Vasanthakumar Thiagarajan <vasanth@atheros.com>
Date: Thu, 24 Jun 2010 11:09:27 +0000 (-0700)
Subject: ath9k: Wakeup the chip in an appropriate place in ath_paprd_calibrate()
X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=47399f1a7d2059c89df7a1116024d0cd9bc240fa;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git

ath9k: Wakeup the chip in an appropriate place in ath_paprd_calibrate()

Move ath9k_ps_wakeup() down just before accessing hw registers.

Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
---

diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c
index c070e01c8de..87356fc6f4c 100644
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
@@ -268,7 +268,6 @@ void ath_paprd_calibrate(struct work_struct *work)
 	int time_left;
 	int i;
 
-	ath9k_ps_wakeup(sc);
 	skb = alloc_skb(len, GFP_KERNEL);
 	if (!skb)
 		return;
@@ -289,6 +288,7 @@ void ath_paprd_calibrate(struct work_struct *work)
 	qnum = sc->tx.hwq_map[WME_AC_BE];
 	txctl.txq = &sc->tx.txq[qnum];
 
+	ath9k_ps_wakeup(sc);
 	ar9003_paprd_init_table(ah);
 	for (chain = 0; chain < AR9300_MAX_CHAINS; chain++) {
 		if (!(ah->caps.tx_chainmask & BIT(chain)))