summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rtlwifi/rtl8192cu/rf.c
diff options
context:
space:
mode:
authorLarry Finger2013-06-18 20:25:05 +0200
committerJohn W. Linville2013-06-19 21:28:20 +0200
commit10d0b9030a3f86e1e26c710c7580524d7787d688 (patch)
tree9d0f70a6807a3332a2d1fd608868e43bf98fd131 /drivers/net/wireless/rtlwifi/rtl8192cu/rf.c
parentbrcmfmac: add sdio sg list support (diff)
downloadkernel-qcow2-linux-10d0b9030a3f86e1e26c710c7580524d7787d688.tar.gz
kernel-qcow2-linux-10d0b9030a3f86e1e26c710c7580524d7787d688.tar.xz
kernel-qcow2-linux-10d0b9030a3f86e1e26c710c7580524d7787d688.zip
rtlwifi: rtl8192cu: Fix duplicate if test
A typo causes routine rtl92cu_phy_rf6052_set_cck_txpower() to test the same condition twice. The problem was found using cppcheck-1.49, and the proper fix was verified against the pre-mac80211 version of the code. This patch was originally included as commit 1288aa4, but was accidentally reverted in a later patch. Reported-by: David Binderman <dcb314@hotmail.com> [original report] Reported-by: Andrea Morello <andrea.merello@gmail.com> [report of accidental reversion] Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: stable <stable@vger.kernel.org> [back to 2.6.39] Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rtlwifi/rtl8192cu/rf.c')
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192cu/rf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/rtlwifi/rtl8192cu/rf.c b/drivers/net/wireless/rtlwifi/rtl8192cu/rf.c
index 953f1a0f8532..2119313a737b 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192cu/rf.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192cu/rf.c
@@ -104,7 +104,7 @@ void rtl92cu_phy_rf6052_set_cck_txpower(struct ieee80211_hw *hw,
tx_agc[RF90_PATH_A] = 0x10101010;
tx_agc[RF90_PATH_B] = 0x10101010;
} else if (rtlpriv->dm.dynamic_txhighpower_lvl ==
- TXHIGHPWRLEVEL_LEVEL1) {
+ TXHIGHPWRLEVEL_LEVEL2) {
tx_agc[RF90_PATH_A] = 0x00000000;
tx_agc[RF90_PATH_B] = 0x00000000;
} else{