Patchwork P2P: Fix P2P Group Formation to register and cancel timeouts on parent only.

login
register
mail settings
Submitter nirav shah
Date May 17, 2012, 8:42 p.m.
Message ID <1337287360-15201-1-git-send-email-nirav.j2.shah@intel.com>
Download mbox | patch
Permalink /patch/160014/
State Accepted
Commit ad853202344294ef326918989a6f064743fbd39f
Headers show

Comments

nirav shah - May 17, 2012, 8:42 p.m.
The fix 361cdf34 extends the use of group formation timeout for the
way handshake but the register is done on the group_interface while
the cancel is done on the parent interface. Correcting the register
to set the eloop timeout on parent.

    Signed-hostap: Nirav Shah <nirav.j2.shah@intel.com>
---
 wpa_supplicant/p2p_supplicant.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
Jouni Malinen - June 4, 2012, 7:03 p.m.
On Thu, May 17, 2012 at 01:42:40PM -0700, nirav shah wrote:
> The fix 361cdf34 extends the use of group formation timeout for the
> way handshake but the register is done on the group_interface while
> the cancel is done on the parent interface. Correcting the register
> to set the eloop timeout on parent.

Thanks! Applied.

Patch

diff --git a/wpa_supplicant/p2p_supplicant.c b/wpa_supplicant/p2p_supplicant.c
index 44aadf1..d41a8dc 100644
--- a/wpa_supplicant/p2p_supplicant.c
+++ b/wpa_supplicant/p2p_supplicant.c
@@ -3743,7 +3743,7 @@  void wpas_p2p_wps_success(struct wpa_supplicant *wpa_s, const u8 *peer_addr,
 		 */
 		eloop_register_timeout(P2P_MAX_INITIAL_CONN_WAIT, 0,
 				       wpas_p2p_group_formation_timeout,
-				       wpa_s, NULL);
+				       wpa_s->parent, NULL);
 	}
 	if (wpa_s->global->p2p)
 		p2p_wps_success_cb(wpa_s->global->p2p, peer_addr);