blob: 9519c2f3e3d78f0095c402b4dad3beaba6415e79 [file] [log] [blame]
developer05f3b2b2024-08-19 19:17:34 +08001From 1d64b54fc9ea3e53a6369e609a9b4e83e800a1e4 Mon Sep 17 00:00:00 2001
2From: Michael-CY Lee <michael-cy.lee@mediatek.com>
3Date: Fri, 26 Apr 2024 08:36:57 +0800
4Subject: [PATCH 081/126] mtk: hostapd: do not roam within the same MLD
5
6If STA scaned and selected a different links from the same MLD AP, the
7check by wpa_s would make it to roam within ESS, which is unnecessary
8for a non-AP MLD.
9
10Signed-off-by: Michael-CY Lee <michael-cy.lee@mediatek.com>
11---
12 wpa_supplicant/events.c | 3 +++
13 1 file changed, 3 insertions(+)
14
15diff --git a/wpa_supplicant/events.c b/wpa_supplicant/events.c
16index 68f4d2dbe..83b1dcc21 100644
17--- a/wpa_supplicant/events.c
18+++ b/wpa_supplicant/events.c
19@@ -2395,6 +2395,9 @@ static int wpa_supplicant_need_to_roam(struct wpa_supplicant *wpa_s,
20 if (current_bss == selected)
21 return 0;
22
23+ if (wpa_s->valid_links && ether_addr_equal(selected->mld_addr, wpa_s->bssid))
24+ return 0; /* same AP MLD but different links */
25+
26 if (selected->last_update_idx > current_bss->last_update_idx)
27 return 1; /* current BSS not seen in the last scan */
28
29--
302.18.0
31