P2P: Pass the known BSSID to the driver to optimize scan time
After GO negotiation is completed, the P2P Client needs to scan the GO before connecting. Only SSID was specified for this and the driver still might need to scan all channels which wastes time. wpa_supplicant can pass the known BSSID in the scan request in additional P2P cases and this allows the driver sto stop the scan once the specific BSSID is found. This helps reduce some time for P2P connection. Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
This commit is contained in:
parent
bffd2b3994
commit
2bd8887e9f
1 changed files with 10 additions and 0 deletions
|
@ -1184,6 +1184,10 @@ static void wpa_supplicant_scan(void *eloop_ctx, void *timeout_ctx)
|
|||
params.ssids[0].ssid = wpa_s->go_params->ssid;
|
||||
params.ssids[0].ssid_len = wpa_s->go_params->ssid_len;
|
||||
params.num_ssids = 1;
|
||||
params.bssid = wpa_s->go_params->peer_interface_addr;
|
||||
wpa_printf(MSG_DEBUG, "P2P: Use specific BSSID " MACSTR
|
||||
" (peer interface address) for scan",
|
||||
MAC2STR(params.bssid));
|
||||
goto ssid_list_set;
|
||||
}
|
||||
|
||||
|
@ -1194,6 +1198,12 @@ static void wpa_supplicant_scan(void *eloop_ctx, void *timeout_ctx)
|
|||
params.ssids[0].ssid_len =
|
||||
wpa_s->current_ssid->ssid_len;
|
||||
params.num_ssids = 1;
|
||||
if (wpa_s->current_ssid->bssid_set) {
|
||||
params.bssid = wpa_s->current_ssid->bssid;
|
||||
wpa_printf(MSG_DEBUG, "P2P: Use specific BSSID "
|
||||
MACSTR " for scan",
|
||||
MAC2STR(params.bssid));
|
||||
}
|
||||
} else {
|
||||
wpa_printf(MSG_DEBUG, "P2P: No specific SSID known for scan during invitation");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue