Lines Matching +full:rates +full:- +full:mcs

3  * Copyright (c) 2002-2009, Jouni Malinen <j@w1.fi>
27 struct hostapd_hw_modes *mode = hapd->iface->current_mode; in hostapd_eid_vht_capabilities()
30 if (!mode || is_6ghz_op_class(hapd->iconf->op_class)) in hostapd_eid_vht_capabilities()
33 if (mode->mode == HOSTAPD_MODE_IEEE80211G && hapd->conf->vendor_vht && in hostapd_eid_vht_capabilities()
34 mode->vht_capab == 0 && hapd->iface->hw_features) { in hostapd_eid_vht_capabilities()
37 for (i = 0; i < hapd->iface->num_hw_features; i++) { in hostapd_eid_vht_capabilities()
38 if (hapd->iface->hw_features[i].mode == in hostapd_eid_vht_capabilities()
40 mode = &hapd->iface->hw_features[i]; in hostapd_eid_vht_capabilities()
51 cap->vht_capabilities_info = host_to_le32( in hostapd_eid_vht_capabilities()
52 hapd->iface->conf->vht_capab); in hostapd_eid_vht_capabilities()
57 hapd_nsts = le_to_host32(cap->vht_capabilities_info); in hostapd_eid_vht_capabilities()
59 cap->vht_capabilities_info &= in hostapd_eid_vht_capabilities()
62 cap->vht_capabilities_info |= in hostapd_eid_vht_capabilities()
66 /* Supported MCS set comes from hw */ in hostapd_eid_vht_capabilities()
67 os_memcpy(&cap->vht_supported_mcs_set, mode->vht_mcs_set, 8); in hostapd_eid_vht_capabilities()
80 hostapd_get_oper_chwidth(hapd->iconf); in hostapd_eid_vht_operation()
81 u8 seg0 = hapd->iconf->vht_oper_centr_freq_seg0_idx; in hostapd_eid_vht_operation()
82 u8 seg1 = hapd->iconf->vht_oper_centr_freq_seg1_idx; in hostapd_eid_vht_operation()
87 if (is_6ghz_op_class(hapd->iconf->op_class)) in hostapd_eid_vht_operation()
99 hapd->iconf->channel, in hostapd_eid_vht_operation()
109 oper->vht_op_info_chan_center_freq_seg0_idx = seg0; in hostapd_eid_vht_operation()
110 oper->vht_op_info_chan_center_freq_seg1_idx = seg1; in hostapd_eid_vht_operation()
112 oper->vht_op_info_chwidth = oper_chwidth; in hostapd_eid_vht_operation()
118 oper->vht_op_info_chwidth = CHANWIDTH_80MHZ; in hostapd_eid_vht_operation()
119 oper->vht_op_info_chan_center_freq_seg1_idx = in hostapd_eid_vht_operation()
120 oper->vht_op_info_chan_center_freq_seg0_idx; in hostapd_eid_vht_operation()
121 if (hapd->iconf->channel < in hostapd_eid_vht_operation()
122 hapd->iconf->vht_oper_centr_freq_seg0_idx) in hostapd_eid_vht_operation()
123 oper->vht_op_info_chan_center_freq_seg0_idx -= 8; in hostapd_eid_vht_operation()
125 oper->vht_op_info_chan_center_freq_seg0_idx += 8; in hostapd_eid_vht_operation()
131 oper->vht_op_info_chwidth = CHANWIDTH_80MHZ; in hostapd_eid_vht_operation()
134 /* VHT Basic MCS set comes from hw */ in hostapd_eid_vht_operation()
135 /* Hard code 1 stream, MCS0-7 is a min Basic VHT MCS rates */ in hostapd_eid_vht_operation()
136 oper->vht_basic_mcs_set = host_to_le16(0xfffc); in hostapd_eid_vht_operation()
156 * allowed MCS in any supported number of streams, i.e., STA is in check_valid_vht_mcs()
157 * advertising 3 (not supported) as VHT MCS rates for all supported in check_valid_vht_mcs()
160 os_memcpy(&ap_vht_cap.vht_supported_mcs_set, mode->vht_mcs_set, in check_valid_vht_mcs()
164 /* AP Tx MCS map vs. STA Rx MCS map */ in check_valid_vht_mcs()
165 sta_rx_mcs_set = le_to_host16(vht_cap->vht_supported_mcs_set.rx_map); in check_valid_vht_mcs()
179 "No matching VHT MCS found between AP TX and STA RX"); in check_valid_vht_mcs()
187 /* Disable VHT caps for STAs associated to no-VHT BSSes. */ in copy_sta_vht_capab()
188 if (!vht_capab || !(sta->flags & WLAN_STA_WMM) || in copy_sta_vht_capab()
189 !hapd->iconf->ieee80211ac || hapd->conf->disable_11ac || in copy_sta_vht_capab()
190 !check_valid_vht_mcs(hapd->iface->current_mode, vht_capab)) { in copy_sta_vht_capab()
191 sta->flags &= ~WLAN_STA_VHT; in copy_sta_vht_capab()
192 os_free(sta->vht_capabilities); in copy_sta_vht_capab()
193 sta->vht_capabilities = NULL; in copy_sta_vht_capab()
197 if (sta->vht_capabilities == NULL) { in copy_sta_vht_capab()
198 sta->vht_capabilities = in copy_sta_vht_capab()
200 if (sta->vht_capabilities == NULL) in copy_sta_vht_capab()
204 sta->flags |= WLAN_STA_VHT; in copy_sta_vht_capab()
205 os_memcpy(sta->vht_capabilities, vht_capab, in copy_sta_vht_capab()
216 os_free(sta->vht_operation); in copy_sta_vht_oper()
217 sta->vht_operation = NULL; in copy_sta_vht_oper()
221 if (!sta->vht_operation) { in copy_sta_vht_oper()
222 sta->vht_operation = in copy_sta_vht_oper()
224 if (!sta->vht_operation) in copy_sta_vht_oper()
228 os_memcpy(sta->vht_operation, vht_oper, in copy_sta_vht_oper()
242 hapd->conf->disable_11ac) in copy_sta_vendor_vht()
251 (int) vht_capab_len > ie + len - vht_capab - 2) in copy_sta_vendor_vht()
255 if (sta->vht_capabilities == NULL) { in copy_sta_vendor_vht()
256 sta->vht_capabilities = in copy_sta_vendor_vht()
258 if (sta->vht_capabilities == NULL) in copy_sta_vendor_vht()
262 sta->flags |= WLAN_STA_VHT | WLAN_STA_VENDOR_VHT; in copy_sta_vendor_vht()
263 os_memcpy(sta->vht_capabilities, vht_capab, in copy_sta_vendor_vht()
268 sta->flags &= ~WLAN_STA_VENDOR_VHT; in copy_sta_vendor_vht()
278 if (!hapd->iface->current_mode || in hostapd_eid_vendor_vht()
279 hapd->iface->current_mode->mode != HOSTAPD_MODE_IEEE80211G) in hostapd_eid_vendor_vht()
301 sta->flags &= ~WLAN_STA_VHT_OPMODE_ENABLED; in set_sta_vht_opmode()
305 sta->flags |= WLAN_STA_VHT_OPMODE_ENABLED; in set_sta_vht_opmode()
306 sta->vht_opmode = *vht_oper_notif; in set_sta_vht_opmode()
321 cap = le_to_host32(neg_vht_cap->vht_capabilities_info); in hostapd_get_vht_capab()
322 own_cap = hapd->iconf->vht_capab; in hostapd_get_vht_capab()
370 neg_vht_cap->vht_capabilities_info = host_to_le32(cap); in hostapd_get_vht_capab()