Currently, hostapd tries to access MLO related functions and structures
even when 'ieee80211be' is unset, as 'mld_ap' is set. This is wrong and
at times, it leads to unexpected issues.
Address this by rejecting the configuration when mld_ap is set, while
'ieee80211be' is unset or disable_11be is set.
While at it, clear the mld_ap while disable_11be flag is modified during
configuration validation.
Signed-off-by: Aditya Kumar Singh <aditya.kumar.singh@oss.qualcomm.com>
Co-developed-by: Manish Dharanenthiran <manish.dharanenthiran@oss.qualcomm.com>
Signed-off-by: Manish Dharanenthiran <manish.dharanenthiran@oss.qualcomm.com>
#ifdef CONFIG_IEEE80211BE
if (full_config && !bss->disable_11be && bss->disable_11ax) {
bss->disable_11be = true;
+ bss->mld_ap = 0;
wpa_printf(MSG_INFO,
"Disabling IEEE 802.11be as IEEE 802.11ax is disabled for this BSS");
}
wpa_printf(MSG_INFO,
"Enabling beacon protection as IEEE 802.11be is enabled for this BSS");
}
+
+ if ((!conf->ieee80211be || bss->disable_11be) && bss->mld_ap) {
+ wpa_printf(MSG_INFO,
+ "Cannot enable mld_ap when IEEE 802.11be is disabled");
+ return -1;
+ }
#endif /* CONFIG_IEEE80211BE */
if (full_config && bss->ignore_broadcast_ssid && conf->mbssid) {