xref: /freebsd/contrib/wpa/wpa_supplicant/mesh_mpm.h (revision 5b9c547c072b84410b50897cc53710c75b2f6b74)
1*5b9c547cSRui Paulo /*
2*5b9c547cSRui Paulo  * WPA Supplicant - Basic mesh peer management
3*5b9c547cSRui Paulo  * Copyright (c) 2013-2014, cozybit, Inc.  All rights reserved.
4*5b9c547cSRui Paulo  *
5*5b9c547cSRui Paulo  * This software may be distributed under the terms of the BSD license.
6*5b9c547cSRui Paulo  * See README for more details.
7*5b9c547cSRui Paulo  */
8*5b9c547cSRui Paulo 
9*5b9c547cSRui Paulo #ifndef MESH_MPM_H
10*5b9c547cSRui Paulo #define MESH_MPM_H
11*5b9c547cSRui Paulo 
12*5b9c547cSRui Paulo /* notify MPM of new mesh peer to be inserted in MPM and driver */
13*5b9c547cSRui Paulo void wpa_mesh_new_mesh_peer(struct wpa_supplicant *wpa_s, const u8 *addr,
14*5b9c547cSRui Paulo 			    struct ieee802_11_elems *elems);
15*5b9c547cSRui Paulo void mesh_mpm_deinit(struct wpa_supplicant *wpa_s, struct hostapd_iface *ifmsh);
16*5b9c547cSRui Paulo void mesh_mpm_auth_peer(struct wpa_supplicant *wpa_s, const u8 *addr);
17*5b9c547cSRui Paulo void mesh_mpm_free_sta(struct sta_info *sta);
18*5b9c547cSRui Paulo void wpa_mesh_set_plink_state(struct wpa_supplicant *wpa_s,
19*5b9c547cSRui Paulo 			      struct sta_info *sta,
20*5b9c547cSRui Paulo 			      enum mesh_plink_state state);
21*5b9c547cSRui Paulo 
22*5b9c547cSRui Paulo #ifdef CONFIG_MESH
23*5b9c547cSRui Paulo 
24*5b9c547cSRui Paulo void mesh_mpm_action_rx(struct wpa_supplicant *wpa_s,
25*5b9c547cSRui Paulo 			const struct ieee80211_mgmt *mgmt, size_t len);
26*5b9c547cSRui Paulo void mesh_mpm_mgmt_rx(struct wpa_supplicant *wpa_s, struct rx_mgmt *rx_mgmt);
27*5b9c547cSRui Paulo 
28*5b9c547cSRui Paulo #else /* CONFIG_MESH */
29*5b9c547cSRui Paulo 
30*5b9c547cSRui Paulo static inline void mesh_mpm_action_rx(struct wpa_supplicant *wpa_s,
31*5b9c547cSRui Paulo 				      const struct ieee80211_mgmt *mgmt,
32*5b9c547cSRui Paulo 				      size_t len)
33*5b9c547cSRui Paulo {
34*5b9c547cSRui Paulo }
35*5b9c547cSRui Paulo 
36*5b9c547cSRui Paulo static inline void mesh_mpm_mgmt_rx(struct wpa_supplicant *wpa_s,
37*5b9c547cSRui Paulo 				    struct rx_mgmt *rx_mgmt)
38*5b9c547cSRui Paulo {
39*5b9c547cSRui Paulo }
40*5b9c547cSRui Paulo 
41*5b9c547cSRui Paulo #endif /* CONFIG_MESH */
42*5b9c547cSRui Paulo 
43*5b9c547cSRui Paulo #endif /* MESH_MPM_H */
44