From patchwork Tue Dec 7 02:48:52 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luis Rodriguez X-Patchwork-Id: 381522 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 oB72n95u013921 for ; Tue, 7 Dec 2010 02:49:09 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754144Ab0LGCtH (ORCPT ); Mon, 6 Dec 2010 21:49:07 -0500 Received: from mail.atheros.com ([12.19.149.2]:17662 "EHLO mail.atheros.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752192Ab0LGCtF (ORCPT ); Mon, 6 Dec 2010 21:49:05 -0500 Received: from mail.atheros.com ([10.10.20.108]) by sidewinder.atheros.com for ; Mon, 06 Dec 2010 18:48:51 -0800 Received: from tux (10.10.11.96) by SC1EXHC-02.global.atheros.com (10.10.20.111) with Microsoft SMTP Server (TLS) id 8.2.213.0; Mon, 6 Dec 2010 18:49:03 -0800 Received: by tux (sSMTP sendmail emulation); Mon, 06 Dec 2010 18:49:03 -0800 From: "Luis R. Rodriguez" To: CC: , , , , "Luis R. Rodriguez" , Subject: [PATCH 2/5] ath9k: Fix power save count imbalance on ath_radio_enable() Date: Mon, 6 Dec 2010 18:48:52 -0800 Message-ID: <1291690135-4535-3-git-send-email-lrodriguez@atheros.com> X-Mailer: git-send-email 1.7.3.2.90.gd4c43 In-Reply-To: <1291690135-4535-1-git-send-email-lrodriguez@atheros.com> References: <1291690135-4535-1-git-send-email-lrodriguez@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.3 (demeter1.kernel.org [140.211.167.41]); Tue, 07 Dec 2010 02:49:09 +0000 (UTC) diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index fd27ec9..97ddb32 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c @@ -903,8 +903,7 @@ void ath_radio_enable(struct ath_softc *sc, struct ieee80211_hw *hw) if (ath_startrecv(sc) != 0) { ath_print(common, ATH_DBG_FATAL, "Unable to restart recv logic\n"); - spin_unlock_bh(&sc->sc_pcu_lock); - return; + goto out; } if (sc->sc_flags & SC_OP_BEACONS) ath_beacon_config(sc, NULL); /* restart beacons */ @@ -918,6 +917,7 @@ void ath_radio_enable(struct ath_softc *sc, struct ieee80211_hw *hw) ath9k_hw_set_gpio(ah, ah->led_pin, 0); ieee80211_wake_queues(hw); +out: spin_unlock_bh(&sc->sc_pcu_lock); ath9k_ps_restore(sc);