P2P: Clear send action work without waiting on find/stop/listen
authorAvraham Stern <avraham.stern@intel.com>
Tue, 3 Nov 2015 14:25:01 +0000 (16:25 +0200)
committerJouni Malinen <j@w1.fi>
Sat, 21 Nov 2015 16:53:22 +0000 (18:53 +0200)
commit2c51c0bd8323b8bfa7b5a640488841d2c2c1d2ae
tree7e5a870be7330810cda576806ef2c96b837b6397
parent6bdc43c4db724ee82aa4ecf6d0b7ea853cd6007a
P2P: Clear send action work without waiting on find/stop/listen

When clearing pending TX action to start a new P2P operation like
P2P_FIND or P2P_LISTEN, wpas_p2p_action_tx_clear() was used to clear
the send action work. However, in cases where the action work has wait
time, it is not cleared immediately but only after the wait time ends.
This may cause delay in starting the P2P operation.

Fix that by always clearing the send action work immediately on these
P2P commands that result in immediate P2P state change and practically
stopping a previous operation, if one was pending.

Signed-off-by: Avraham Stern <avraham.stern@intel.com>
wpa_supplicant/p2p_supplicant.c