From 5d0d72a3e56bbf509dba89275966eb2dc6f8e70f Mon Sep 17 00:00:00 2001 From: Ben Greear Date: Wed, 5 Mar 2014 16:19:49 -0800 Subject: [PATCH] wpa_supplicant: Put upper bound on initial scan time delay This makes stations associate much faster when using lots of stations. In addition, this avoids delaying the initial scan continuously for dynamic interface removal/addition cases. Signed-hostap: Ben Greear --- wpa_supplicant/wpa_supplicant.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/wpa_supplicant/wpa_supplicant.c b/wpa_supplicant/wpa_supplicant.c index 561099cb9..6a04e5acc 100644 --- a/wpa_supplicant/wpa_supplicant.c +++ b/wpa_supplicant/wpa_supplicant.c @@ -2687,9 +2687,10 @@ int wpa_supplicant_driver_init(struct wpa_supplicant *wpa_s) interface_count = 0; } if (!wpa_s->p2p_mgmt && - wpa_supplicant_delayed_sched_scan(wpa_s, interface_count, + wpa_supplicant_delayed_sched_scan(wpa_s, + interface_count % 3, 100000)) - wpa_supplicant_req_scan(wpa_s, interface_count, + wpa_supplicant_req_scan(wpa_s, interface_count % 3, 100000); interface_count++; } else