]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
HE: Obtain correct AP mode capabilities for hw_mode with 6 GHz support
authorSreeramya Soratkal <ssramya@codeaurora.org>
Fri, 9 Jul 2021 10:49:25 +0000 (16:19 +0530)
committerJouni Malinen <j@w1.fi>
Tue, 3 Aug 2021 16:48:12 +0000 (19:48 +0300)
Though both 5 GHz channels and 6 GHz channels report the mode as
HOSTAPD_MODE_IEEE80211A, there is a possibility of different HT/VHT/HE
capabilities being available between these bands. Use get_mode() to
obtain correct capabilities to cover cases where the driver reports
different capability values for the 5 GHz and 6 GHz channels.

Signed-off-by: Sreeramya Soratkal <ssramya@codeaurora.org>
wpa_supplicant/ap.c

index cdf0ed5c7b5f3c3e0c1f374e62a378eb38fc9872..6c0f68ac10e827897f257f01fe2feb01e5a785ef 100644 (file)
@@ -224,7 +224,8 @@ int wpa_supplicant_conf_ap_ht(struct wpa_supplicant *wpa_s,
                           "Determining HT/VHT options based on driver capabilities (freq=%u chan=%u)",
                           ssid->frequency, conf->channel);
 
-               mode = wpa_supplicant_find_hw_mode(wpa_s, conf->hw_mode);
+               mode = get_mode(wpa_s->hw.modes, wpa_s->hw.num_modes,
+                               conf->hw_mode, is_6ghz_freq(ssid->frequency));
 
                /* May drop to IEEE 802.11b if the driver does not support IEEE
                 * 802.11g */