aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
authorForest Bond <forest.bond@rapidrollout.com>2012-07-13 12:26:06 -0400
committerJohn W. Linville <linville@tuxdriver.com>2012-07-17 15:11:32 -0400
commitf1b00f4dab29b57bdf1bc03ef12020b280fd2a72 (patch)
treed570601b5dcfa8530b778ec57447825f3ff21efc /drivers/net/wireless
parent1924b4e294df4e97ad22557700e554af409569bc (diff)
rtlwifi: rtl8192de: Fix phy-based version calculation
Commit d83579e2a50ac68389e6b4c58b845c702cf37516 incorporated some changes from the vendor driver that made it newly important that the calculated hardware version correctly include the CHIP_92D bit, as all of the IS_92D_* macros were changed to depend on it. However, this bit was being unset for dual-mac, dual-phy devices. The vendor driver behavior was modified to not do this, but unfortunately this change was not picked up along with the others. This caused scanning in the 2.4GHz band to be broken, and possibly other bugs as well. This patch brings the version calculation logic in parity with the vendor driver in this regard, and in doing so fixes the regression. However, the version calculation code in general continues to be largely incoherent and messy, and needs to be cleaned up. Signed-off-by: Forest Bond <forest.bond@rapidrollout.com> Cc: Stable <stable@vger.kernel.org> [v3.2+] Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192de/phy.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/wireless/rtlwifi/rtl8192de/phy.c b/drivers/net/wireless/rtlwifi/rtl8192de/phy.c
index 18380a7829f1..442031256bce 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192de/phy.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192de/phy.c
@@ -3345,21 +3345,21 @@ void rtl92d_phy_config_macphymode_info(struct ieee80211_hw *hw)
3345 switch (rtlhal->macphymode) { 3345 switch (rtlhal->macphymode) {
3346 case DUALMAC_SINGLEPHY: 3346 case DUALMAC_SINGLEPHY:
3347 rtlphy->rf_type = RF_2T2R; 3347 rtlphy->rf_type = RF_2T2R;
3348 rtlhal->version |= CHIP_92D_SINGLEPHY; 3348 rtlhal->version |= RF_TYPE_2T2R;
3349 rtlhal->bandset = BAND_ON_BOTH; 3349 rtlhal->bandset = BAND_ON_BOTH;
3350 rtlhal->current_bandtype = BAND_ON_2_4G; 3350 rtlhal->current_bandtype = BAND_ON_2_4G;
3351 break; 3351 break;
3352 3352
3353 case SINGLEMAC_SINGLEPHY: 3353 case SINGLEMAC_SINGLEPHY:
3354 rtlphy->rf_type = RF_2T2R; 3354 rtlphy->rf_type = RF_2T2R;
3355 rtlhal->version |= CHIP_92D_SINGLEPHY; 3355 rtlhal->version |= RF_TYPE_2T2R;
3356 rtlhal->bandset = BAND_ON_BOTH; 3356 rtlhal->bandset = BAND_ON_BOTH;
3357 rtlhal->current_bandtype = BAND_ON_2_4G; 3357 rtlhal->current_bandtype = BAND_ON_2_4G;
3358 break; 3358 break;
3359 3359
3360 case DUALMAC_DUALPHY: 3360 case DUALMAC_DUALPHY:
3361 rtlphy->rf_type = RF_1T1R; 3361 rtlphy->rf_type = RF_1T1R;
3362 rtlhal->version &= (~CHIP_92D_SINGLEPHY); 3362 rtlhal->version &= RF_TYPE_1T1R;
3363 /* Now we let MAC0 run on 5G band. */ 3363 /* Now we let MAC0 run on 5G band. */
3364 if (rtlhal->interfaceindex == 0) { 3364 if (rtlhal->interfaceindex == 0) {
3365 rtlhal->bandset = BAND_ON_5G; 3365 rtlhal->bandset = BAND_ON_5G;