diff options
author | Igor Mitsyanko <igor.mitsyanko.os@quantenna.com> | 2017-10-31 04:04:48 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2017-11-10 05:30:55 +0300 |
commit | d42df85f7d853ae155d7708cc57118a0d6925d4f (patch) | |
tree | 4d84c1d9f4fad3cf61867bcc3354752ff769a66a /drivers/net/wireless/quantenna | |
parent | e294cbfda05640063a0da3ec69b9b19ed13ea2f8 (diff) | |
download | linux-d42df85f7d853ae155d7708cc57118a0d6925d4f.tar.xz |
qtnfmac: initialize HT/VHT caps "can override" masks
Information on which HT/VHT capabilities can be overridden is reported
per-MAC by wireless device.
Signed-off-by: Igor Mitsyanko <igor.mitsyanko.os@quantenna.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/quantenna')
4 files changed, 12 insertions, 9 deletions
diff --git a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c index 2f60331fc0dd..b6a25409d220 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c +++ b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c @@ -925,6 +925,8 @@ int qtnf_wiphy_register(struct qtnf_hw_info *hw_info, struct qtnf_wmac *mac) wiphy->available_antennas_rx = mac->macinfo.num_rx_chain; wiphy->max_ap_assoc_sta = mac->macinfo.max_ap_assoc_sta; + wiphy->ht_capa_mod_mask = &mac->macinfo.ht_cap_mod_mask; + wiphy->vht_capa_mod_mask = &mac->macinfo.vht_cap_mod_mask; ether_addr_copy(wiphy->perm_addr, mac->macaddr); diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.c b/drivers/net/wireless/quantenna/qtnfmac/commands.c index a7422c5a150b..35ff7e87ca00 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.c +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.c @@ -1110,9 +1110,10 @@ qtnf_cmd_resp_proc_mac_info(struct qtnf_wmac *mac, qlink_chan_width_mask_to_nl(le16_to_cpu( resp_info->radar_detect_widths)); - memcpy(&mac_info->ht_cap, &resp_info->ht_cap, sizeof(mac_info->ht_cap)); - memcpy(&mac_info->vht_cap, &resp_info->vht_cap, - sizeof(mac_info->vht_cap)); + memcpy(&mac_info->ht_cap_mod_mask, &resp_info->ht_cap_mod_mask, + sizeof(mac_info->ht_cap_mod_mask)); + memcpy(&mac_info->vht_cap_mod_mask, &resp_info->vht_cap_mod_mask, + sizeof(mac_info->vht_cap_mod_mask)); } static void qtnf_cmd_resp_band_fill_htcap(const u8 *info, diff --git a/drivers/net/wireless/quantenna/qtnfmac/core.h b/drivers/net/wireless/quantenna/qtnfmac/core.h index da2c24e2271d..74b94ce4f426 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/core.h +++ b/drivers/net/wireless/quantenna/qtnfmac/core.h @@ -103,8 +103,8 @@ struct qtnf_mac_info { u8 sretry_limit; u8 coverage_class; u8 radar_detect_widths; - struct ieee80211_ht_cap ht_cap; - struct ieee80211_vht_cap vht_cap; + struct ieee80211_ht_cap ht_cap_mod_mask; + struct ieee80211_vht_cap vht_cap_mod_mask; struct ieee80211_iface_limit *limits; size_t n_limits; }; diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink.h b/drivers/net/wireless/quantenna/qtnfmac/qlink.h index dfef7faa6fca..b2c4e27d1dd2 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink.h @@ -636,8 +636,8 @@ struct qlink_resp { * specified WMAC). * @num_tx_chain: Number of transmit chains used by WMAC. * @num_rx_chain: Number of receive chains used by WMAC. - * @vht_cap: VHT capabilities. - * @ht_cap: HT capabilities. + * @vht_cap_mod_mask: mask specifying which VHT capabilities can be altered. + * @ht_cap_mod_mask: mask specifying which HT capabilities can be altered. * @bands_cap: wireless bands WMAC can operate in, bitmap of &enum qlink_band. * @phymode_cap: PHY modes WMAC can operate in, bitmap of &enum qlink_phy_mode. * @max_ap_assoc_sta: Maximum number of associations supported by WMAC. @@ -649,8 +649,8 @@ struct qlink_resp_get_mac_info { u8 dev_mac[ETH_ALEN]; u8 num_tx_chain; u8 num_rx_chain; - struct ieee80211_vht_cap vht_cap; - struct ieee80211_ht_cap ht_cap; + struct ieee80211_vht_cap vht_cap_mod_mask; + struct ieee80211_ht_cap ht_cap_mod_mask; u8 bands_cap; u8 phymode_cap; __le16 max_ap_assoc_sta; |