FreeBSD kernel WLAN code
ieee80211_node.c File Reference
#include <sys/cdefs.h>
#include "opt_wlan.h"
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/mbuf.h>
#include <sys/malloc.h>
#include <sys/kernel.h>
#include <sys/socket.h>
#include <net/if.h>
#include <net/if_var.h>
#include <net/if_media.h>
#include <net/ethernet.h>
#include <net80211/ieee80211_var.h>
#include <net80211/ieee80211_input.h>
#include <net80211/ieee80211_wds.h>
#include <net80211/ieee80211_mesh.h>
#include <net80211/ieee80211_ratectl.h>
#include <net80211/ieee80211_vht.h>
#include <net/bpf.h>
Include dependency graph for ieee80211_node.c:

Go to the source code of this file.

Data Structures

struct  rssiinfo
 

Macros

#define IEEE80211_AID_SET(_vap, b)
 
#define IEEE80211_AID_CLR(_vap, b)
 
#define IEEE80211_AID_ISSET(_vap, b)    ((_vap)->iv_aid_bitmap[IEEE80211_AID(b) / 32] & (1 << (IEEE80211_AID(b) % 32)))
 
#define IS_PROBEREQ(wh)
 
#define IS_BCAST_PROBEREQ(wh)
 
#define NZ(x)   ((x) == 0 ? 1 : (x))
 

Functions

 __FBSDID ("$FreeBSD$")
 
 CTASSERT ((IEEE80211_NODE_HASHSIZE &(IEEE80211_NODE_HASHSIZE-1))==0)
 
static int ieee80211_sta_join1 (struct ieee80211_node *)
 
static struct ieee80211_nodenode_alloc (struct ieee80211vap *, const uint8_t[IEEE80211_ADDR_LEN])
 
static int node_init (struct ieee80211_node *)
 
static void node_cleanup (struct ieee80211_node *)
 
static void node_free (struct ieee80211_node *)
 
static void node_age (struct ieee80211_node *)
 
static int8_t node_getrssi (const struct ieee80211_node *)
 
static void node_getsignal (const struct ieee80211_node *, int8_t *, int8_t *)
 
static void node_getmimoinfo (const struct ieee80211_node *, struct ieee80211_mimo_info *)
 
static void _ieee80211_free_node (struct ieee80211_node *)
 
static void node_reclaim (struct ieee80211_node_table *nt, struct ieee80211_node *ni)
 
static void ieee80211_node_table_init (struct ieee80211com *ic, struct ieee80211_node_table *nt, const char *name, int inact, int keymaxix)
 
static void ieee80211_node_table_reset (struct ieee80211_node_table *, struct ieee80211vap *)
 
static void ieee80211_node_table_cleanup (struct ieee80211_node_table *nt)
 
static void ieee80211_vap_erp_timeout (struct ieee80211vap *)
 
 MALLOC_DEFINE (M_80211_NODE, "80211node", "802.11 node state")
 
 MALLOC_DEFINE (M_80211_NODE_IE, "80211nodeie", "802.11 node ie")
 
void ieee80211_node_attach (struct ieee80211com *ic)
 
void ieee80211_node_detach (struct ieee80211com *ic)
 
void ieee80211_node_vattach (struct ieee80211vap *vap)
 
void ieee80211_node_latevattach (struct ieee80211vap *vap)
 
void ieee80211_node_vdetach (struct ieee80211vap *vap)
 
void ieee80211_node_authorize (struct ieee80211_node *ni)
 
void ieee80211_node_unauthorize (struct ieee80211_node *ni)
 
void ieee80211_node_setuptxparms (struct ieee80211_node *ni)
 
void ieee80211_node_set_chan (struct ieee80211_node *ni, struct ieee80211_channel *chan)
 
static __inline void copy_bss (struct ieee80211_node *nbss, const struct ieee80211_node *obss)
 
void ieee80211_create_ibss (struct ieee80211vap *vap, struct ieee80211_channel *chan)
 
void ieee80211_reset_bss (struct ieee80211vap *vap)
 
static int match_ssid (const struct ieee80211_node *ni, int nssid, const struct ieee80211_scan_ssid ssids[])
 
static int check_bss (struct ieee80211vap *vap, struct ieee80211_node *ni)
 
int ieee80211_ibss_merge_check (struct ieee80211_node *ni)
 
int ieee80211_ibss_node_check_new (struct ieee80211_node *ni, const struct ieee80211_scanparams *scan)
 
int ieee80211_ibss_merge (struct ieee80211_node *ni)
 
static int gethtadjustflags (struct ieee80211com *ic)
 
static int getvhtadjustflags (struct ieee80211com *ic)
 
void ieee80211_sync_curchan (struct ieee80211com *ic)
 
void ieee80211_setupcurchan (struct ieee80211com *ic, struct ieee80211_channel *c)
 
void ieee80211_setcurchan (struct ieee80211com *ic, struct ieee80211_channel *c)
 
void ieee80211_update_chw (struct ieee80211com *ic)
 
