diff mbox series

Fix channel switch wrapper doesn't build when switching from HT to VHT/HE

Message ID CA+wtz68TkVbo0YFSCGc=BD1ruq=fA+G12Y0Xen7FJ6mTgeA+LQ@mail.gmail.com
State Superseded
Headers show
Series Fix channel switch wrapper doesn't build when switching from HT to VHT/HE | expand

Commit Message

peterhuang Aug. 16, 2021, 10:56 a.m. UTC
From 2e70bb620afb541d491b0ff201880d329df30921 Mon Sep 17 00:00:00 2001
From: peterhuang <peter801117.cs03g@g2.nctu.edu.tw>
Date: Mon, 16 Aug 2021 17:59:00 +0800
Subject: [PATCH] Fix channel switch wrapper doesn't build when
switching from HT to VHT/HE

Because ieee80211ac and ieee80211ax don't update before channel switch done,
hostapd doesn't build the channel switch wrapper element
when it switches from HT to bandwidth more than 40M of VHT/HE.

Signed-off-by: peterhuang <peter801117.cs03g@g2.nctu.edu.tw>
---
 src/ap/beacon.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

  pos = hostapd_get_rsnxe(hapd, pos, epos - pos);
@@ -1558,9 +1556,7 @@ int ieee802_11_build_ap_params(struct hostapd_data *hapd,
  tailpos = hostapd_eid_txpower_envelope(hapd, tailpos);
 #endif /* CONFIG_IEEE80211AX */

- if ((hapd->iconf->ieee80211ac && !hapd->conf->disable_11ac) ||
-     (hapd->iconf->ieee80211ax && !hapd->conf->disable_11ax))
- tailpos = hostapd_eid_wb_chsw_wrapper(hapd, tailpos);
+ tailpos = hostapd_eid_wb_chsw_wrapper(hapd, tailpos);

  tailpos = hostapd_eid_fils_indic(hapd, tailpos, 0);
  tailpos = hostapd_get_rsnxe(hapd, tailpos, tailend - tailpos);
diff mbox series

Patch

diff --git a/src/ap/beacon.c b/src/ap/beacon.c
index 15fc2b3db..096de6a2a 100644
--- a/src/ap/beacon.c
+++ b/src/ap/beacon.c
@@ -569,9 +569,7 @@  static u8 * hostapd_gen_probe_resp(struct
hostapd_data *hapd,
  pos = hostapd_eid_txpower_envelope(hapd, pos);
 #endif /* CONFIG_IEEE80211AX */

- if ((hapd->iconf->ieee80211ac && !hapd->conf->disable_11ac) ||
-     (hapd->iconf->ieee80211ax && !hapd->conf->disable_11ax))
- pos = hostapd_eid_wb_chsw_wrapper(hapd, pos);
+ pos = hostapd_eid_wb_chsw_wrapper(hapd, pos);

  pos = hostapd_eid_fils_indic(hapd, pos, 0);