Preparatory step for adding support for RTL8188EU chips. We follow the same approach as with efuse here. Signed-off-by: Jakub Sitnicki <jsitnicki@xxxxxxxxx> --- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 4 +++- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c index a7d172a..83cdc2a 100644 --- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c +++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c @@ -1490,7 +1490,7 @@ static void rtl8723au_config_channel(struct ieee80211_hw *hw) static void rtl8723a_set_tx_power(struct rtl8xxxu_priv *priv, int channel, bool ht40) { - struct rtl8723au_tx_power *tx_power = &priv->tx_power; + struct rtl8723au_tx_power *tx_power = &priv->tx_power.tx_power8723; u8 cck[RTL8723A_MAX_RF_PATHS], ofdm[RTL8723A_MAX_RF_PATHS]; u8 ofdmbase[RTL8723A_MAX_RF_PATHS], mcsbase[RTL8723A_MAX_RF_PATHS]; u32 val32, ofdm_a, ofdm_b, mcs_a, mcs_b; @@ -1781,7 +1781,7 @@ static int rtl8xxxu_identify_chip(struct rtl8xxxu_priv *priv) static int rtl8723au_parse_efuse(struct rtl8xxxu_priv *priv) { struct rtl8723au_efuse *efuse = &priv->efuse_wifi.efuse8723; - struct rtl8723au_tx_power *tx_power = &priv->tx_power; + struct rtl8723au_tx_power *tx_power = &priv->tx_power.tx_power8723; if (efuse->rtl_id != cpu_to_le16(0x8129)) return -EINVAL; @@ -1826,7 +1826,7 @@ static int rtl8723au_parse_efuse(struct rtl8xxxu_priv *priv) static int rtl8192cu_parse_efuse(struct rtl8xxxu_priv *priv) { struct rtl8192cu_efuse *efuse = &priv->efuse_wifi.efuse8192; - struct rtl8723au_tx_power *tx_power = &priv->tx_power; + struct rtl8723au_tx_power *tx_power = &priv->tx_power.tx_power8723; int i; if (efuse->rtl_id != cpu_to_le16(0x8129)) diff --git a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h index ccfbc10..1a767eb 100644 --- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h +++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h @@ -598,7 +598,9 @@ struct rtl8xxxu_priv { u8 mac_addr[ETH_ALEN]; char chip_name[8]; - struct rtl8723au_tx_power tx_power; + union { + struct rtl8723au_tx_power tx_power8723; + } tx_power; u32 chip_cut:4; u32 rom_rev:4; u32 is_multi_func:1; -- 2.1.0 -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html