From patchwork Thu Apr 21 20:30:40 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luis Rodriguez X-Patchwork-Id: 725611 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 p3LKUv18015803 for ; Thu, 21 Apr 2011 20:30:57 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754070Ab1DUUay (ORCPT ); Thu, 21 Apr 2011 16:30:54 -0400 Received: from mail.atheros.com ([12.19.149.2]:43161 "EHLO mail.atheros.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754021Ab1DUUax (ORCPT ); Thu, 21 Apr 2011 16:30:53 -0400 Received: from mail.atheros.com ([10.234.20.104]) by sidewinder.atheros.com for ; Thu, 21 Apr 2011 13:30:26 -0700 Received: from tux (10.10.11.42) by SC1EXHC-01.global.atheros.com (10.234.20.111) with Microsoft SMTP Server (TLS) id 8.2.213.0; Thu, 21 Apr 2011 13:30:51 -0700 Received: by tux (sSMTP sendmail emulation); Thu, 21 Apr 2011 13:30:51 -0700 From: "Luis R. Rodriguez" To: CC: , , , , , "Luis R. Rodriguez" Subject: [PATCH v2 5/5] ath6kl: fix operations for power management Date: Thu, 21 Apr 2011 13:30:40 -0700 Message-ID: <1303417840-19605-6-git-send-email-lrodriguez@atheros.com> X-Mailer: git-send-email 1.7.4.15.g7811d In-Reply-To: <1303417840-19605-1-git-send-email-lrodriguez@atheros.com> References: <1303417840-19605-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.6 (demeter1.kernel.org [140.211.167.41]); Thu, 21 Apr 2011 20:30:57 +0000 (UTC) From: Naveen Singh The cfg80211 ops for power management were completely broken. If we were asked for to go into power save it was putting device in awake, and when we were asked to become awake we were putting the device into power save... This fixes the powersave operations to do the right thing. Signed-off-by: Naveen Singh Signed-off-by: Luis R. Rodriguez --- drivers/staging/ath6kl/os/linux/cfg80211.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/ath6kl/os/linux/cfg80211.c b/drivers/staging/ath6kl/os/linux/cfg80211.c index d5e554e..e87d3aa 100644 --- a/drivers/staging/ath6kl/os/linux/cfg80211.c +++ b/drivers/staging/ath6kl/os/linux/cfg80211.c @@ -1209,10 +1209,10 @@ ar6k_cfg80211_set_power_mgmt(struct wiphy *wiphy, if(pmgmt) { AR_DEBUG_PRINTF(ATH_DEBUG_INFO, ("%s: Max Perf\n", __func__)); - pwrMode.powerMode = MAX_PERF_POWER; + pwrMode.powerMode = REC_POWER; } else { AR_DEBUG_PRINTF(ATH_DEBUG_INFO, ("%s: Rec Power\n", __func__)); - pwrMode.powerMode = REC_POWER; + pwrMode.powerMode = MAX_PERF_POWER; } if(wmi_powermode_cmd(ar->arWmi, pwrMode.powerMode) != 0) {