blob: 06ceae8987260f382174aba0e1c95f789f43fc39 [file] [log] [blame]
developerb85e8752023-09-25 14:16:05 +08001From be727db37e753f0041b2789af3ecc1eff8c0f5db Mon Sep 17 00:00:00 2001
developer5e0a8d72023-05-12 18:58:17 +08002From: Evelyn Tsai <evelyn.tsai@mediatek.com>
3Date: Fri, 12 May 2023 05:23:00 +0800
developerb85e8752023-09-25 14:16:05 +08004Subject: [PATCH 23/38] hostapd: mtk: Fix setting wrong seg0 index for 5G
developer8b64f1a2023-05-02 10:31:58 +08005 center chan 159 BW40
6
7Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
8---
9 src/ap/ap_config.h | 3 ++-
10 1 file changed, 2 insertions(+), 1 deletion(-)
11
12diff --git a/src/ap/ap_config.h b/src/ap/ap_config.h
developerb85e8752023-09-25 14:16:05 +080013index d0e27b2..f03a957 100644
developer8b64f1a2023-05-02 10:31:58 +080014--- a/src/ap/ap_config.h
15+++ b/src/ap/ap_config.h
developerb85e8752023-09-25 14:16:05 +080016@@ -1308,7 +1308,8 @@ hostapd_set_oper_centr_freq_seg0_idx(struct hostapd_config *conf,
developer8b64f1a2023-05-02 10:31:58 +080017 #ifdef CONFIG_IEEE80211BE
18 if (conf->ieee80211be)
19 conf->eht_oper_centr_freq_seg0_idx = oper_centr_freq_seg0_idx;
20- if (center_idx_to_bw_6ghz(oper_centr_freq_seg0_idx) == 4)
21+ if (is_6ghz_op_class(conf->op_class) &&
22+ center_idx_to_bw_6ghz(oper_centr_freq_seg0_idx) == 4)
23 oper_centr_freq_seg0_idx +=
24 conf->channel > oper_centr_freq_seg0_idx ? 16 : -16;
25 #endif /* CONFIG_IEEE80211BE */
26--
developerbddc9db2023-09-11 13:34:36 +0800272.18.0
developer8b64f1a2023-05-02 10:31:58 +080028