From patchwork Tue Apr 26 05:09:55 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vivek Natarajan X-Patchwork-Id: 732222 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p3QAeJE4014549 for ; Tue, 26 Apr 2011 10:40:20 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754096Ab1DZKkS (ORCPT ); Tue, 26 Apr 2011 06:40:18 -0400 Received: from mail.atheros.com ([12.19.149.2]:40725 "EHLO mail.atheros.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753850Ab1DZKkR (ORCPT ); Tue, 26 Apr 2011 06:40:17 -0400 Received: from mail.atheros.com ([10.10.20.108]) by sidewinder.atheros.com for ; Tue, 26 Apr 2011 03:39:50 -0700 Received: from smtp.atheros.com (10.12.4.8) by SC1EXHC-02.global.atheros.com (10.10.20.106) with Microsoft SMTP Server (TLS) id 8.2.213.0; Tue, 26 Apr 2011 03:40:14 -0700 Received: by smtp.atheros.com (sSMTP sendmail emulation); Tue, 26 Apr 2011 10:40:11 +0530 From: Vivek Natarajan To: CC: Subject: [PATCH 4/4] ath9k: Use ps wrappers for btcoex logic. Date: Tue, 26 Apr 2011 10:39:55 +0530 Message-ID: <1303794595-4031-4-git-send-email-vnatarajan@atheros.com> X-Mailer: git-send-email 1.6.3.3 In-Reply-To: <1303794595-4031-3-git-send-email-vnatarajan@atheros.com> References: <1303794595-4031-1-git-send-email-vnatarajan@atheros.com> <1303794595-4031-2-git-send-email-vnatarajan@atheros.com> <1303794595-4031-3-git-send-email-vnatarajan@atheros.com> MIME-Version: 1.0 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 26 Apr 2011 10:40:20 +0000 (UTC) Use ps wrappers before accessing hw registers in btcoex. Signed-off-by: Vivek Natarajan --- drivers/net/wireless/ath/ath9k/gpio.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/drivers/net/wireless/ath/ath9k/gpio.c b/drivers/net/wireless/ath/ath9k/gpio.c index 3a4ddd1..0349b3a 100644 --- a/drivers/net/wireless/ath/ath9k/gpio.c +++ b/drivers/net/wireless/ath/ath9k/gpio.c @@ -179,6 +179,7 @@ static void ath_btcoex_period_timer(unsigned long data) u32 timer_period; bool is_btscan; + ath9k_ps_wakeup(sc); ath_detect_bt_priority(sc); is_btscan = sc->sc_flags & SC_OP_BT_SCAN; @@ -201,6 +202,7 @@ static void ath_btcoex_period_timer(unsigned long data) btcoex->hw_timer_enabled = true; } + ath9k_ps_restore(sc); mod_timer(&btcoex->period_timer, jiffies + msecs_to_jiffies(ATH_BTCOEX_DEF_BT_PERIOD)); } @@ -220,6 +222,7 @@ static void ath_btcoex_no_stomp_timer(void *arg) ath_dbg(common, ATH_DBG_BTCOEX, "no stomp timer running\n"); + ath9k_ps_wakeup(sc); spin_lock_bh(&btcoex->btcoex_lock); if (btcoex->bt_stomp_type == ATH_BTCOEX_STOMP_LOW || is_btscan) @@ -228,6 +231,7 @@ static void ath_btcoex_no_stomp_timer(void *arg) ath9k_hw_btcoex_bt_stomp(ah, ATH_BTCOEX_STOMP_LOW); spin_unlock_bh(&btcoex->btcoex_lock); + ath9k_ps_restore(sc); } int ath_init_btcoex_timer(struct ath_softc *sc)