P2P: Add p2p_get_peer_found to get peer info

This will only retrieve information about peers that have been fully
discovered, not peers that are only half-discovered based on their Probe
Request frames.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
Johannes Berg 2011-02-24 22:05:22 +02:00 committed by Jouni Malinen
parent 8fd7dc1b1c
commit c165d81eea
2 changed files with 51 additions and 0 deletions

View file

@ -1372,4 +1372,14 @@ unsigned int p2p_get_group_num_members(struct p2p_group *group);
*/
const u8 * p2p_iterate_group_members(struct p2p_group *group, void **next);
/**
* p2p_get_peer_found - Get P2P peer info structure of a found peer
* @p2p: P2P module context from p2p_init()
* @addr: P2P Device Address of the peer or %NULL to indicate the first peer
* @next: Whether to select the peer entry following the one indicated by addr
* Returns: The first P2P peer info available or %NULL if no such peer exists
*/
const struct p2p_peer_info *
p2p_get_peer_found(struct p2p_data *p2p, const u8 *addr, int next);
#endif /* P2P_H */