P2P: Set a timeout for a persistent reinvoke on a P2P Client
Use P2P group formation timeout to wait for the 4-way handshake to complete on a persistent reinvocation on a P2P Client. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
This commit is contained in:
parent
41d5ce9e0b
commit
91364b7f10
1 changed files with 7 additions and 1 deletions
|
@ -57,7 +57,8 @@
|
||||||
#ifndef P2P_MAX_INITIAL_CONN_WAIT
|
#ifndef P2P_MAX_INITIAL_CONN_WAIT
|
||||||
/*
|
/*
|
||||||
* How many seconds to wait for initial 4-way handshake to get completed after
|
* How many seconds to wait for initial 4-way handshake to get completed after
|
||||||
* WPS provisioning step.
|
* WPS provisioning step or after the re-invocation of a persistent group on a
|
||||||
|
* P2P Client.
|
||||||
*/
|
*/
|
||||||
#define P2P_MAX_INITIAL_CONN_WAIT 10
|
#define P2P_MAX_INITIAL_CONN_WAIT 10
|
||||||
#endif /* P2P_MAX_INITIAL_CONN_WAIT */
|
#endif /* P2P_MAX_INITIAL_CONN_WAIT */
|
||||||
|
@ -5206,6 +5207,11 @@ static int wpas_start_p2p_client(struct wpa_supplicant *wpa_s,
|
||||||
wpa_s->p2p_in_invitation = 1;
|
wpa_s->p2p_in_invitation = 1;
|
||||||
wpa_s->p2p_invite_go_freq = freq;
|
wpa_s->p2p_invite_go_freq = freq;
|
||||||
|
|
||||||
|
eloop_cancel_timeout(wpas_p2p_group_formation_timeout, wpa_s->parent,
|
||||||
|
NULL);
|
||||||
|
eloop_register_timeout(P2P_MAX_INITIAL_CONN_WAIT, 0,
|
||||||
|
wpas_p2p_group_formation_timeout,
|
||||||
|
wpa_s->parent, NULL);
|
||||||
wpa_supplicant_select_network(wpa_s, ssid);
|
wpa_supplicant_select_network(wpa_s, ssid);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Reference in a new issue