From: Larry Finger <Larry.Finger@lwfinger.net>
To: linville@tuxdriver.com
Cc: linux-wireless@vger.kernel.org,
Larry Finger <Larry.Finger@lwfinger.net>,
netdev@vger.kernel.org, Stable <stable@vger.kernel.org>
Subject: [PATCH 09/12 NEXT] rtlwifi: rtl8192cu: Update the power index registers
Date: Mon, 18 Nov 2013 11:11:33 -0600 [thread overview]
Message-ID: <1384794696-20314-10-git-send-email-Larry.Finger@lwfinger.net> (raw)
In-Reply-To: <1384794696-20314-1-git-send-email-Larry.Finger@lwfinger.net>
This patch uses the newly introduced power index register routines.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
---
drivers/net/wireless/rtlwifi/rtl8192cu/dm.c | 6 ++++++
drivers/net/wireless/rtlwifi/rtl8192cu/dm.h | 3 +++
2 files changed, 9 insertions(+)
Index: wireless-testing/drivers/net/wireless/rtlwifi/rtl8192cu/dm.c
===================================================================
--- wireless-testing.orig/drivers/net/wireless/rtlwifi/rtl8192cu/dm.c
+++ wireless-testing/drivers/net/wireless/rtlwifi/rtl8192cu/dm.c
@@ -101,6 +101,15 @@ void rtl92cu_dm_dynamic_txpower(struct i
"PHY_SetTxPowerLevel8192S() Channel = %d\n",
rtlphy->current_channel);
rtl92c_phy_set_txpower_level(hw, rtlphy->current_channel);
+ if (rtlpriv->dm.dynamic_txhighpower_lvl ==
+ TXHIGHPWRLEVEL_NORMAL)
+ dm_restorepowerindex(hw);
+ else if (rtlpriv->dm.dynamic_txhighpower_lvl ==
+ TXHIGHPWRLEVEL_LEVEL1)
+ dm_writepowerindex(hw, 0x14);
+ else if (rtlpriv->dm.dynamic_txhighpower_lvl ==
+ TXHIGHPWRLEVEL_LEVEL2)
+ dm_writepowerindex(hw, 0x10);
}
rtlpriv->dm.last_dtp_lvl = rtlpriv->dm.dynamic_txhighpower_lvl;
Index: wireless-testing/drivers/net/wireless/rtlwifi/rtl8192cu/dm.h
===================================================================
--- wireless-testing.orig/drivers/net/wireless/rtlwifi/rtl8192cu/dm.h
+++ wireless-testing/drivers/net/wireless/rtlwifi/rtl8192cu/dm.h
@@ -30,3 +30,6 @@
#include "../rtl8192ce/dm.h"
void rtl92cu_dm_dynamic_txpower(struct ieee80211_hw *hw);
+void dm_savepowerindex(struct ieee80211_hw *hw);
+void dm_writepowerindex(struct ieee80211_hw *hw, u8 value);
+void dm_restorepowerindex(struct ieee80211_hw *hw);
next prev parent reply other threads:[~2013-11-18 17:11 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-18 17:11 [PATCH 00/12] Fix various problems with the rtl8192cu driver Larry Finger
2013-11-18 17:11 ` [PATCH 01/12 NEXT] rtlwifi: rtl8192c: Prevent reconnect attempts if not connected Larry Finger
2013-11-18 17:11 ` [PATCH 02/12 NEXT] rtlwifi: rtl8192cu: Add new firmware Larry Finger
[not found] ` <1384794696-20314-1-git-send-email-Larry.Finger-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
2013-11-18 17:11 ` [PATCH 03/12 NEXT] rtlwifi: Redo register save locations Larry Finger
2013-11-18 17:11 ` [PATCH 10/12 NEXT] rtlwifi: rtl8192cu: Fix some code in RF handling Larry Finger
2013-11-18 17:11 ` [PATCH 11/12 NEXT] rtlwifi: Add missing code to PWDB statics routine Larry Finger
2013-11-18 17:11 ` [PATCH 04/12 NEXT] rtlwifi: Set the link state Larry Finger
2013-11-18 17:11 ` [PATCH 05/12 NEXT] rtlwifi: rtl8192c: Add new definitions in the dm_common header Larry Finger
2013-11-18 17:11 ` [PATCH 06/12 NEXT] rtlwifi: Increase the RX queue length for USB drivers Larry Finger
2013-11-18 17:11 ` [PATCH 07/12 NEXT] rtlwifi: Update beacon statistics for USB driver Larry Finger
2013-11-18 17:11 ` [PATCH 08/12 NEXT] rtlwifi: rtl8192c: Add routines to save/restore power index registers Larry Finger
2013-11-18 17:11 ` Larry Finger [this message]
2013-11-18 17:11 ` [PATCH 12/12 NEXT] rtlwifi: rtl8192c: Update dynamic gain calculations Larry Finger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1384794696-20314-10-git-send-email-Larry.Finger@lwfinger.net \
--to=larry.finger@lwfinger.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=netdev@vger.kernel.org \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox