[PATCH v2 10/20] WNM: Don't scan frequencies of neighbors that should be ignored
benjamin at sipsolutions.net
benjamin at sipsolutions.net
Tue Feb 20 05:18:17 PST 2024
From: Benjamin Berg <benjamin.berg at intel.com>
It does not make sense to scan for neighbors that we are not supposed to
use anyway. As such, skip them.
Signed-off-by: Benjamin Berg <benjamin.berg at intel.com>
---
wpa_supplicant/wnm_sta.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/wpa_supplicant/wnm_sta.c b/wpa_supplicant/wnm_sta.c
index 6f5f63a8d..71608a394 100644
--- a/wpa_supplicant/wnm_sta.c
+++ b/wpa_supplicant/wnm_sta.c
@@ -1356,6 +1356,10 @@ static void wnm_set_scan_freqs(struct wpa_supplicant *wpa_s)
struct neighbor_report *nei;
nei = &wpa_s->wnm_neighbor_report_elements[i];
+
+ if (nei->preference_present && nei->preference == 0)
+ continue;
+
if (nei->freq <= 0) {
wpa_printf(MSG_DEBUG,
"WNM: Unknown neighbor operating frequency for "
--
2.43.2
More information about the Hostap
mailing list