]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
hostapd: ucode: clear start_disabled when reloading a started BSS
authorFelix Fietkau <nbd@nbd.name>
Fri, 10 Jul 2026 11:59:30 +0000 (13:59 +0200)
committerFelix Fietkau <nbd@nbd.name>
Thu, 16 Jul 2026 09:50:21 +0000 (11:50 +0200)
On a radio shared with a STA every AP BSS is generated with
start_disabled=1. A smart reload that takes the full bss.set_config() path
restarts the BSS but never cleared start_disabled, so hostapd_start_beacon()
skipped beaconing and the AP went silently quiet until an unrelated
apsta_state event. Clear it when the BSS was already started, matching the
add_bss path.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
package/network/services/hostapd/src/src/ap/ucode.c

index 5e16293d40206f88c6b8f92519a6a8d756ebc282..08a83c529c0116a96c95faf954365d69d12380d5 100644 (file)
@@ -297,6 +297,14 @@ uc_hostapd_bss_set_config(uc_vm_t *vm, size_t nargs)
        started = hapd->started;
        __uc_hostapd_bss_stop(hapd);
 
+       /*
+        * start_disabled is only meaningful for the initial apsta bring-up. When
+        * re-applying config to a BSS that was already started, clear it so the
+        * restart keeps beaconing instead of silently going quiet.
+        */
+       if (started)
+               conf->bss[idx]->start_disabled = 0;
+
        old_bss = hapd->conf;
        for (i = 0; i < iface->conf->num_bss; i++)
                if (iface->conf->bss[i] == hapd->conf)