blob: a29ec33c29ebf406c13a7b5a8324e77b906c4076 [file] [log] [blame]
developer81939a52023-03-25 15:31:11 +08001From 61b475daa5dbf9802932657943d1322cb5c8f5b3 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
developer81939a52023-03-25 15:31:11 +08004Subject: [PATCH 19/24] hostapd: mtk: Fix auto ht issue when switching to DFS
5 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