Lines Matching +full:rates +full:- +full:mcs
3 * Copyright (c) 2016-2017, Qualcomm Atheros, Inc.
73 cap_len = sizeof(*cap) - sizeof(cap->optional); in ieee80211_invalid_he_cap_size()
77 cap_len += ieee80211_he_mcs_set_size(cap->he_phy_capab_info); in ieee80211_invalid_he_cap_size()
83 cap->he_phy_capab_info); in ieee80211_invalid_he_cap_size()
93 struct hostapd_hw_modes *mode = hapd->iface->current_mode; in hostapd_eid_he_capab()
101 ie_size = sizeof(*cap) - sizeof(cap->optional); in hostapd_eid_he_capab()
102 ppet_size = ieee80211_he_ppet_size(mode->he_capab[opmode].ppet[0], in hostapd_eid_he_capab()
103 mode->he_capab[opmode].phy_cap); in hostapd_eid_he_capab()
105 switch (hapd->iface->conf->he_oper_chwidth) { in hostapd_eid_he_capab()
133 os_memcpy(cap->he_mac_capab_info, mode->he_capab[opmode].mac_cap, in hostapd_eid_he_capab()
135 os_memcpy(cap->he_phy_capab_info, mode->he_capab[opmode].phy_cap, in hostapd_eid_he_capab()
137 os_memcpy(cap->optional, mode->he_capab[opmode].mcs, mcs_nss_size); in hostapd_eid_he_capab()
139 os_memcpy(&cap->optional[mcs_nss_size], in hostapd_eid_he_capab()
140 mode->he_capab[opmode].ppet, ppet_size); in hostapd_eid_he_capab()
142 if (hapd->iface->conf->he_phy_capab.he_su_beamformer) in hostapd_eid_he_capab()
143 cap->he_phy_capab_info[HE_PHYCAP_SU_BEAMFORMER_CAPAB_IDX] |= in hostapd_eid_he_capab()
146 cap->he_phy_capab_info[HE_PHYCAP_SU_BEAMFORMER_CAPAB_IDX] &= in hostapd_eid_he_capab()
149 if (hapd->iface->conf->he_phy_capab.he_su_beamformee) in hostapd_eid_he_capab()
150 cap->he_phy_capab_info[HE_PHYCAP_SU_BEAMFORMEE_CAPAB_IDX] |= in hostapd_eid_he_capab()
153 cap->he_phy_capab_info[HE_PHYCAP_SU_BEAMFORMEE_CAPAB_IDX] &= in hostapd_eid_he_capab()
156 if (hapd->iface->conf->he_phy_capab.he_mu_beamformer) in hostapd_eid_he_capab()
157 cap->he_phy_capab_info[HE_PHYCAP_MU_BEAMFORMER_CAPAB_IDX] |= in hostapd_eid_he_capab()
160 cap->he_phy_capab_info[HE_PHYCAP_MU_BEAMFORMER_CAPAB_IDX] &= in hostapd_eid_he_capab()
163 cap->he_phy_capab_info[HE_PHYCAP_CHANNEL_WIDTH_SET_IDX] &= in hostapd_eid_he_capab()
179 if (!hapd->iface->current_mode) in hostapd_eid_he_operation()
182 if (is_6ghz_op_class(hapd->iconf->op_class)) in hostapd_eid_he_operation()
192 if (hapd->iface->conf->he_op.he_default_pe_duration) in hostapd_eid_he_operation()
193 params |= (hapd->iface->conf->he_op.he_default_pe_duration << in hostapd_eid_he_operation()
196 if (hapd->iface->conf->he_op.he_twt_required) in hostapd_eid_he_operation()
199 if (hapd->iface->conf->he_op.he_rts_threshold) in hostapd_eid_he_operation()
200 params |= (hapd->iface->conf->he_op.he_rts_threshold << in hostapd_eid_he_operation()
203 if (hapd->iface->conf->he_op.he_er_su_disable) in hostapd_eid_he_operation()
206 if (hapd->iface->conf->he_op.he_bss_color_disabled || in hostapd_eid_he_operation()
207 hapd->cca_in_progress) in hostapd_eid_he_operation()
209 if (hapd->iface->conf->he_op.he_bss_color_partial) in hostapd_eid_he_operation()
211 params |= hapd->iface->conf->he_op.he_bss_color << in hostapd_eid_he_operation()
214 /* HE minimum required basic MCS and NSS for STAs */ in hostapd_eid_he_operation()
215 oper->he_mcs_nss_set = in hostapd_eid_he_operation()
216 host_to_le16(hapd->iface->conf->he_op.he_basic_mcs_nss_set); in hostapd_eid_he_operation()
222 if (is_6ghz_op_class(hapd->iconf->op_class)) { in hostapd_eid_he_operation()
224 hostapd_get_oper_chwidth(hapd->iconf); in hostapd_eid_he_operation()
225 u8 seg0 = hapd->iconf->he_oper_centr_freq_seg0_idx; in hostapd_eid_he_operation()
226 u8 seg1 = hostapd_get_oper_centr_freq_seg1_idx(hapd->iconf); in hostapd_eid_he_operation()
233 hapd->iconf->channel, in hostapd_eid_he_operation()
239 seg0 = hapd->iconf->channel; in hostapd_eid_he_operation()
244 * IEEE Std 802.11ax-2021, 9.4.2.249 HE Operation element, in hostapd_eid_he_operation()
245 * Figure 9-788k in hostapd_eid_he_operation()
247 *pos++ = hapd->iconf->channel; /* Primary Channel */ in hostapd_eid_he_operation()
250 * bits 0-1: Channel Width in hostapd_eid_he_operation()
252 * bits 3-5: Regulatory Info in hostapd_eid_he_operation()
260 control |= hapd->iconf->he_6ghz_reg_pwr_type << in hostapd_eid_he_operation()
273 if (hapd->iconf->channel < seg0) in hostapd_eid_he_operation()
274 seg0 -= 8; in hostapd_eid_he_operation()
285 oper->he_oper_params = host_to_le32(params); in hostapd_eid_he_operation()
297 pos = (u8 *) &hapd->iface->conf->he_mu_edca; in hostapd_eid_he_mu_edca_parameter_set()
311 os_memcpy(edca, &hapd->iface->conf->he_mu_edca, sizeof(*edca)); in hostapd_eid_he_mu_edca_parameter_set()
328 if (!hapd->iface->conf->spr.sr_control) in hostapd_eid_spatial_reuse()
331 if (hapd->iface->conf->spr.sr_control & in hostapd_eid_spatial_reuse()
335 if (hapd->iface->conf->spr.sr_control & in hostapd_eid_spatial_reuse()
346 spr->sr_ctrl = hapd->iface->conf->spr.sr_control; in hostapd_eid_spatial_reuse()
348 spr_param = spr->params; in hostapd_eid_spatial_reuse()
349 if (spr->sr_ctrl & SPATIAL_REUSE_NON_SRG_OFFSET_PRESENT) { in hostapd_eid_spatial_reuse()
351 hapd->iface->conf->spr.non_srg_obss_pd_max_offset; in hostapd_eid_spatial_reuse()
354 if (spr->sr_ctrl & SPATIAL_REUSE_SRG_INFORMATION_PRESENT) { in hostapd_eid_spatial_reuse()
355 *spr_param++ = hapd->iface->conf->spr.srg_obss_pd_min_offset; in hostapd_eid_spatial_reuse()
356 *spr_param++ = hapd->iface->conf->spr.srg_obss_pd_max_offset; in hostapd_eid_spatial_reuse()
358 hapd->iface->conf->spr.srg_bss_color_bitmap, 8); in hostapd_eid_spatial_reuse()
361 hapd->iface->conf->spr.srg_partial_bssid_bitmap, 8); in hostapd_eid_spatial_reuse()
371 struct hostapd_config *conf = hapd->iface->conf; in hostapd_eid_he_6ghz_band_cap()
372 struct hostapd_hw_modes *mode = hapd->iface->current_mode; in hostapd_eid_he_6ghz_band_cap()
378 if (!mode || !is_6ghz_op_class(hapd->iconf->op_class) || in hostapd_eid_he_6ghz_band_cap()
379 !is_6ghz_freq(hapd->iface->freq)) in hostapd_eid_he_6ghz_band_cap()
382 he_cap = &mode->he_capab[IEEE80211_MODE_AP]; in hostapd_eid_he_6ghz_band_cap()
383 capab = he_cap->he_6ghz_capa & HE_6GHZ_BAND_CAP_MIN_MPDU_START; in hostapd_eid_he_6ghz_band_cap()
384 capab |= (conf->he_6ghz_max_ampdu_len_exp << in hostapd_eid_he_6ghz_band_cap()
387 capab |= (conf->he_6ghz_max_mpdu << in hostapd_eid_he_6ghz_band_cap()
391 if (conf->he_6ghz_rx_ant_pat) in hostapd_eid_he_6ghz_band_cap()
393 if (conf->he_6ghz_tx_ant_pat) in hostapd_eid_he_6ghz_band_cap()
402 cap->capab = host_to_le16(capab); in hostapd_eid_he_6ghz_band_cap()
433 if (!hapd->iface->current_mode) in check_valid_he_mcs()
435 ap_mcs_set = (u16 *) hapd->iface->current_mode->he_capab[opmode].mcs; in check_valid_he_mcs()
437 sta_he_capab)->optional; in check_valid_he_mcs()
441 * allowed MCS in any supported number of streams, i.e., STA is in check_valid_he_mcs()
442 * advertising 3 (not supported) as HE MCS rates for all supported in check_valid_he_mcs()
445 switch (hapd->iface->conf->he_oper_chwidth) { in check_valid_he_mcs()
460 /* AP Tx MCS map vs. STA Rx MCS map */ in check_valid_he_mcs()
477 "No matching HE MCS found between AP TX and STA RX"); in check_valid_he_mcs()
487 if (!he_capab || !(sta->flags & WLAN_STA_WMM) || in copy_sta_he_capab()
488 !hapd->iconf->ieee80211ax || hapd->conf->disable_11ax || in copy_sta_he_capab()
492 sta->flags &= ~WLAN_STA_HE; in copy_sta_he_capab()
493 os_free(sta->he_capab); in copy_sta_he_capab()
494 sta->he_capab = NULL; in copy_sta_he_capab()
498 if (!sta->he_capab) { in copy_sta_he_capab()
499 sta->he_capab = in copy_sta_he_capab()
501 if (!sta->he_capab) in copy_sta_he_capab()
505 sta->flags |= WLAN_STA_HE; in copy_sta_he_capab()
506 os_memset(sta->he_capab, 0, sizeof(struct ieee80211_he_capabilities)); in copy_sta_he_capab()
507 os_memcpy(sta->he_capab, he_capab, he_capab_len); in copy_sta_he_capab()
508 sta->he_capab_len = he_capab_len; in copy_sta_he_capab()
517 if (!he_6ghz_capab || !hapd->iconf->ieee80211ax || in copy_sta_he_6ghz_capab()
518 hapd->conf->disable_11ax || in copy_sta_he_6ghz_capab()
519 !is_6ghz_op_class(hapd->iconf->op_class)) { in copy_sta_he_6ghz_capab()
520 sta->flags &= ~WLAN_STA_6GHZ; in copy_sta_he_6ghz_capab()
521 os_free(sta->he_6ghz_capab); in copy_sta_he_6ghz_capab()
522 sta->he_6ghz_capab = NULL; in copy_sta_he_6ghz_capab()
526 if (!sta->he_6ghz_capab) { in copy_sta_he_6ghz_capab()
527 sta->he_6ghz_capab = in copy_sta_he_6ghz_capab()
529 if (!sta->he_6ghz_capab) in copy_sta_he_6ghz_capab()
533 sta->flags |= WLAN_STA_6GHZ; in copy_sta_he_6ghz_capab()
534 os_memcpy(sta->he_6ghz_capab, he_6ghz_capab, in copy_sta_he_6ghz_capab()
546 if (!hapd->iface->current_mode || in hostapd_get_he_twt_responder()
547 !hapd->iface->current_mode->he_capab[mode].he_supported || in hostapd_get_he_twt_responder()
548 !hapd->iconf->ieee80211ax || hapd->conf->disable_11ax) in hostapd_get_he_twt_responder()
551 mac_cap = hapd->iface->current_mode->he_capab[mode].mac_cap; in hostapd_get_he_twt_responder()
554 hapd->iface->conf->he_op.he_twt_responder; in hostapd_get_he_twt_responder()
560 if (!hapd->cca_in_progress) in hostapd_eid_cca()
567 *eid++ = hapd->cca_count; /* Color Switch Countdown */ in hostapd_eid_cca()
568 *eid++ = hapd->cca_color; /* New BSS Color Information */ in hostapd_eid_cca()