wifi-scripts: ucode: add support for setting he_twt_responder

In hostapd conf this option is set to 1 by default.
Then it's set to 0 if the HE MAC capability bit is not present.

Add an option in wifi-scripts to manually control it.

Signed-off-by: Zhi-Jun You <hujy652@protonmail.com>
Link: https://github.com/openwrt/openwrt/pull/22577
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
This commit is contained in:
Zhi-Jun You 2026-03-23 18:06:10 +08:00 committed by Hauke Mehrtens
parent 20d6296141
commit 3b69cf0844
2 changed files with 9 additions and 1 deletions

View File

@ -334,6 +334,11 @@
"type": "boolean",
"default": false
},
"he_twt_responder": {
"description": "Whether TWT (HE) responder is enabled.",
"type": "boolean",
"default": true
},
"hostapd_options": {
"type": "array",
"items": {

View File

@ -426,12 +426,15 @@ function device_htmode_append(config) {
config.he_mu_beamformer = false;
if (!(he_phy_cap[7] & 0x1))
config.he_spr_psr_enabled = false;
if (!(he_mac_cap[0] & 0x4))
config.he_twt_responder = false;
if (!(he_mac_cap[0] & 0x1))
config.he_twt_required= false;
append_vars(config, [
'ieee80211ax', 'he_oper_chwidth', 'he_oper_centr_freq_seg0_idx',
'he_su_beamformer', 'he_su_beamformee', 'he_mu_beamformer', 'he_twt_required',
'he_su_beamformer', 'he_su_beamformee', 'he_mu_beamformer',
'he_twt_required', 'he_twt_responder',
'he_default_pe_duration', 'he_rts_threshold', 'he_mu_edca_qos_info_param_count',
'he_mu_edca_qos_info_q_ack', 'he_mu_edca_qos_info_queue_request', 'he_mu_edca_qos_info_txop_request',
'he_mu_edca_ac_be_aifsn', 'he_mu_edca_ac_be_aci', 'he_mu_edca_ac_be_ecwmin',