blob: 46b553e6d8061af0d19d41206fa10d79514489f1 [file] [log] [blame]
developer8eb72a32023-03-30 08:32:07 +08001From b5a2e258df9261533c840fa8b7b8d7947894c31d Mon Sep 17 00:00:00 2001
developer9a3c8b32023-02-20 17:37:56 +08002From: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
3Date: Mon, 20 Feb 2023 16:58:20 +0800
developer8eb72a32023-03-30 08:32:07 +08004Subject: [PATCH 19/25] hostapd: mtk: Fix auto ht issue when switching to DFS
developer81939a52023-03-25 15:31:11 +08005 channel
developer9a3c8b32023-02-20 17:37:56 +08006
7Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
8---
9 hostapd/ctrl_iface.c | 12 ++++++------
10 1 file changed, 6 insertions(+), 6 deletions(-)
11
12diff --git a/hostapd/ctrl_iface.c b/hostapd/ctrl_iface.c
developer81939a52023-03-25 15:31:11 +080013index 61c9e80..c33b7a4 100644
developer9a3c8b32023-02-20 17:37:56 +080014--- a/hostapd/ctrl_iface.c
15+++ b/hostapd/ctrl_iface.c
16@@ -2698,6 +2698,12 @@ static int hostapd_ctrl_iface_chan_switch(struct hostapd_iface *iface,
17 break;
18 }
19
20+ if (os_strstr(pos, " auto-ht")) {
21+ settings.freq_params.ht_enabled = iface->conf->ieee80211n;
22+ settings.freq_params.vht_enabled = iface->conf->ieee80211ac;
23+ settings.freq_params.he_enabled = iface->conf->ieee80211ax;
24+ }
25+
26 if (settings.freq_params.center_freq1)
27 dfs_range += hostapd_is_dfs_overlap(
28 iface, bandwidth, settings.freq_params.center_freq1);
29@@ -2735,12 +2741,6 @@ static int hostapd_ctrl_iface_chan_switch(struct hostapd_iface *iface,
30 return 0;
31 }
32
33- if (os_strstr(pos, " auto-ht")) {
34- settings.freq_params.ht_enabled = iface->conf->ieee80211n;
35- settings.freq_params.vht_enabled = iface->conf->ieee80211ac;
36- settings.freq_params.he_enabled = iface->conf->ieee80211ax;
37- }
38-
39 for (i = 0; i < iface->num_bss; i++) {
40
41 /* Save CHAN_SWITCH VHT, HE, and EHT config */
42--
432.18.0
44