[PATCH 25/42] AP: Avoid setting same MLD and link address

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



For MLD AP, when bssid configuration is specified without mld_addr,
first link address is used as mld address as well.
Though the spec allows it, current implementation and the kernel aren't
happy about it. Better avoid this.

Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@xxxxxxxxx>
---
 hostapd/main.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/hostapd/main.c b/hostapd/main.c
index fcb01f60e1..32083c0840 100644
--- a/hostapd/main.c
+++ b/hostapd/main.c
@@ -241,14 +241,19 @@ static int hostapd_driver_init(struct hostapd_iface *iface)
 		params.global_priv = global.drv_priv[i];
 		break;
 	}
+
 	params.bssid = b;
 #ifdef CONFIG_IEEE80211BE
 	/*
 	 * Use the configured MLD MAC address as the interface hardware address
 	 * if this AP is a part of an AP MLD.
 	 */
-	if (!is_zero_ether_addr(hapd->conf->mld_addr) && hapd->conf->mld_ap)
-		params.bssid = hapd->conf->mld_addr;
+	if (hapd->conf->mld_ap) {
+		if (!is_zero_ether_addr(hapd->conf->mld_addr))
+			params.bssid = hapd->conf->mld_addr;
+		else
+			params.bssid = NULL;
+	}
 #endif /* CONFIG_IEEE80211BE */
 
 	params.ifname = hapd->conf->iface;
-- 
2.38.1


_______________________________________________
Hostap mailing list
Hostap@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/hostap



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux