]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
Fix channel switch to disable VHT with HT
authorJouni Malinen <j@w1.fi>
Sat, 25 Oct 2014 08:27:48 +0000 (11:27 +0300)
committerJouni Malinen <j@w1.fi>
Sat, 25 Oct 2014 08:27:48 +0000 (11:27 +0300)
If both HT and VHT was enabled on AP and channel switch event from the
driver indicated that HT was disabled, VHT was left enabled. This
resulted in the following channel configuration failing. Fix this by
disabling VHT if HT gets disabled.

Signed-off-by: Jouni Malinen <j@w1.fi>
src/ap/drv_callbacks.c

index 9beb32245461053c9c09b67294a0107616c4c292..bcecac1c4f70e9f43fe78823cac0039c9e46e84e 100644 (file)
@@ -489,6 +489,8 @@ void hostapd_event_ch_switch(struct hostapd_data *hapd, int freq, int ht,
 
        hapd->iconf->channel = channel;
        hapd->iconf->ieee80211n = ht;
+       if (!ht)
+               hapd->iconf->ieee80211ac = 0;
        hapd->iconf->secondary_channel = offset;
        hapd->iconf->vht_oper_chwidth = chwidth;
        hapd->iconf->vht_oper_centr_freq_seg0_idx = seg0_idx;