aboutsummaryrefslogtreecommitdiffstats
path: root/src/p2p/p2p_i.h
diff options
context:
space:
mode:
authorJouni Malinen <jouni@qca.qualcomm.com>2013-02-12 17:25:18 (GMT)
committerJouni Malinen <j@w1.fi>2013-02-12 17:25:18 (GMT)
commita5b5e830a054ecf0d4711f8e8f0be105bc18a437 (patch)
tree82925c78c7070d1790798722512aa9449bde1bb6 /src/p2p/p2p_i.h
parentc5f10e804afff4a73b3f1e3267a5061e78c20a17 (diff)
downloadhostap-a5b5e830a054ecf0d4711f8e8f0be105bc18a437.zip
hostap-a5b5e830a054ecf0d4711f8e8f0be105bc18a437.tar.gz
hostap-a5b5e830a054ecf0d4711f8e8f0be105bc18a437.tar.bz2
P2P: Do not use old scan result data for peer discovery
The driver may have cached (e.g., in cfg80211 BSS table) the scan results for relatively long time. To avoid reporting stale information, update P2P peers only based on results that have based on frames received after the last p2p_find operation was started. This helps especially in detecting when a previously operating GO stops the group since the BSS entry for that could live for 30 seconds in the cfg80211 cache. Running p2p_flush followed by p2p_find will now allow wpa_supplicant to not add a P2P peer entry for that GO if the group had been terminated just before that p2p_flush command. Previously, that GO could have been indicated as a newly found device for up to 30 seconds after it had stopped the group. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'src/p2p/p2p_i.h')
-rw-r--r--src/p2p/p2p_i.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/p2p/p2p_i.h b/src/p2p/p2p_i.h
index c4838d2..005f73b 100644
--- a/src/p2p/p2p_i.h
+++ b/src/p2p/p2p_i.h
@@ -390,6 +390,8 @@ struct p2p_data {
u8 *find_dev_id;
u8 find_dev_id_buf[ETH_ALEN];
+ struct os_time find_start; /* time of last p2p_find start */
+
struct p2p_group **groups;
size_t num_groups;