nl80211: New notification to discover mesh peer candidates.
Notify userspace when a beacon/presp is received from a suitable mesh peer candidate for whom no sta information exists. Userspace can then decide to create a sta info for the candidate. If userspace is not ready to authenticate the peer right away, it can create the sta info with the authenticated flag unset and set it later. Signed-off-by: Javier Cardona <javier@cozybit.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:

committed by
John W. Linville

parent
96b78dff03
commit
c93b5e717e
@@ -1,5 +1,6 @@
|
||||
#include <linux/ieee80211.h>
|
||||
#include <net/cfg80211.h>
|
||||
#include "nl80211.h"
|
||||
#include "core.h"
|
||||
|
||||
/* Default values, timeouts in ms */
|
||||
@@ -110,6 +111,19 @@ int cfg80211_join_mesh(struct cfg80211_registered_device *rdev,
|
||||
return err;
|
||||
}
|
||||
|
||||
void cfg80211_notify_new_peer_candidate(struct net_device *dev,
|
||||
const u8 *macaddr, const u8* ie, u8 ie_len, gfp_t gfp)
|
||||
{
|
||||
struct wireless_dev *wdev = dev->ieee80211_ptr;
|
||||
|
||||
if (WARN_ON(wdev->iftype != NL80211_IFTYPE_MESH_POINT))
|
||||
return;
|
||||
|
||||
nl80211_send_new_peer_candidate(wiphy_to_dev(wdev->wiphy), dev,
|
||||
macaddr, ie, ie_len, gfp);
|
||||
}
|
||||
EXPORT_SYMBOL(cfg80211_notify_new_peer_candidate);
|
||||
|
||||
static int __cfg80211_leave_mesh(struct cfg80211_registered_device *rdev,
|
||||
struct net_device *dev)
|
||||
{
|
||||
|
Reference in New Issue
Block a user