int ieee80211_sta_join (struct ieee80211vap *vap, struct ieee80211_channel *chan, const struct ieee80211_scan_entry *se)
 
void ieee80211_sta_leave (struct ieee80211_node *ni)
 
void ieee80211_node_deauth (struct ieee80211_node *ni, int reason)
 
int ieee80211_ies_init (struct ieee80211_ies *ies, const uint8_t *data, int len)
 
void ieee80211_ies_cleanup (struct ieee80211_ies *ies)
 
void ieee80211_ies_expand (struct ieee80211_ies *ies)
 
static void ieee80211_add_node_nt (struct ieee80211_node_table *nt, struct ieee80211_node *ni)
 
static void ieee80211_del_node_nt (struct ieee80211_node_table *nt, struct ieee80211_node *ni)
 
struct ieee80211_nodeieee80211_alloc_node (struct ieee80211_node_table *nt, struct ieee80211vap *vap, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
struct ieee80211_nodeieee80211_tmp_node (struct ieee80211vap *vap, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
struct ieee80211_nodeieee80211_dup_bss (struct ieee80211vap *vap, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
struct ieee80211_nodeieee80211_node_create_wds (struct ieee80211vap *vap, const uint8_t bssid[IEEE80211_ADDR_LEN], struct ieee80211_channel *chan)
 
struct ieee80211_nodeieee80211_find_node_locked (struct ieee80211_node_table *nt, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
struct ieee80211_nodeieee80211_find_node (struct ieee80211_node_table *nt, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
struct ieee80211_nodeieee80211_find_vap_node_locked (struct ieee80211_node_table *nt, const struct ieee80211vap *vap, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
struct ieee80211_nodeieee80211_find_vap_node (struct ieee80211_node_table *nt, const struct ieee80211vap *vap, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
struct ieee80211_nodeieee80211_fakeup_adhoc_node (struct ieee80211vap *vap, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
void ieee80211_init_neighbor (struct ieee80211_node *ni, const struct ieee80211_frame *wh, const struct ieee80211_scanparams *sp)
 
struct ieee80211_nodeieee80211_add_neighbor (struct ieee80211vap *vap, const struct ieee80211_frame *wh, const struct ieee80211_scanparams *sp)
 
static __inline struct ieee80211_node_find_rxnode (struct ieee80211_node_table *nt, const struct ieee80211_frame_min *wh)
 
struct ieee80211_nodeieee80211_find_rxnode (struct ieee80211com *ic, const struct ieee80211_frame_min *wh)
 
struct ieee80211_nodeieee80211_find_rxnode_withkey (struct ieee80211com *ic, const struct ieee80211_frame_min *wh, ieee80211_keyix keyix)
 
struct ieee80211_nodeieee80211_find_txnode (struct ieee80211vap *vap, const uint8_t macaddr[IEEE80211_ADDR_LEN])
 
static int node_clear_keyixmap (struct ieee80211_node_table *nt, struct ieee80211_node *ni)
 
void ieee80211_free_node (struct ieee80211_node *ni)
 
int ieee80211_node_delucastkey (struct ieee80211_node *ni)
 
static void timeout_stations (void *arg __unused, struct ieee80211_node *ni)
 
static void ieee80211_timeout_stations (struct ieee80211com *ic)
 
void ieee80211_drain (struct ieee80211com *ic)
 
static void ieee80211_vap_timeout (struct ieee80211vap *vap)
 
void ieee80211_node_timeout (void *arg)
 
int ieee80211_iterate_nodes_vap (struct ieee80211_node_table *nt, struct ieee80211vap *vap, ieee80211_iter_func *f, void *arg)
 
void ieee80211_iterate_nodes (struct ieee80211_node_table *nt, ieee80211_iter_func *f, void *arg)
 
void ieee80211_dump_node (struct ieee80211_node_table *nt __unused, struct ieee80211_node *ni)
 
void ieee80211_dump_nodes (struct ieee80211_node_table *nt)
 
void ieee80211_notify_erp_locked (struct ieee80211com *ic)
 
static void ieee80211_node_join_11g (struct ieee80211_node *ni)
 
void ieee80211_node_join (struct ieee80211_node *ni, int resp)
 
static void disable_protection (struct ieee80211vap *vap)
 
static void ieee80211_node_leave_11g (struct ieee80211_node *ni)
 
void ieee80211_node_leave (struct ieee80211_node *ni)
 
static void get_hostap_rssi (void *arg, struct ieee80211_node *ni)
 
static void get_adhoc_rssi (void *arg, struct ieee80211_node *ni)
 
int8_t ieee80211_getrssi (struct ieee80211vap *vap)
 
void ieee80211_getsignal (struct ieee80211vap *vap, int8_t *rssi, int8_t *noise)
 

Macro Definition Documentation

◆ IEEE80211_AID_CLR

#define IEEE80211_AID_CLR (   _vap,
 
)
Value:
((_vap)->iv_aid_bitmap[IEEE80211_AID(b) / 32] &= \
~(1 << (IEEE80211_AID(b) % 32)))
#define IEEE80211_AID(b)
Definition: ieee80211.h:1379

Definition at line 73 of file ieee80211_node.c.

◆ IEEE80211_AID_ISSET

#define IEEE80211_AID_ISSET (   _vap,
 
)     ((_vap)->iv_aid_bitmap[IEEE80211_AID(b) / 32] & (1 << (IEEE80211_AID(b) % 32)))

Definition at line 76 of file ieee80211_node.c.

◆ IEEE80211_AID_SET

#define IEEE80211_AID_SET (   _vap,
 
)
Value:
((_vap)->iv_aid_bitmap[IEEE80211_AID(b) / 32] |= \
(1 << (IEEE80211_AID(b) % 32)))

Definition at line 70 of file ieee80211_node.c.

◆ IS_BCAST_PROBEREQ

#define IS_BCAST_PROBEREQ (   wh)
Value:
((const struct ieee80211_frame *)(wh))->i_addr3))
#define IEEE80211_IS_MULTICAST(_a)
Definition: ieee80211.h:39
#define IS_PROBEREQ(wh)

Definition at line 1922 of file ieee80211_node.c.

◆ IS_PROBEREQ

#define IS_PROBEREQ (   wh)
Value:
#define IEEE80211_FC0_TYPE_MASK
Definition: ieee80211.h:118
#define IEEE80211_FC0_SUBTYPE_PROBE_REQ
Definition: ieee80211.h:131
#define IEEE80211_FC0_TYPE_MGT
Definition: ieee80211.h:120
#define IEEE80211_FC0_SUBTYPE_MASK
Definition: ieee80211.h:124

Definition at line 1919 of file ieee80211_node.c.

◆ NZ

#define NZ (   x)    ((x) == 0 ? 1 : (x))

Function Documentation

◆ __FBSDID()

__FBSDID ( "$FreeBSD$"  )

◆ _find_rxnode()

static __inline struct ieee80211_node * _find_rxnode ( struct ieee80211_node_table nt,
const struct ieee80211_frame_min wh 
)
static

Definition at line 1927 of file ieee80211_node.c.

References ieee80211_frame_min::i_addr2, ieee80211_find_node_locked(), and IS_BCAST_PROBEREQ.

Referenced by ieee80211_find_rxnode(), and ieee80211_find_rxnode_withkey().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ _ieee80211_free_node()

◆ check_bss()

◆ copy_bss()

static __inline void copy_bss ( struct ieee80211_node nbss,
const struct ieee80211_node obss 
)
static

◆ CTASSERT()

◆ disable_protection()

static void disable_protection ( struct ieee80211vap vap)
static

◆ get_adhoc_rssi()

static void get_adhoc_rssi ( void *  arg,
struct ieee80211_node ni 
)
static

◆ get_hostap_rssi()

static void get_hostap_rssi ( void *  arg,
struct ieee80211_node ni 
)
static

Definition at line 3011 of file ieee80211_node.c.

References ieee80211com::ic_node_getrssi, ieee80211vap::iv_ic, ieee80211_node::ni_associd, ieee80211_node::ni_vap, rssiinfo::rssi_samples, and rssiinfo::rssi_total.

Referenced by ieee80211_getrssi().

Here is the caller graph for this function:

◆ gethtadjustflags()

static int gethtadjustflags ( struct ieee80211com ic)
static

◆ getvhtadjustflags()

static int getvhtadjustflags ( struct ieee80211com ic)
static

◆ ieee80211_add_neighbor()

◆ ieee80211_add_node_nt()

static void ieee80211_add_node_nt ( struct ieee80211_node_table nt,
struct ieee80211_node ni 
)
static

◆ ieee80211_alloc_node()

struct ieee80211_node * ieee80211_alloc_node ( struct ieee80211_node_table nt,
struct ieee80211vap vap,
const uint8_t  macaddr[IEEE80211_ADDR_LEN] 
)

◆ ieee80211_create_ibss()

void ieee80211_create_ibss ( struct ieee80211vap vap,
struct ieee80211_channel chan 
)

Definition at line 332 of file ieee80211_node.c.

References copy_bss(), ieee80211com::ic_bintval, ieee80211com::ic_bsschan, ieee80211com::ic_curmode, ieee80211_channel::ic_flags, ieee80211_channel::ic_freq, ieee80211com::ic_phytype, ieee80211com::ic_sta, ieee80211_addbasicrates(), IEEE80211_ADDR_COPY, IEEE80211_ADDR_LEN, ieee80211_alloc_node(), IEEE80211_C_TDMA, IEEE80211_CAPINFO_IBSS, IEEE80211_CAPINFO_PRIVACY, ieee80211_chan2ieee(), ieee80211_chan2mode(), IEEE80211_CHAN_ANYC, ieee80211_channel_type_char(), ieee80211_dfs_cac_clear(), IEEE80211_DPRINTF, IEEE80211_F_DESBSSID, IEEE80211_F_PRIVACY, IEEE80211_F_PUREG, ieee80211_ht_node_init(), IEEE80211_IS_CHAN_ANYG, IEEE80211_IS_CHAN_B, IEEE80211_IS_CHAN_CACDONE, IEEE80211_IS_CHAN_FULL, IEEE80211_IS_CHAN_HT, IEEE80211_IS_CHAN_VHT, IEEE80211_M_AHDEMO, IEEE80211_M_IBSS, IEEE80211_M_MBSS, IEEE80211_MODE_11A, IEEE80211_MODE_11B, IEEE80211_MODE_11G, IEEE80211_MSG_SCAN, ieee80211_node_set_chan(), ieee80211_opmode_name, ieee80211_ref_node(), ieee80211_setbasicrates(), ieee80211_sta_join1(), IEEE80211_T_FH, ieee80211_vht_node_init(), ieee80211vap::iv_bss, ieee80211vap::iv_caps, ieee80211vap::iv_des_bssid, ieee80211vap::iv_des_ssid, ieee80211vap::iv_flags, ieee80211vap::iv_ic, ieee80211vap::iv_mesh, ieee80211vap::iv_myaddr, ieee80211vap::iv_opmode, ieee80211_scan_ssid::len, ieee80211_mesh_state::ms_id, ieee80211_mesh_state::ms_idlen, net80211_get_random_bytes(), ieee80211_node::ni_bssid, ieee80211_node::ni_capinfo, ieee80211_node::ni_chan, ieee80211_node::ni_essid, ieee80211_node::ni_esslen, ieee80211_node::ni_fhdwell, ieee80211_node::ni_fhindex, ieee80211_node::ni_intval, ieee80211_node::ni_meshid, ieee80211_node::ni_meshidlen, ieee80211_node::ni_rates, and ieee80211_scan_ssid::ssid.

Referenced by adhoc_newstate(), adhoc_pick_bss(), ap_end(), hostap_newstate(), mesh_newstate(), and monitor_newstate().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_del_node_nt()

static void ieee80211_del_node_nt ( struct ieee80211_node_table nt,
struct ieee80211_node ni 
)
static

Definition at line 1373 of file ieee80211_node.c.

References IEEE80211_NODE_LOCK_ASSERT, ieee80211_node::ni_table, and ieee80211_node_table::nt_count.

Referenced by _ieee80211_free_node(), and node_reclaim().

Here is the caller graph for this function:

◆ ieee80211_drain()

◆ ieee80211_dump_node()

◆ ieee80211_dump_nodes()

void ieee80211_dump_nodes ( struct ieee80211_node_table nt)

Definition at line 2657 of file ieee80211_node.c.

References ieee80211_dump_node(), and ieee80211_iterate_nodes().

Here is the call graph for this function:

◆ ieee80211_dup_bss()

struct ieee80211_node * ieee80211_dup_bss ( struct ieee80211vap vap,
const uint8_t  macaddr[IEEE80211_ADDR_LEN] 
)

◆ ieee80211_fakeup_adhoc_node()

◆ ieee80211_find_node()

struct ieee80211_node * ieee80211_find_node ( struct ieee80211_node_table nt,
const uint8_t  macaddr[IEEE80211_ADDR_LEN] 
)

Definition at line 1616 of file ieee80211_node.c.

References ieee80211_find_node_locked(), IEEE80211_NODE_LOCK, and IEEE80211_NODE_UNLOCK.

Here is the call graph for this function:

◆ ieee80211_find_node_locked()

struct ieee80211_node * ieee80211_find_node_locked ( struct ieee80211_node_table nt,
const uint8_t  macaddr[IEEE80211_ADDR_LEN] 
)

◆ ieee80211_find_rxnode()

struct ieee80211_node * ieee80211_find_rxnode ( struct ieee80211com ic,
const struct ieee80211_frame_min wh 
)

Definition at line 1945 of file ieee80211_node.c.

References _find_rxnode(), ieee80211com::ic_sta, IEEE80211_NODE_LOCK, and IEEE80211_NODE_UNLOCK.

Here is the call graph for this function:

◆ ieee80211_find_rxnode_withkey()

◆ ieee80211_find_txnode()

◆ ieee80211_find_vap_node()

◆ ieee80211_find_vap_node_locked()

struct ieee80211_node * ieee80211_find_vap_node_locked ( struct ieee80211_node_table nt,
const struct ieee80211vap vap,
const uint8_t  macaddr[IEEE80211_ADDR_LEN] 
)

◆ ieee80211_free_node()

void ieee80211_free_node ( struct ieee80211_node ni)

Definition at line 2130 of file ieee80211_node.c.

References _ieee80211_free_node(), IEEE80211_DPRINTF, IEEE80211_MSG_NODE, ieee80211_node_dectestref(), IEEE80211_NODE_LOCK, ieee80211_node_refcnt, IEEE80211_NODE_UNLOCK, ieee80211_node::ni_macaddr, ieee80211_node::ni_table, ieee80211_node::ni_vap, and node_clear_keyixmap().

Referenced by ageq_mfree(), getstainfo_common(), hostap_deliver_data(), ht_send_action_ba_addba(), ht_send_action_ba_delba(), ht_send_action_ht_txchwidth(), hwmp_send_action(), ieee80211_create_wds(), ieee80211_drain_ifq(), ieee80211_dwds_mcast(), ieee80211_flush_ifq(), ieee80211_ht_update_beacon(), ieee80211_input_mimo_all(), ieee80211_ioctl_delkey(), ieee80211_ioctl_getkey(), ieee80211_ioctl_getstastats(), ieee80211_ioctl_getstatxpow(), ieee80211_ioctl_getstavlan(), ieee80211_ioctl_getwpaie(), ieee80211_ioctl_setkey(), ieee80211_ioctl_setstastats(), ieee80211_ioctl_setstatxpow(), ieee80211_ioctl_setstavlan(), ieee80211_iterate_nodes_vap(), ieee80211_mgmt_output(), ieee80211_node_deauth(), ieee80211_node_delucastkey(), ieee80211_node_leave(), ieee80211_node_vdetach(), ieee80211_output(), ieee80211_parent_xmitpkt(), ieee80211_raw_output(), ieee80211_reset_bss(), ieee80211_send_bar(), ieee80211_send_error(), ieee80211_send_mgmt(), ieee80211_send_nulldata(), ieee80211_send_probereq(), ieee80211_send_proberesp(), ieee80211_start_pkt(), ieee80211_tx_complete(), ieee80211_vap_pkt_send_dest(), mesh_send_action(), mesh_send_action_meshgate(), mesh_send_action_meshlmetric(), mesh_send_action_meshpeering_close(), mesh_send_action_meshpeering_confirm(), mesh_send_action_meshpeering_open(), psq_mfree(), setmlme_common(), and setmlme_dropsta().

Here is the call graph for this function:

◆ ieee80211_getrssi()

◆ ieee80211_getsignal()

void ieee80211_getsignal ( struct ieee80211vap vap,
int8_t *  rssi,
int8_t *  noise 
)

Definition at line 3102 of file ieee80211_node.c.

References ieee80211com::ic_node_getsignal, ieee80211_getrssi(), IEEE80211_M_STA, ieee80211vap::iv_bss, ieee80211vap::iv_ic, and ieee80211vap::iv_opmode.

Here is the call graph for this function:

◆ ieee80211_ibss_merge()

◆ ieee80211_ibss_merge_check()

int ieee80211_ibss_merge_check ( struct ieee80211_node ni)

Definition at line 579 of file ieee80211_node.c.

References check_bss(), IEEE80211_ADDR_EQ, IEEE80211_DPRINTF, IEEE80211_MSG_ASSOC, ieee80211_stats::is_ibss_capmismatch, ieee80211vap::iv_bss, ieee80211vap::iv_stats, ieee80211_node::ni_bssid, and ieee80211_node::ni_vap.

Referenced by ieee80211_ibss_merge().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_ibss_node_check_new()

int ieee80211_ibss_node_check_new ( struct ieee80211_node ni,
const struct ieee80211_scanparams scan 
)

◆ ieee80211_ies_cleanup()

void ieee80211_ies_cleanup ( struct ieee80211_ies ies)

Definition at line 1120 of file ieee80211_node.c.

References ieee80211_ies::data, and IEEE80211_FREE.

Referenced by adhoc_age(), node_free(), and sta_flush_table().

Here is the caller graph for this function:

◆ ieee80211_ies_expand()

◆ ieee80211_ies_init()

int ieee80211_ies_init ( struct ieee80211_ies ies,
const uint8_t *  data,
int  len 
)

◆ ieee80211_init_neighbor()

void ieee80211_init_neighbor ( struct ieee80211_node ni,
const struct ieee80211_frame wh,
const struct ieee80211_scanparams sp 
)

Definition at line 1768 of file ieee80211_node.c.

References ieee80211_ies::ath_ie, ieee80211_scanparams::bintval, ieee80211_scanparams::capinfo, ieee80211_node::data, ieee80211_scanparams::erp, ieee80211_scanparams::fhdwell, ieee80211_scanparams::fhindex, ieee80211_ies::htcap_ie, ieee80211_ies::htinfo_ie, ieee80211_frame::i_addr3, ieee80211com::ic_curchan, ieee80211com::ic_newassoc, IEEE80211_ADDR_COPY, IEEE80211_DPRINTF, IEEE80211_F_DOBRS, IEEE80211_F_DODEL, IEEE80211_F_DOFRATE, IEEE80211_F_DONEGO, IEEE80211_F_DOSORT, IEEE80211_F_JOIN, IEEE80211_FHT_HT, IEEE80211_FVHT_VHT, ieee80211_ht_node_init(), ieee80211_ht_updateparams(), ieee80211_ht_updateparams_final(), ieee80211_ies_expand(), ieee80211_ies_init(), IEEE80211_IS_CHAN_2GHZ, IEEE80211_M_MBSS, ieee80211_mesh_init_neighbor(), IEEE80211_MSG_ASSOC, IEEE80211_NODE_QOS, ieee80211_node_setuptxparms(), ieee80211_parse_ath(), ieee80211_parse_htcap(), ieee80211_parse_htinfo(), ieee80211_parse_vhtcap(), ieee80211_parse_vhtopmode(), ieee80211_ratectl_node_init(), ieee80211_setup_basic_htrates(), ieee80211_setup_htrates(), ieee80211_setup_rates(), ieee80211_setup_vht_rates(), ieee80211_vht_node_init(), ieee80211_vht_updateparams(), ieee80211_scanparams::ies, ieee80211_scanparams::ies_len, ieee80211vap::iv_flags_ht, ieee80211vap::iv_flags_vht, ieee80211vap::iv_opmode, ieee80211_node::ni_bssid, ieee80211_node::ni_capinfo, ieee80211_node::ni_chan, ieee80211_node::ni_erp, ieee80211_node::ni_essid, ieee80211_node::ni_esslen, ieee80211_node::ni_fhdwell, ieee80211_node::ni_fhindex, ieee80211_node::ni_flags, ieee80211_node::ni_ic, ieee80211_node::ni_ies, ieee80211_node::ni_intval, ieee80211_node::ni_macaddr, ieee80211_node::ni_timoff, ieee80211_node::ni_tstamp, ieee80211_node::ni_vap, ieee80211_scanparams::rates, ieee80211_scanparams::ssid, ieee80211_scanparams::timoff, ieee80211_scanparams::tstamp, ieee80211_ies::vhtcap_ie, ieee80211_ies::vhtopmode_ie, ieee80211_ies::wme_ie, and ieee80211_scanparams::xrates.

Referenced by adhoc_recv_mgmt(), and ieee80211_add_neighbor().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_iterate_nodes()

void ieee80211_iterate_nodes ( struct ieee80211_node_table nt,
ieee80211_iter_func f,
void *  arg 
)

Definition at line 2614 of file ieee80211_node.c.

References ieee80211_iterate_nodes_vap().

Referenced by ieee80211_crypto_reload_keys(), ieee80211_dump_nodes(), ieee80211_ratectl_sysctl_stats(), ieee80211_timeout_stations(), mesh_generateid(), mesh_newstate(), mesh_vdetach(), and setmlme_dropsta().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_iterate_nodes_vap()

int ieee80211_iterate_nodes_vap ( struct ieee80211_node_table nt,
struct ieee80211vap vap,
ieee80211_iter_func f,
void *  arg 
)

◆ ieee80211_node_attach()

◆ ieee80211_node_authorize()

◆ ieee80211_node_create_wds()

◆ ieee80211_node_deauth()

void ieee80211_node_deauth ( struct ieee80211_node ni,
int  reason 
)

Definition at line 1060 of file ieee80211_node.c.

References IEEE80211_FC0_SUBTYPE_DEAUTH, ieee80211_free_node(), ieee80211_node_leave(), ieee80211_ref_node(), IEEE80211_SEND_MGMT, and ieee80211_node::ni_associd.

Referenced by wpa_assocreq().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_node_delucastkey()

◆ ieee80211_node_detach()

void ieee80211_node_detach ( struct ieee80211com ic)

Definition at line 137 of file ieee80211_node.c.

References ieee80211com::ic_inact, ieee80211com::ic_sta, ieee80211com::ic_stageq, ieee80211_ageq_cleanup(), ieee80211_ageq_drain(), and ieee80211_node_table_cleanup().

Referenced by ieee80211_ifdetach().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_node_join()

◆ ieee80211_node_join_11g()

◆ ieee80211_node_latevattach()

◆ ieee80211_node_leave()

◆ ieee80211_node_leave_11g()

◆ ieee80211_node_set_chan()

◆ ieee80211_node_setuptxparms()

◆ ieee80211_node_table_cleanup()

static void ieee80211_node_table_cleanup ( struct ieee80211_node_table nt)
static

Definition at line 2312 of file ieee80211_node.c.

References IEEE80211_FREE, IEEE80211_NODE_LOCK_DESTROY, ieee80211_node_table_reset(), ieee80211_node_table::nt_keyixmap, ieee80211_node_table::nt_keyixmax, and ieee80211_node_table::nt_name.

Referenced by ieee80211_node_detach().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_node_table_init()

static void ieee80211_node_table_init ( struct ieee80211com ic,
struct ieee80211_node_table nt,
const char *  name,
int  inact,
int  keymaxix 
)
static

◆ ieee80211_node_table_reset()

static void ieee80211_node_table_reset ( struct ieee80211_node_table nt,
struct ieee80211vap match 
)
static

◆ ieee80211_node_timeout()

void ieee80211_node_timeout ( void *  arg)

◆ ieee80211_node_unauthorize()

void ieee80211_node_unauthorize ( struct ieee80211_node ni)

◆ ieee80211_node_vattach()

◆ ieee80211_node_vdetach()

void ieee80211_node_vdetach ( struct ieee80211vap vap)

Definition at line 193 of file ieee80211_node.c.

References ieee80211com::ic_sta, IEEE80211_FREE, ieee80211_free_node(), ieee80211_node_table_reset(), ieee80211vap::iv_aid_bitmap, ieee80211vap::iv_bss, and ieee80211vap::iv_ic.

Referenced by ieee80211_vap_detach().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_notify_erp_locked()

void ieee80211_notify_erp_locked ( struct ieee80211com ic)

Definition at line 2669 of file ieee80211_node.c.

References IEEE80211_BEACON_ERP, ieee80211_beacon_notify(), IEEE80211_LOCK_ASSERT, IEEE80211_M_HOSTAP, and ieee80211vap::iv_opmode.

Referenced by vap_update_erp_protmode(), and vap_update_preamble().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_reset_bss()

◆ ieee80211_setcurchan()

void ieee80211_setcurchan ( struct ieee80211com ic,
struct ieee80211_channel c 
)

Definition at line 820 of file ieee80211_node.c.

References ieee80211com::ic_chan_task, ieee80211_runtask(), and ieee80211_setupcurchan().

Referenced by ieee80211_csa_completeswitch(), ieee80211_sta_join1(), and setcurchan().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_setupcurchan()

◆ ieee80211_sta_join()

int ieee80211_sta_join ( struct ieee80211vap vap,
struct ieee80211_channel chan,
const struct ieee80211_scan_entry se 
)

Definition at line 910 of file ieee80211_node.c.

References ieee80211_ies::ath_ie, ieee80211_ies::data, ieee80211_ies::htcap_ie, ieee80211_ies::htinfo_ie, ieee80211com::ic_sta, IEEE80211_ADDR_COPY, ieee80211_alloc_node(), IEEE80211_F_DOBRS, IEEE80211_F_DOSORT, IEEE80211_F_JOIN, IEEE80211_FHT_HT, IEEE80211_FVHT_VHT, ieee80211_ht_node_init(), ieee80211_ht_updateparams(), ieee80211_ht_updateparams_final(), ieee80211_ies_expand(), ieee80211_ies_init(), IEEE80211_IS_CHAN_2GHZ, ieee80211_iserp_rateset(), IEEE80211_M_STA, IEEE80211_NODE_ASSOCID, IEEE80211_NODE_ERP, ieee80211_node_setuptxparms(), ieee80211_parse_ath(), ieee80211_parse_htcap(), ieee80211_parse_htinfo(), ieee80211_parse_meshid(), ieee80211_parse_tdma(), ieee80211_parse_vhtcap(), ieee80211_parse_vhtopmode(), ieee80211_ratectl_node_init(), ieee80211_ref_node(), IEEE80211_RSSI_LPF, ieee80211_setup_basic_htrates(), ieee80211_setup_htrates(), ieee80211_setup_rates(), ieee80211_setup_vht_rates(), ieee80211_sta_join1(), ieee80211_vht_node_init(), ieee80211_vht_updateparams(), ieee80211vap::iv_dtim_count, ieee80211vap::iv_dtim_period, ieee80211vap::iv_flags_ht, ieee80211vap::iv_flags_vht, ieee80211vap::iv_ic, ieee80211vap::iv_opmode, ieee80211_ies::len, ieee80211_ies::meshid_ie, ieee80211_node::ni_avgrssi, ieee80211_node::ni_bssid, ieee80211_node::ni_capinfo, ieee80211_node::ni_chan, ieee80211_node::ni_erp, ieee80211_node::ni_essid, ieee80211_node::ni_esslen, ieee80211_node::ni_fhdwell, ieee80211_node::ni_fhindex, ieee80211_node::ni_flags, ieee80211_node::ni_ies, ieee80211_node::ni_intval, ieee80211_node::ni_macaddr, ieee80211_node::ni_noise, ieee80211_node::ni_rates, ieee80211_node::ni_timoff, ieee80211_node::ni_tstamp, ieee80211_scan_entry::se_bssid, ieee80211_scan_entry::se_capinfo, ieee80211_scan_entry::se_dtimperiod, ieee80211_scan_entry::se_erp, ieee80211_scan_entry::se_fhdwell, ieee80211_scan_entry::se_fhindex, ieee80211_scan_entry::se_ies, ieee80211_scan_entry::se_intval, ieee80211_scan_entry::se_macaddr, ieee80211_scan_entry::se_noise, ieee80211_scan_entry::se_rates, ieee80211_scan_entry::se_rssi, ieee80211_scan_entry::se_ssid, ieee80211_scan_entry::se_timoff, ieee80211_scan_entry::se_tstamp, ieee80211_scan_entry::se_xrates, ieee80211_ies::tdma_ie, ieee80211_node::tsf, ieee80211_scan_entry::tsf, ieee80211_ies::vhtcap_ie, and ieee80211_ies::vhtopmode_ie.

Referenced by adhoc_pick_bss(), setmlme_assoc_sta(), sta_pick_bss(), and sta_roam_check().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_sta_join1()

◆ ieee80211_sta_leave()

void ieee80211_sta_leave ( struct ieee80211_node ni)

Definition at line 1048 of file ieee80211_node.c.

References ieee80211com::ic_node_cleanup, ieee80211_notify_node_leave(), and ieee80211_node::ni_ic.

Referenced by ieee80211_node_leave(), and sta_newstate().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_sync_curchan()

◆ ieee80211_timeout_stations()

static void ieee80211_timeout_stations ( struct ieee80211com ic)
static

Definition at line 2453 of file ieee80211_node.c.

References ieee80211com::ic_sta, ieee80211_iterate_nodes(), and timeout_stations().

Referenced by ieee80211_node_timeout().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_tmp_node()

◆ ieee80211_update_chw()

void ieee80211_update_chw ( struct ieee80211com ic)

Definition at line 827 of file ieee80211_node.c.

References ieee80211com::ic_chw_task, ieee80211com::ic_curchan, ieee80211_runtask(), and ieee80211_setupcurchan().

Referenced by adhoc_recv_mgmt(), and sta_recv_mgmt().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ieee80211_vap_erp_timeout()

static void ieee80211_vap_erp_timeout ( struct ieee80211vap vap)
static

◆ ieee80211_vap_timeout()

static void ieee80211_vap_timeout ( struct ieee80211vap vap)
static

Definition at line 2514 of file ieee80211_node.c.

References ieee80211_ht_timeout(), IEEE80211_LOCK_ASSERT, ieee80211_vap_erp_timeout(), ieee80211_vht_timeout(), and ieee80211vap::iv_ic.

Referenced by ieee80211_node_timeout().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MALLOC_DEFINE() [1/2]

MALLOC_DEFINE ( M_80211_NODE  ,
"80211node"  ,
"802.11 node state"   
)

◆ MALLOC_DEFINE() [2/2]

MALLOC_DEFINE ( M_80211_NODE_IE  ,
"80211nodeie"  ,
"802.11 node ie"   
)

◆ match_ssid()

static int match_ssid ( const struct ieee80211_node ni,
int  nssid,
const struct ieee80211_scan_ssid  ssids[] 
)
static

Definition at line 467 of file ieee80211_node.c.

References ieee80211_scan_ssid::len, ieee80211_node::ni_essid, ieee80211_node::ni_esslen, and ieee80211_scan_ssid::ssid.

Referenced by check_bss().

Here is the caller graph for this function:

◆ node_age()

static void node_age ( struct ieee80211_node ni)
static

Definition at line 1291 of file ieee80211_node.c.

References ieee80211_ht_node_age(), IEEE80211_NODE_HT, ieee80211_node_psq_age(), ieee80211vap::iv_set_tim, ieee80211_node::ni_associd, ieee80211_node::ni_flags, ieee80211_node::ni_psq, ieee80211_node::ni_vap, and ieee80211_psq::psq_len.

Referenced by ieee80211_node_attach().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ node_alloc()

static struct ieee80211_node * node_alloc ( struct ieee80211vap vap,
const uint8_t  macaddr[IEEE80211_ADDR_LEN] 
)
static

Definition at line 1071 of file ieee80211_node.c.

References IEEE80211_M_NOWAIT, IEEE80211_M_ZERO, and IEEE80211_MALLOC.

Referenced by ieee80211_node_attach().

Here is the caller graph for this function:

◆ node_cleanup()

◆ node_clear_keyixmap()

static int node_clear_keyixmap ( struct ieee80211_node_table nt,
struct ieee80211_node ni 
)
static

◆ node_free()

static void node_free ( struct ieee80211_node ni)
static

Definition at line 1279 of file ieee80211_node.c.

References ieee80211com::ic_node_cleanup, IEEE80211_FREE, ieee80211_ies_cleanup(), ieee80211_psq_cleanup(), ieee80211_ratectl_node_deinit(), ieee80211_node::ni_ic, ieee80211_node::ni_ies, and ieee80211_node::ni_psq.

Referenced by ieee80211_node_attach().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ node_getmimoinfo()

◆ node_getrssi()

static int8_t node_getrssi ( const struct ieee80211_node ni)
static

Definition at line 1310 of file ieee80211_node.c.

References IEEE80211_RSSI_DUMMY_MARKER, IEEE80211_RSSI_GET, and ieee80211_node::ni_avgrssi.

Referenced by ieee80211_dump_node(), ieee80211_node_attach(), and node_getsignal().

Here is the caller graph for this function:

◆ node_getsignal()

static void node_getsignal ( const struct ieee80211_node ni,
int8_t *  rssi,
int8_t *  noise 
)
static

Definition at line 1322 of file ieee80211_node.c.

References ieee80211_node::ni_noise, and node_getrssi().

Referenced by ieee80211_node_attach().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ node_init()

static int node_init ( struct ieee80211_node ni)
static

Definition at line 1081 of file ieee80211_node.c.

Referenced by ieee80211_node_attach().

Here is the caller graph for this function:

◆ node_reclaim()

◆ timeout_stations()