From 9c8d550b77ba9aeed99a75f43645182239b27d68 Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Wed, 1 Jan 2020 17:09:18 +0200 Subject: [PATCH] Allow roam to lower signal level if throughput benefit is significant Do not prevent roam to a different BSS based only on the signal level with the current BSS being higher than with the selected BSS. If the estimated throughput is significantly higher (> 20%), allow roaming if the following conditions are met. Signed-off-by: Jouni Malinen --- wpa_supplicant/events.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wpa_supplicant/events.c b/wpa_supplicant/events.c index f7997d5fc..6478c3443 100644 --- a/wpa_supplicant/events.c +++ b/wpa_supplicant/events.c @@ -1796,7 +1796,8 @@ static int wpa_supplicant_need_to_roam(struct wpa_supplicant *wpa_s, to_5ghz = selected->freq > 4000 && current_bss->freq < 4000; - if (cur_level < 0 && cur_level > selected->level + to_5ghz * 2) { + if (cur_level < 0 && cur_level > selected->level + to_5ghz * 2 && + selected->est_throughput < cur_est * 1.2) { wpa_dbg(wpa_s, MSG_DEBUG, "Skip roam - Current BSS has better " "signal level"); return 0;