rtlwifi: Add board type for 8723be and 8192ee
authorPing-Ke Shih <pkshih@realtek.com>
Sun, 2 Jul 2017 18:12:32 +0000 (13:12 -0500)
committerKalle Valo <kvalo@codeaurora.org>
Fri, 28 Jul 2017 15:16:35 +0000 (18:16 +0300)
With correct board_type, the phy praser can choose correct parameters.

Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Yan-Hsuan Chuang <yhchuang@realtek.com>
Cc: Birming Chiu <birming@realtek.com>
Cc: Shaofu <shaofu@realtek.com>
Cc: Steven Ting <steventing@realtek.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/realtek/rtlwifi/rtl8192ee/hw.c
drivers/net/wireless/realtek/rtlwifi/rtl8723be/hw.c

index d84ac7a..ef9394b 100644 (file)
@@ -2133,7 +2133,12 @@ static void _rtl92ee_read_adapter_info(struct ieee80211_hw *hw)
        if ((*(u8 *)&hwinfo[EEPROM_RF_BOARD_OPTION_92E]) == 0xFF)
                rtlefuse->board_type = 0;
 
+       if (rtlpriv->btcoexist.btc_info.btcoexist == 1)
+               rtlefuse->board_type |= BIT(2); /* ODM_BOARD_BT */
+
        rtlhal->board_type = rtlefuse->board_type;
+       RT_TRACE(rtlpriv, COMP_INIT, DBG_LOUD,
+                "board_type = 0x%x\n", rtlefuse->board_type);
        /*parse xtal*/
        rtlefuse->crystalcap = hwinfo[EEPROM_XTAL_92E];
        if (hwinfo[EEPROM_XTAL_92E] == 0xFF)
index 2a7ad5f..0b9366e 100644 (file)
@@ -2114,6 +2114,13 @@ static void _rtl8723be_read_adapter_info(struct ieee80211_hw *hw,
                                                 rtlefuse->autoload_failflag,
                                                 hwinfo);
 
+       if (rtlpriv->btcoexist.btc_info.btcoexist == 1)
+               rtlefuse->board_type |= BIT(2); /* ODM_BOARD_BT */
+
+       rtlhal->board_type = rtlefuse->board_type;
+       RT_TRACE(rtlpriv, COMP_INIT, DBG_LOUD,
+                "board_type = 0x%x\n", rtlefuse->board_type);
+
        rtlhal->package_type = _rtl8723be_read_package_type(hw);
 
        /* set channel plan from efuse */