aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rtlwifi
diff options
context:
space:
mode:
authorLarry Finger <Larry.Finger@lwfinger.net>2013-11-18 12:11:33 -0500
committerJohn W. Linville <linville@tuxdriver.com>2013-12-05 14:55:16 -0500
commit9806eacf5de27ab01d680c5d75c92a3a89734e4f (patch)
tree1a71ce3050c822d074fd38fc8f281ad962f64794 /drivers/net/wireless/rtlwifi
parent97204e93f01868eeba6ae5c4f3270f32905bb418 (diff)
rtlwifi: rtl8192cu: Update the power index registers
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> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rtlwifi')
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192cu/dm.c9
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192cu/dm.h3
2 files changed, 12 insertions, 0 deletions
diff --git a/drivers/net/wireless/rtlwifi/rtl8192cu/dm.c b/drivers/net/wireless/rtlwifi/rtl8192cu/dm.c
index 16a0b9e59acf..c16209a336ea 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192cu/dm.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192cu/dm.c
@@ -101,6 +101,15 @@ void rtl92cu_dm_dynamic_txpower(struct ieee80211_hw *hw)
101 "PHY_SetTxPowerLevel8192S() Channel = %d\n", 101 "PHY_SetTxPowerLevel8192S() Channel = %d\n",
102 rtlphy->current_channel); 102 rtlphy->current_channel);
103 rtl92c_phy_set_txpower_level(hw, rtlphy->current_channel); 103 rtl92c_phy_set_txpower_level(hw, rtlphy->current_channel);
104 if (rtlpriv->dm.dynamic_txhighpower_lvl ==
105 TXHIGHPWRLEVEL_NORMAL)
106 dm_restorepowerindex(hw);
107 else if (rtlpriv->dm.dynamic_txhighpower_lvl ==
108 TXHIGHPWRLEVEL_LEVEL1)
109 dm_writepowerindex(hw, 0x14);
110 else if (rtlpriv->dm.dynamic_txhighpower_lvl ==
111 TXHIGHPWRLEVEL_LEVEL2)
112 dm_writepowerindex(hw, 0x10);
104 } 113 }
105 114
106 rtlpriv->dm.last_dtp_lvl = rtlpriv->dm.dynamic_txhighpower_lvl; 115 rtlpriv->dm.last_dtp_lvl = rtlpriv->dm.dynamic_txhighpower_lvl;
diff --git a/drivers/net/wireless/rtlwifi/rtl8192cu/dm.h b/drivers/net/wireless/rtlwifi/rtl8192cu/dm.h
index d947e7d350bb..fafa6bac2a3f 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192cu/dm.h
+++ b/drivers/net/wireless/rtlwifi/rtl8192cu/dm.h
@@ -30,3 +30,6 @@
30#include "../rtl8192ce/dm.h" 30#include "../rtl8192ce/dm.h"
31 31
32void rtl92cu_dm_dynamic_txpower(struct ieee80211_hw *hw); 32void rtl92cu_dm_dynamic_txpower(struct ieee80211_hw *hw);
33void dm_savepowerindex(struct ieee80211_hw *hw);
34void dm_writepowerindex(struct ieee80211_hw *hw, u8 value);
35void dm_restorepowerindex(struct ieee80211_hw *hw);