linux/net/wireless/nl80211.c

// SPDX-License-Identifier: GPL-2.0-only
/*
 * This is the new netlink-based wireless configuration interface.
 *
 * Copyright 2006-2010	Johannes Berg <[email protected]>
 * Copyright 2013-2014  Intel Mobile Communications GmbH
 * Copyright 2015-2017	Intel Deutschland GmbH
 * Copyright (C) 2018-2024 Intel Corporation
 */

#include <linux/if.h>
#include <linux/module.h>
#include <linux/err.h>
#include <linux/slab.h>
#include <linux/list.h>
#include <linux/if_ether.h>
#include <linux/ieee80211.h>
#include <linux/nl80211.h>
#include <linux/rtnetlink.h>
#include <linux/netlink.h>
#include <linux/nospec.h>
#include <linux/etherdevice.h>
#include <linux/if_vlan.h>
#include <net/net_namespace.h>
#include <net/genetlink.h>
#include <net/cfg80211.h>
#include <net/sock.h>
#include <net/inet_connection_sock.h>
#include "core.h"
#include "nl80211.h"
#include "reg.h"
#include "rdev-ops.h"

static int nl80211_crypto_settings(struct cfg80211_registered_device *rdev,
				   struct genl_info *info,
				   struct cfg80211_crypto_settings *settings,
				   int cipher_limit);

/* the netlink family */
static struct genl_family nl80211_fam;

/* multicast groups */
enum nl80211_multicast_groups {};

static const struct genl_multicast_group nl80211_mcgrps[] =;

/* returns ERR_PTR values */
static struct wireless_dev *
__cfg80211_wdev_from_attrs(struct cfg80211_registered_device *rdev,
			   struct net *netns, struct nlattr **attrs)
{}

static struct cfg80211_registered_device *
__cfg80211_rdev_from_attrs(struct net *netns, struct nlattr **attrs)
{}

/*
 * This function returns a pointer to the driver
 * that the genl_info item that is passed refers to.
 *
 * The result of this can be a PTR_ERR and hence must
 * be checked with IS_ERR() for errors.
 */
static struct cfg80211_registered_device *
cfg80211_get_dev_from_info(struct net *netns, struct genl_info *info)
{}

static int validate_beacon_head(const struct nlattr *attr,
				struct netlink_ext_ack *extack)
{}

static int validate_ie_attr(const struct nlattr *attr,
			    struct netlink_ext_ack *extack)
{}

static int validate_he_capa(const struct nlattr *attr,
			    struct netlink_ext_ack *extack)
{}

/* policy for the attributes */
static const struct nla_policy nl80211_policy[NUM_NL80211_ATTR];

static const struct nla_policy
nl80211_ftm_responder_policy[NL80211_FTM_RESP_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_pmsr_ftm_req_attr_policy[NL80211_PMSR_FTM_REQ_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_pmsr_req_data_policy[NL80211_PMSR_TYPE_MAX + 1] =;

static const struct nla_policy
nl80211_pmsr_req_attr_policy[NL80211_PMSR_REQ_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_pmsr_peer_attr_policy[NL80211_PMSR_PEER_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_pmsr_attr_policy[NL80211_PMSR_ATTR_MAX + 1] =;

static const struct nla_policy
he_obss_pd_policy[NL80211_HE_OBSS_PD_ATTR_MAX + 1] =;

static const struct nla_policy
he_bss_color_policy[NL80211_HE_BSS_COLOR_ATTR_MAX + 1] =;

static const struct nla_policy nl80211_txattr_policy[NL80211_TXRATE_MAX + 1] =;

static const struct nla_policy
nl80211_tid_config_attr_policy[NL80211_TID_CONFIG_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_fils_discovery_policy[NL80211_FILS_DISCOVERY_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_unsol_bcast_probe_resp_policy[NL80211_UNSOL_BCAST_PROBE_RESP_ATTR_MAX + 1] =;

static const struct nla_policy
sar_specs_policy[NL80211_SAR_ATTR_SPECS_MAX + 1] =;

static const struct nla_policy
sar_policy[NL80211_SAR_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_mbssid_config_policy[NL80211_MBSSID_CONFIG_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_sta_wme_policy[NL80211_STA_WME_MAX + 1] =;

static const struct netlink_range_validation nl80211_punct_bitmap_range =;

static const struct netlink_range_validation q_range =;

static const struct nla_policy nl80211_policy[NUM_NL80211_ATTR] =;

/* policy for the key attributes */
static const struct nla_policy nl80211_key_policy[NL80211_KEY_MAX + 1] =;

/* policy for the key default flags */
static const struct nla_policy
nl80211_key_default_policy[NUM_NL80211_KEY_DEFAULT_TYPES] =;

#ifdef CONFIG_PM
/* policy for WoWLAN attributes */
static const struct nla_policy
nl80211_wowlan_policy[NUM_NL80211_WOWLAN_TRIG] =;

static const struct nla_policy
nl80211_wowlan_tcp_policy[NUM_NL80211_WOWLAN_TCP] =;
#endif /* CONFIG_PM */

/* policy for coalesce rule attributes */
static const struct nla_policy
nl80211_coalesce_policy[NUM_NL80211_ATTR_COALESCE_RULE] =;

/* policy for GTK rekey offload attributes */
static const struct nla_policy
nl80211_rekey_policy[NUM_NL80211_REKEY_DATA] =;

static const struct nla_policy
nl80211_match_policy[NL80211_SCHED_SCAN_MATCH_ATTR_MAX + 1] =;

static const struct nla_policy
nl80211_plan_policy[NL80211_SCHED_SCAN_PLAN_MAX + 1] =;

static const struct nla_policy
nl80211_bss_select_policy[NL80211_BSS_SELECT_ATTR_MAX + 1] =;

/* policy for NAN function attributes */
static const struct nla_policy
nl80211_nan_func_policy[NL80211_NAN_FUNC_ATTR_MAX + 1] =;

/* policy for Service Response Filter attributes */
static const struct nla_policy
nl80211_nan_srf_policy[NL80211_NAN_SRF_ATTR_MAX + 1] =;

/* policy for packet pattern attributes */
static const struct nla_policy
nl80211_packet_pattern_policy[MAX_NL80211_PKTPAT + 1] =;

static int nl80211_prepare_wdev_dump(struct netlink_callback *cb,
				     struct cfg80211_registered_device **rdev,
				     struct wireless_dev **wdev,
				     struct nlattr **attrbuf)
{}

/* message building helper */
void *nl80211hdr_put(struct sk_buff *skb, u32 portid, u32 seq,
		     int flags, u8 cmd)
{}

static int nl80211_msg_put_wmm_rules(struct sk_buff *msg,
				     const struct ieee80211_reg_rule *rule)
{}

static int nl80211_msg_put_channel(struct sk_buff *msg, struct wiphy *wiphy,
				   struct ieee80211_channel *chan,
				   bool large)
{}

static bool nl80211_put_txq_stats(struct sk_buff *msg,
				  struct cfg80211_txq_stats *txqstats,
				  int attrtype)
{}

/* netlink command implementations */

/**
 * nl80211_link_id - return link ID
 * @attrs: attributes to look at
 *
 * Returns: the link ID or 0 if not given
 *
 * Note this function doesn't do any validation of the link
 * ID validity wrt. links that were actually added, so it must
 * be called only from ops with %NL80211_FLAG_MLO_VALID_LINK_ID
 * or if additional validation is done.
 */
static unsigned int nl80211_link_id(struct nlattr **attrs)
{}

static int nl80211_link_id_or_invalid(struct nlattr **attrs)
{}

struct key_parse {};

static int nl80211_parse_key_new(struct genl_info *info, struct nlattr *key,
				 struct key_parse *k)
{}

static int nl80211_parse_key_old(struct genl_info *info, struct key_parse *k)
{}

static int nl80211_parse_key(struct genl_info *info, struct key_parse *k)
{}

static struct cfg80211_cached_keys *
nl80211_parse_connkeys(struct cfg80211_registered_device *rdev,
		       struct genl_info *info, bool *no_ht)
{}

static int nl80211_key_allowed(struct wireless_dev *wdev)
{}

static struct ieee80211_channel *nl80211_get_valid_chan(struct wiphy *wiphy,
							u32 freq)
{}

static int nl80211_put_iftypes(struct sk_buff *msg, u32 attr, u16 ifmodes)
{}

static int nl80211_put_ifcomb_data(struct sk_buff *msg, bool large, int idx,
				   const struct ieee80211_iface_combination *c,
				   u16 nested)
{}

static int nl80211_put_iface_combinations(struct wiphy *wiphy,
					  struct sk_buff *msg,
					  int attr, int radio,
					  bool large, u16 nested)
{}

#ifdef CONFIG_PM
static int nl80211_send_wowlan_tcp_caps(struct cfg80211_registered_device *rdev,
					struct sk_buff *msg)
{}

static int nl80211_send_wowlan(struct sk_buff *msg,
			       struct cfg80211_registered_device *rdev,
			       bool large)
{}
#endif

static int nl80211_send_coalesce(struct sk_buff *msg,
				 struct cfg80211_registered_device *rdev)
{}

static int
nl80211_send_iftype_data(struct sk_buff *msg,
			 const struct ieee80211_supported_band *sband,
			 const struct ieee80211_sband_iftype_data *iftdata)
{}

static int nl80211_send_band_rateinfo(struct sk_buff *msg,
				      struct ieee80211_supported_band *sband,
				      bool large)
{}

static int
nl80211_send_mgmt_stypes(struct sk_buff *msg,
			 const struct ieee80211_txrx_stypes *mgmt_stypes)
{}

#define CMD

static int nl80211_add_commands_unsplit(struct cfg80211_registered_device *rdev,
					struct sk_buff *msg)
{}

static int
nl80211_send_pmsr_ftm_capa(const struct cfg80211_pmsr_capabilities *cap,
			   struct sk_buff *msg)
{}

static int nl80211_send_pmsr_capa(struct cfg80211_registered_device *rdev,
				  struct sk_buff *msg)
{}

static int
nl80211_put_iftype_akm_suites(struct cfg80211_registered_device *rdev,
			      struct sk_buff *msg)
{}

static int
nl80211_put_tid_config_support(struct cfg80211_registered_device *rdev,
			       struct sk_buff *msg)
{}

static int
nl80211_put_sar_specs(struct cfg80211_registered_device *rdev,
		      struct sk_buff *msg)
{}

static int nl80211_put_mbssid_support(struct wiphy *wiphy, struct sk_buff *msg)
{}

static int nl80211_put_radio(struct wiphy *wiphy, struct sk_buff *msg, int idx)
{}

static int nl80211_put_radios(struct wiphy *wiphy, struct sk_buff *msg)
{}

struct nl80211_dump_wiphy_state {};

static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
			      enum nl80211_commands cmd,
			      struct sk_buff *msg, u32 portid, u32 seq,
			      int flags, struct nl80211_dump_wiphy_state *state)
{}

static int nl80211_dump_wiphy_parse(struct sk_buff *skb,
				    struct netlink_callback *cb,
				    struct nl80211_dump_wiphy_state *state)
{}

static int nl80211_dump_wiphy(struct sk_buff *skb, struct netlink_callback *cb)
{}

static int nl80211_dump_wiphy_done(struct netlink_callback *cb)
{}

static int nl80211_get_wiphy(struct sk_buff *skb, struct genl_info *info)
{}

static const struct nla_policy txq_params_policy[NL80211_TXQ_ATTR_MAX + 1] =;

static int parse_txq_params(struct nlattr *tb[],
			    struct ieee80211_txq_params *txq_params)
{}

static bool nl80211_can_set_dev_channel(struct wireless_dev *wdev)
{}

static int _nl80211_parse_chandef(struct cfg80211_registered_device *rdev,
				  struct genl_info *info, bool monitor,
				  struct cfg80211_chan_def *chandef)
{}

int nl80211_parse_chandef(struct cfg80211_registered_device *rdev,
			  struct genl_info *info,
			  struct cfg80211_chan_def *chandef)
{}

static int __nl80211_set_channel(struct cfg80211_registered_device *rdev,
				 struct net_device *dev,
				 struct genl_info *info,
				 int _link_id)
{}

static int nl80211_set_channel(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_wiphy(struct sk_buff *skb, struct genl_info *info)
{}

int nl80211_send_chandef(struct sk_buff *msg, const struct cfg80211_chan_def *chandef)
{}
EXPORT_SYMBOL();

static int nl80211_send_iface(struct sk_buff *msg, u32 portid, u32 seq, int flags,
			      struct cfg80211_registered_device *rdev,
			      struct wireless_dev *wdev,
			      enum nl80211_commands cmd)
{}

static int nl80211_dump_interface(struct sk_buff *skb, struct netlink_callback *cb)
{}

static int nl80211_get_interface(struct sk_buff *skb, struct genl_info *info)
{}

static const struct nla_policy mntr_flags_policy[NL80211_MNTR_FLAG_MAX + 1] =;

static int parse_monitor_flags(struct nlattr *nla, u32 *mntrflags)
{}

static int nl80211_parse_mon_options(struct cfg80211_registered_device *rdev,
				     enum nl80211_iftype type,
				     struct genl_info *info,
				     struct vif_params *params)
{}

static int nl80211_valid_4addr(struct cfg80211_registered_device *rdev,
			       struct net_device *netdev, u8 use_4addr,
			       enum nl80211_iftype iftype)
{}

static int nl80211_set_interface(struct sk_buff *skb, struct genl_info *info)
{}

static int _nl80211_new_interface(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_new_interface(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_del_interface(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_noack_map(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_validate_key_link_id(struct genl_info *info,
					struct wireless_dev *wdev,
					int link_id, bool pairwise)
{}

struct get_key_cookie {};

static void get_key_callback(void *c, struct key_params *params)
{}

static int nl80211_get_key(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_key(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_new_key(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_del_key(struct sk_buff *skb, struct genl_info *info)
{}

/* This function returns an error or the number of nested attributes */
static int validate_acl_mac_addrs(struct nlattr *nl_attr)
{}

/*
 * This function parses ACL information and allocates memory for ACL data.
 * On successful return, the calling function is responsible to free the
 * ACL buffer returned by this function.
 */
static struct cfg80211_acl_data *parse_acl_data(struct wiphy *wiphy,
						struct genl_info *info)
{}

static int nl80211_set_mac_acl(struct sk_buff *skb, struct genl_info *info)
{}

static u32 rateset_to_mask(struct ieee80211_supported_band *sband,
			   u8 *rates, u8 rates_len)
{}

static bool ht_rateset_to_mask(struct ieee80211_supported_band *sband,
			       u8 *rates, u8 rates_len,
			       u8 mcs[IEEE80211_HT_MCS_MASK_LEN])
{}

static u16 vht_mcs_map_to_mcs_mask(u8 vht_mcs_map)
{}

static void vht_build_mcs_mask(u16 vht_mcs_map,
			       u16 vht_mcs_mask[NL80211_VHT_NSS_MAX])
{}

static bool vht_set_mcs_mask(struct ieee80211_supported_band *sband,
			     struct nl80211_txrate_vht *txrate,
			     u16 mcs[NL80211_VHT_NSS_MAX])
{}

static u16 he_mcs_map_to_mcs_mask(u8 he_mcs_map)
{}

static void he_build_mcs_mask(u16 he_mcs_map,
			      u16 he_mcs_mask[NL80211_HE_NSS_MAX])
{}

static u16 he_get_txmcsmap(struct genl_info *info, unsigned int link_id,
			   const struct ieee80211_sta_he_cap *he_cap)
{}

static bool he_set_mcs_mask(struct genl_info *info,
			    struct wireless_dev *wdev,
			    struct ieee80211_supported_band *sband,
			    struct nl80211_txrate_he *txrate,
			    u16 mcs[NL80211_HE_NSS_MAX],
			    unsigned int link_id)
{}

static int nl80211_parse_tx_bitrate_mask(struct genl_info *info,
					 struct nlattr *attrs[],
					 enum nl80211_attrs attr,
					 struct cfg80211_bitrate_mask *mask,
					 struct net_device *dev,
					 bool default_all_enabled,
					 unsigned int link_id)
{}

static int validate_beacon_tx_rate(struct cfg80211_registered_device *rdev,
				   enum nl80211_band band,
				   struct cfg80211_bitrate_mask *beacon_rate)
{}

static int nl80211_parse_mbssid_config(struct wiphy *wiphy,
				       struct net_device *dev,
				       struct nlattr *attrs,
				       struct cfg80211_mbssid_config *config,
				       u8 num_elems)
{}

static struct cfg80211_mbssid_elems *
nl80211_parse_mbssid_elems(struct wiphy *wiphy, struct nlattr *attrs)
{}

static struct cfg80211_rnr_elems *
nl80211_parse_rnr_elems(struct wiphy *wiphy, struct nlattr *attrs,
			struct netlink_ext_ack *extack)
{}

static int nl80211_parse_he_bss_color(struct nlattr *attrs,
				      struct cfg80211_he_bss_color *he_bss_color)
{}

static int nl80211_parse_beacon(struct cfg80211_registered_device *rdev,
				struct nlattr *attrs[],
				struct cfg80211_beacon_data *bcn,
				struct netlink_ext_ack *extack)
{}

static int nl80211_parse_he_obss_pd(struct nlattr *attrs,
				    struct ieee80211_he_obss_pd *he_obss_pd)
{}

static int nl80211_parse_fils_discovery(struct cfg80211_registered_device *rdev,
					struct nlattr *attrs,
					struct cfg80211_fils_discovery *fd)
{}

static int
nl80211_parse_unsol_bcast_probe_resp(struct cfg80211_registered_device *rdev,
				     struct nlattr *attrs,
				     struct cfg80211_unsol_bcast_probe_resp *presp)
{}

static void nl80211_check_ap_rate_selectors(struct cfg80211_ap_settings *params,
					    const struct element *rates)
{}

/*
 * Since the nl80211 API didn't include, from the beginning, attributes about
 * HT/VHT requirements/capabilities, we parse them out of the IEs for the
 * benefit of drivers that rebuild IEs in the firmware.
 */
static int nl80211_calculate_ap_params(struct cfg80211_ap_settings *params)
{}

static bool nl80211_get_ap_channel(struct cfg80211_registered_device *rdev,
				   struct cfg80211_ap_settings *params)
{}

static bool nl80211_valid_auth_type(struct cfg80211_registered_device *rdev,
				    enum nl80211_auth_type auth_type,
				    enum nl80211_commands cmd)
{}

static void nl80211_send_ap_started(struct wireless_dev *wdev,
				    unsigned int link_id)
{}

static int nl80211_validate_ap_phy_operation(struct cfg80211_ap_settings *params)
{}

static int nl80211_start_ap(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_beacon(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_stop_ap(struct sk_buff *skb, struct genl_info *info)
{}

static const struct nla_policy sta_flags_policy[NL80211_STA_FLAG_MAX + 1] =;

static int parse_station_flags(struct genl_info *info,
			       enum nl80211_iftype iftype,
			       struct station_parameters *params)
{}

bool nl80211_put_sta_rate(struct sk_buff *msg, struct rate_info *info, int attr)
{}

static bool nl80211_put_signal(struct sk_buff *msg, u8 mask, s8 *signal,
			       int id)
{}

static int nl80211_send_station(struct sk_buff *msg, u32 cmd, u32 portid,
				u32 seq, int flags,
				struct cfg80211_registered_device *rdev,
				struct net_device *dev,
				const u8 *mac_addr, struct station_info *sinfo)
{}

static int nl80211_dump_station(struct sk_buff *skb,
				struct netlink_callback *cb)
{}

static int nl80211_get_station(struct sk_buff *skb, struct genl_info *info)
{}

int cfg80211_check_station_change(struct wiphy *wiphy,
				  struct station_parameters *params,
				  enum cfg80211_station_type statype)
{}
EXPORT_SYMBOL();

/*
 * Get vlan interface making sure it is running and on the right wiphy.
 */
static struct net_device *get_vlan(struct genl_info *info,
				   struct cfg80211_registered_device *rdev)
{}

static int nl80211_parse_sta_wme(struct genl_info *info,
				 struct station_parameters *params)
{}

static int nl80211_parse_sta_channel_info(struct genl_info *info,
				      struct station_parameters *params)
{}

static int nl80211_set_station_tdls(struct genl_info *info,
				    struct station_parameters *params)
{}

static int nl80211_parse_sta_txpower_setting(struct genl_info *info,
					     struct sta_txpwr *txpwr,
					     bool *txpwr_set)
{}

static int nl80211_set_station(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_new_station(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_del_station(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_send_mpath(struct sk_buff *msg, u32 portid, u32 seq,
				int flags, struct net_device *dev,
				u8 *dst, u8 *next_hop,
				struct mpath_info *pinfo)
{}

static int nl80211_dump_mpath(struct sk_buff *skb,
			      struct netlink_callback *cb)
{}

static int nl80211_get_mpath(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_mpath(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_new_mpath(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_del_mpath(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_get_mpp(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_dump_mpp(struct sk_buff *skb,
			    struct netlink_callback *cb)
{}

static int nl80211_set_bss(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_req_set_reg(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_reload_regdb(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_get_mesh_config(struct sk_buff *skb,
				   struct genl_info *info)
{}

static const struct nla_policy
nl80211_meshconf_params_policy[NL80211_MESHCONF_ATTR_MAX+1] =;

static const struct nla_policy
	nl80211_mesh_setup_params_policy[NL80211_MESH_SETUP_ATTR_MAX+1] =;

static int nl80211_parse_mesh_config(struct genl_info *info,
				     struct mesh_config *cfg,
				     u32 *mask_out)
{}

static int nl80211_parse_mesh_setup(struct genl_info *info,
				     struct mesh_setup *setup)
{}

static int nl80211_update_mesh_config(struct sk_buff *skb,
				      struct genl_info *info)
{}

static int nl80211_put_regdom(const struct ieee80211_regdomain *regdom,
			      struct sk_buff *msg)
{}

static int nl80211_get_reg_do(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_send_regdom(struct sk_buff *msg, struct netlink_callback *cb,
			       u32 seq, int flags, struct wiphy *wiphy,
			       const struct ieee80211_regdomain *regdom)
{}

static int nl80211_get_reg_dump(struct sk_buff *skb,
				struct netlink_callback *cb)
{}

#ifdef CONFIG_CFG80211_CRDA_SUPPORT
static const struct nla_policy reg_rule_policy[NL80211_REG_RULE_ATTR_MAX + 1] =;

static int parse_reg_rule(struct nlattr *tb[],
	struct ieee80211_reg_rule *reg_rule)
{}

static int nl80211_set_reg(struct sk_buff *skb, struct genl_info *info)
{}
#endif /* CONFIG_CFG80211_CRDA_SUPPORT */

static int validate_scan_freqs(struct nlattr *freqs)
{}

static bool is_band_valid(struct wiphy *wiphy, enum nl80211_band b)
{}

static int parse_bss_select(struct nlattr *nla, struct wiphy *wiphy,
			    struct cfg80211_bss_selection *bss_select)
{}

int nl80211_parse_random_mac(struct nlattr **attrs,
			     u8 *mac_addr, u8 *mac_addr_mask)
{}

static bool cfg80211_off_channel_oper_allowed(struct wireless_dev *wdev,
					      struct ieee80211_channel *chan)
{}

static bool nl80211_check_scan_feat(struct wiphy *wiphy, u32 flags, u32 flag,
				    enum nl80211_ext_feature_index feat)
{}

static int
nl80211_check_scan_flags(struct wiphy *wiphy, struct wireless_dev *wdev,
			 void *request, struct nlattr **attrs,
			 bool is_sched_scan)
{}

static int nl80211_trigger_scan(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_abort_scan(struct sk_buff *skb, struct genl_info *info)
{}

static int
nl80211_parse_sched_scan_plans(struct wiphy *wiphy, int n_plans,
			       struct cfg80211_sched_scan_request *request,
			       struct nlattr **attrs)
{}

static struct cfg80211_sched_scan_request *
nl80211_parse_sched_scan(struct wiphy *wiphy, struct wireless_dev *wdev,
			 struct nlattr **attrs, int max_match_sets)
{}

static int nl80211_start_sched_scan(struct sk_buff *skb,
				    struct genl_info *info)
{}

static int nl80211_stop_sched_scan(struct sk_buff *skb,
				   struct genl_info *info)
{}

static int nl80211_start_radar_detection(struct sk_buff *skb,
					 struct genl_info *info)
{}

static int nl80211_notify_radar_detection(struct sk_buff *skb,
					  struct genl_info *info)
{}

static int nl80211_parse_counter_offsets(struct cfg80211_registered_device *rdev,
					 const u8 *data, size_t datalen,
					 int first_count, struct nlattr *attr,
					 const u16 **offsets, unsigned int *n_offsets)
{}

static int nl80211_channel_switch(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_send_bss(struct sk_buff *msg, struct netlink_callback *cb,
			    u32 seq, int flags,
			    struct cfg80211_registered_device *rdev,
			    struct wireless_dev *wdev,
			    struct cfg80211_internal_bss *intbss)
{}

static int nl80211_dump_scan(struct sk_buff *skb, struct netlink_callback *cb)
{}

static int nl80211_send_survey(struct sk_buff *msg, u32 portid, u32 seq,
			       int flags, struct net_device *dev,
			       bool allow_radio_stats,
			       struct survey_info *survey)
{}

static int nl80211_dump_survey(struct sk_buff *skb, struct netlink_callback *cb)
{}

static int nl80211_authenticate(struct sk_buff *skb, struct genl_info *info)
{}

static int validate_pae_over_nl80211(struct cfg80211_registered_device *rdev,
				     struct genl_info *info)
{}

static int nl80211_crypto_settings(struct cfg80211_registered_device *rdev,
				   struct genl_info *info,
				   struct cfg80211_crypto_settings *settings,
				   int cipher_limit)
{}

static struct cfg80211_bss *nl80211_assoc_bss(struct cfg80211_registered_device *rdev,
					      const u8 *ssid, int ssid_len,
					      struct nlattr **attrs,
					      int assoc_link_id, int link_id)
{}

static int nl80211_associate(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_deauthenticate(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_disassociate(struct sk_buff *skb, struct genl_info *info)
{}

static bool
nl80211_parse_mcast_rate(struct cfg80211_registered_device *rdev,
			 int mcast_rate[NUM_NL80211_BANDS],
			 int rateval)
{}

static int nl80211_join_ibss(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_leave_ibss(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_mcast_rate(struct sk_buff *skb, struct genl_info *info)
{}

static struct sk_buff *
__cfg80211_alloc_vendor_skb(struct cfg80211_registered_device *rdev,
			    struct wireless_dev *wdev, int approxlen,
			    u32 portid, u32 seq, enum nl80211_commands cmd,
			    enum nl80211_attrs attr,
			    const struct nl80211_vendor_cmd_info *info,
			    gfp_t gfp)
{}

struct sk_buff *__cfg80211_alloc_event_skb(struct wiphy *wiphy,
					   struct wireless_dev *wdev,
					   enum nl80211_commands cmd,
					   enum nl80211_attrs attr,
					   unsigned int portid,
					   int vendor_event_idx,
					   int approxlen, gfp_t gfp)
{}
EXPORT_SYMBOL();

void __cfg80211_send_event_skb(struct sk_buff *skb, gfp_t gfp)
{}
EXPORT_SYMBOL();

#ifdef CONFIG_NL80211_TESTMODE
static int nl80211_testmode_do(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_testmode_dump(struct sk_buff *skb,
				 struct netlink_callback *cb)
{}
#endif

static int nl80211_connect(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_update_connect_params(struct sk_buff *skb,
					 struct genl_info *info)
{}

static int nl80211_disconnect(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_wiphy_netns(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_pmksa(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_del_pmksa(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_flush_pmksa(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_tdls_mgmt(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_tdls_oper(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_remain_on_channel(struct sk_buff *skb,
				     struct genl_info *info)
{}

static int nl80211_cancel_remain_on_channel(struct sk_buff *skb,
					    struct genl_info *info)
{}

static int nl80211_set_tx_bitrate_mask(struct sk_buff *skb,
				       struct genl_info *info)
{}

static int nl80211_register_mgmt(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_tx_mgmt(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_tx_mgmt_cancel_wait(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_power_save(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_get_power_save(struct sk_buff *skb, struct genl_info *info)
{}

static const struct nla_policy
nl80211_attr_cqm_policy[NL80211_ATTR_CQM_MAX + 1] =;

static int nl80211_set_cqm_txe(struct genl_info *info,
			       u32 rate, u32 pkts, u32 intvl)
{}

static int cfg80211_cqm_rssi_update(struct cfg80211_registered_device *rdev,
				    struct net_device *dev,
				    struct cfg80211_cqm_config *cqm_config)
{}

static int nl80211_set_cqm_rssi(struct genl_info *info,
				const s32 *thresholds, int n_thresholds,
				u32 hysteresis)
{}

static int nl80211_set_cqm(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_join_ocb(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_leave_ocb(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_join_mesh(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_leave_mesh(struct sk_buff *skb, struct genl_info *info)
{}

#ifdef CONFIG_PM
static int nl80211_send_wowlan_patterns(struct sk_buff *msg,
					struct cfg80211_registered_device *rdev)
{}

static int nl80211_send_wowlan_tcp(struct sk_buff *msg,
				   struct cfg80211_wowlan_tcp *tcp)
{}

static int nl80211_send_wowlan_nd(struct sk_buff *msg,
				  struct cfg80211_sched_scan_request *req)
{}

static int nl80211_get_wowlan(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_parse_wowlan_tcp(struct cfg80211_registered_device *rdev,
				    struct nlattr *attr,
				    struct cfg80211_wowlan *trig)
{}

static int nl80211_parse_wowlan_nd(struct cfg80211_registered_device *rdev,
				   const struct wiphy_wowlan_support *wowlan,
				   struct nlattr *attr,
				   struct cfg80211_wowlan *trig)
{}

static int nl80211_set_wowlan(struct sk_buff *skb, struct genl_info *info)
{}
#endif

static int nl80211_send_coalesce_rules(struct sk_buff *msg,
				       struct cfg80211_registered_device *rdev)
{}

static int nl80211_get_coalesce(struct sk_buff *skb, struct genl_info *info)
{}

void cfg80211_free_coalesce(struct cfg80211_coalesce *coalesce)
{}

static int nl80211_parse_coalesce_rule(struct cfg80211_registered_device *rdev,
				       struct nlattr *rule,
				       struct cfg80211_coalesce_rules *new_rule)
{}

static int nl80211_set_coalesce(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_rekey_data(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_register_unexpected_frame(struct sk_buff *skb,
					     struct genl_info *info)
{}

static int nl80211_probe_client(struct sk_buff *skb,
				struct genl_info *info)
{}

static int nl80211_register_beacons(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_start_p2p_device(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_stop_p2p_device(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_start_nan(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_stop_nan(struct sk_buff *skb, struct genl_info *info)
{}

static int validate_nan_filter(struct nlattr *filter_attr)
{}

static int handle_nan_filter(struct nlattr *attr_filter,
			     struct cfg80211_nan_func *func,
			     bool tx)
{}

static int nl80211_nan_add_func(struct sk_buff *skb,
				struct genl_info *info)
{}

static int nl80211_nan_del_func(struct sk_buff *skb,
			       struct genl_info *info)
{}

static int nl80211_nan_change_config(struct sk_buff *skb,
				     struct genl_info *info)
{}

void cfg80211_nan_match(struct wireless_dev *wdev,
			struct cfg80211_nan_match_params *match, gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_nan_func_terminated(struct wireless_dev *wdev,
				  u8 inst_id,
				  enum nl80211_nan_func_term_reason reason,
				  u64 cookie, gfp_t gfp)
{}
EXPORT_SYMBOL();

static int nl80211_get_protocol_features(struct sk_buff *skb,
					 struct genl_info *info)
{}

static int nl80211_update_ft_ies(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_crit_protocol_start(struct sk_buff *skb,
				       struct genl_info *info)
{}

static int nl80211_crit_protocol_stop(struct sk_buff *skb,
				      struct genl_info *info)
{}

static int nl80211_vendor_check_policy(const struct wiphy_vendor_command *vcmd,
				       struct nlattr *attr,
				       struct netlink_ext_ack *extack)
{}

static int nl80211_vendor_cmd(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_prepare_vendor_dump(struct sk_buff *skb,
				       struct netlink_callback *cb,
				       struct cfg80211_registered_device **rdev,
				       struct wireless_dev **wdev)
{}

static int nl80211_vendor_cmd_dump(struct sk_buff *skb,
				   struct netlink_callback *cb)
{}

struct sk_buff *__cfg80211_alloc_reply_skb(struct wiphy *wiphy,
					   enum nl80211_commands cmd,
					   enum nl80211_attrs attr,
					   int approxlen)
{}
EXPORT_SYMBOL();

int cfg80211_vendor_cmd_reply(struct sk_buff *skb)
{}
EXPORT_SYMBOL_GPL();

unsigned int cfg80211_vendor_cmd_get_sender(struct wiphy *wiphy)
{}
EXPORT_SYMBOL_GPL();

static int nl80211_set_qos_map(struct sk_buff *skb,
			       struct genl_info *info)
{}

static int nl80211_add_tx_ts(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_del_tx_ts(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_tdls_channel_switch(struct sk_buff *skb,
				       struct genl_info *info)
{}

static int nl80211_tdls_cancel_channel_switch(struct sk_buff *skb,
					      struct genl_info *info)
{}

static int nl80211_set_multicast_to_unicast(struct sk_buff *skb,
					    struct genl_info *info)
{}

static int nl80211_set_pmk(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_del_pmk(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_external_auth(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_tx_control_port(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_get_ftm_responder_stats(struct sk_buff *skb,
					   struct genl_info *info)
{}

static int nl80211_update_owe_info(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_probe_mesh_link(struct sk_buff *skb, struct genl_info *info)
{}

static int parse_tid_conf(struct cfg80211_registered_device *rdev,
			  struct nlattr *attrs[], struct net_device *dev,
			  struct cfg80211_tid_cfg *tid_conf,
			  struct genl_info *info, const u8 *peer,
			  unsigned int link_id)
{}

static int nl80211_set_tid_config(struct sk_buff *skb,
				  struct genl_info *info)
{}

static int nl80211_color_change(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_fils_aad(struct sk_buff *skb,
				struct genl_info *info)
{}

static int nl80211_add_link(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_remove_link(struct sk_buff *skb, struct genl_info *info)
{}

static int
nl80211_add_mod_link_station(struct sk_buff *skb, struct genl_info *info,
			     bool add)
{}

static int
nl80211_add_link_station(struct sk_buff *skb, struct genl_info *info)
{}

static int
nl80211_modify_link_station(struct sk_buff *skb, struct genl_info *info)
{}

static int
nl80211_remove_link_station(struct sk_buff *skb, struct genl_info *info)
{}

static int nl80211_set_hw_timestamp(struct sk_buff *skb,
				    struct genl_info *info)
{}

static int
nl80211_set_ttlm(struct sk_buff *skb, struct genl_info *info)
{}

#define NL80211_FLAG_NEED_WIPHY
#define NL80211_FLAG_NEED_NETDEV
#define NL80211_FLAG_NEED_RTNL
#define NL80211_FLAG_CHECK_NETDEV_UP
#define NL80211_FLAG_NEED_NETDEV_UP
#define NL80211_FLAG_NEED_WDEV
/* If a netdev is associated, it must be UP, P2P must be started */
#define NL80211_FLAG_NEED_WDEV_UP
#define NL80211_FLAG_CLEAR_SKB
#define NL80211_FLAG_NO_WIPHY_MTX
#define NL80211_FLAG_MLO_VALID_LINK_ID
#define NL80211_FLAG_MLO_UNSUPPORTED

#define INTERNAL_FLAG_SELECTORS(__sel)

enum nl80211_internal_flags_selector {};

static u32 nl80211_internal_flags[] =;

static int nl80211_pre_doit(const struct genl_split_ops *ops,
			    struct sk_buff *skb,
			    struct genl_info *info)
{}

static void nl80211_post_doit(const struct genl_split_ops *ops,
			      struct sk_buff *skb,
			      struct genl_info *info)
{}

static int nl80211_set_sar_sub_specs(struct cfg80211_registered_device *rdev,
				     struct cfg80211_sar_specs *sar_specs,
				     struct nlattr *spec[], int index)
{}

static int nl80211_set_sar_specs(struct sk_buff *skb, struct genl_info *info)
{}

#define SELECTOR(__sel, name, value)
int __missing_selector(void);
#define IFLAGS(__val)

static const struct genl_ops nl80211_ops[] =;

static const struct genl_small_ops nl80211_small_ops[] =;

static struct genl_family nl80211_fam __ro_after_init =;

/* notification functions */

void nl80211_notify_wiphy(struct cfg80211_registered_device *rdev,
			  enum nl80211_commands cmd)
{}

void nl80211_notify_iface(struct cfg80211_registered_device *rdev,
				struct wireless_dev *wdev,
				enum nl80211_commands cmd)
{}

static int nl80211_add_scan_req(struct sk_buff *msg,
				struct cfg80211_registered_device *rdev)
{}

static int nl80211_prep_scan_msg(struct sk_buff *msg,
				 struct cfg80211_registered_device *rdev,
				 struct wireless_dev *wdev,
				 u32 portid, u32 seq, int flags,
				 u32 cmd)
{}

static int
nl80211_prep_sched_scan_msg(struct sk_buff *msg,
			    struct cfg80211_sched_scan_request *req, u32 cmd)
{}

void nl80211_send_scan_start(struct cfg80211_registered_device *rdev,
			     struct wireless_dev *wdev)
{}

struct sk_buff *nl80211_build_scan_msg(struct cfg80211_registered_device *rdev,
				       struct wireless_dev *wdev, bool aborted)
{}

/* send message created by nl80211_build_scan_msg() */
void nl80211_send_scan_msg(struct cfg80211_registered_device *rdev,
			   struct sk_buff *msg)
{}

void nl80211_send_sched_scan(struct cfg80211_sched_scan_request *req, u32 cmd)
{}

static bool nl80211_reg_change_event_fill(struct sk_buff *msg,
					  struct regulatory_request *request)
{}

/*
 * This can happen on global regulatory changes or device specific settings
 * based on custom regulatory domains.
 */
void nl80211_common_reg_change_event(enum nl80211_commands cmd_id,
				     struct regulatory_request *request)
{}

struct nl80211_mlme_event {};

static void nl80211_send_mlme_event(struct cfg80211_registered_device *rdev,
				    struct net_device *netdev,
				    const struct nl80211_mlme_event *event,
				    gfp_t gfp)
{}

void nl80211_send_rx_auth(struct cfg80211_registered_device *rdev,
			  struct net_device *netdev, const u8 *buf,
			  size_t len, gfp_t gfp)
{}

void nl80211_send_rx_assoc(struct cfg80211_registered_device *rdev,
			   struct net_device *netdev,
			   const struct cfg80211_rx_assoc_resp_data *data)
{}

void nl80211_send_deauth(struct cfg80211_registered_device *rdev,
			 struct net_device *netdev, const u8 *buf,
			 size_t len, bool reconnect, gfp_t gfp)
{}

void nl80211_send_disassoc(struct cfg80211_registered_device *rdev,
			   struct net_device *netdev, const u8 *buf,
			   size_t len, bool reconnect, gfp_t gfp)
{}

void cfg80211_rx_unprot_mlme_mgmt(struct net_device *dev, const u8 *buf,
				  size_t len)
{}
EXPORT_SYMBOL();

static void nl80211_send_mlme_timeout(struct cfg80211_registered_device *rdev,
				      struct net_device *netdev, int cmd,
				      const u8 *addr, gfp_t gfp)
{}

void nl80211_send_auth_timeout(struct cfg80211_registered_device *rdev,
			       struct net_device *netdev, const u8 *addr,
			       gfp_t gfp)
{}

void nl80211_send_assoc_timeout(struct cfg80211_registered_device *rdev,
				struct net_device *netdev, const u8 *addr,
				gfp_t gfp)
{}

void nl80211_send_connect_result(struct cfg80211_registered_device *rdev,
				 struct net_device *netdev,
				 struct cfg80211_connect_resp_params *cr,
				 gfp_t gfp)
{}

void nl80211_send_roamed(struct cfg80211_registered_device *rdev,
			 struct net_device *netdev,
			 struct cfg80211_roam_info *info, gfp_t gfp)
{}

void nl80211_send_port_authorized(struct cfg80211_registered_device *rdev,
				  struct net_device *netdev, const u8 *peer_addr,
				  const u8 *td_bitmap, u8 td_bitmap_len)
{}

void nl80211_send_disconnected(struct cfg80211_registered_device *rdev,
			       struct net_device *netdev, u16 reason,
			       const u8 *ie, size_t ie_len, bool from_ap)
{}

void cfg80211_links_removed(struct net_device *dev, u16 link_mask)
{}
EXPORT_SYMBOL();

void nl80211_send_ibss_bssid(struct cfg80211_registered_device *rdev,
			     struct net_device *netdev, const u8 *bssid,
			     gfp_t gfp)
{}

void cfg80211_notify_new_peer_candidate(struct net_device *dev, const u8 *addr,
					const u8 *ie, u8 ie_len,
					int sig_dbm, gfp_t gfp)
{}
EXPORT_SYMBOL();

void nl80211_michael_mic_failure(struct cfg80211_registered_device *rdev,
				 struct net_device *netdev, const u8 *addr,
				 enum nl80211_key_type key_type, int key_id,
				 const u8 *tsc, gfp_t gfp)
{}

void nl80211_send_beacon_hint_event(struct wiphy *wiphy,
				    struct ieee80211_channel *channel_before,
				    struct ieee80211_channel *channel_after)
{}

static void nl80211_send_remain_on_chan_event(
	int cmd, struct cfg80211_registered_device *rdev,
	struct wireless_dev *wdev, u64 cookie,
	struct ieee80211_channel *chan,
	unsigned int duration, gfp_t gfp)
{}

void cfg80211_assoc_comeback(struct net_device *netdev,
			     const u8 *ap_addr, u32 timeout)
{}
EXPORT_SYMBOL();

void cfg80211_ready_on_channel(struct wireless_dev *wdev, u64 cookie,
			       struct ieee80211_channel *chan,
			       unsigned int duration, gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_remain_on_channel_expired(struct wireless_dev *wdev, u64 cookie,
					struct ieee80211_channel *chan,
					gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_tx_mgmt_expired(struct wireless_dev *wdev, u64 cookie,
					struct ieee80211_channel *chan,
					gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_new_sta(struct net_device *dev, const u8 *mac_addr,
		      struct station_info *sinfo, gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_del_sta_sinfo(struct net_device *dev, const u8 *mac_addr,
			    struct station_info *sinfo, gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_conn_failed(struct net_device *dev, const u8 *mac_addr,
			  enum nl80211_connect_failed_reason reason,
			  gfp_t gfp)
{}
EXPORT_SYMBOL();

static bool __nl80211_unexpected_frame(struct net_device *dev, u8 cmd,
				       const u8 *addr, gfp_t gfp)
{}

bool cfg80211_rx_spurious_frame(struct net_device *dev,
				const u8 *addr, gfp_t gfp)
{}
EXPORT_SYMBOL();

bool cfg80211_rx_unexpected_4addr_frame(struct net_device *dev,
					const u8 *addr, gfp_t gfp)
{}
EXPORT_SYMBOL();

int nl80211_send_mgmt(struct cfg80211_registered_device *rdev,
		      struct wireless_dev *wdev, u32 nlportid,
		      struct cfg80211_rx_info *info, gfp_t gfp)
{}

static void nl80211_frame_tx_status(struct wireless_dev *wdev,
				    struct cfg80211_tx_status *status,
				    gfp_t gfp, enum nl80211_commands command)
{}

void cfg80211_control_port_tx_status(struct wireless_dev *wdev, u64 cookie,
				     const u8 *buf, size_t len, bool ack,
				     gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_mgmt_tx_status_ext(struct wireless_dev *wdev,
				 struct cfg80211_tx_status *status, gfp_t gfp)
{}
EXPORT_SYMBOL();

static int __nl80211_rx_control_port(struct net_device *dev,
				     struct sk_buff *skb,
				     bool unencrypted,
				     int link_id,
				     gfp_t gfp)
{}

bool cfg80211_rx_control_port(struct net_device *dev, struct sk_buff *skb,
			      bool unencrypted, int link_id)
{}
EXPORT_SYMBOL();

static struct sk_buff *cfg80211_prepare_cqm(struct net_device *dev,
					    const char *mac, gfp_t gfp)
{}

static void cfg80211_send_cqm(struct sk_buff *msg, gfp_t gfp)
{}

void cfg80211_cqm_rssi_notify(struct net_device *dev,
			      enum nl80211_cqm_rssi_threshold_event rssi_event,
			      s32 rssi_level, gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_cqm_rssi_notify_work(struct wiphy *wiphy, struct wiphy_work *work)
{}

void cfg80211_cqm_txe_notify(struct net_device *dev,
			     const u8 *peer, u32 num_packets,
			     u32 rate, u32 intvl, gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_cqm_pktloss_notify(struct net_device *dev,
				 const u8 *peer, u32 num_packets, gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_cqm_beacon_loss_notify(struct net_device *dev, gfp_t gfp)
{}
EXPORT_SYMBOL();

static void nl80211_gtk_rekey_notify(struct cfg80211_registered_device *rdev,
				     struct net_device *netdev, const u8 *bssid,
				     const u8 *replay_ctr, gfp_t gfp)
{}

void cfg80211_gtk_rekey_notify(struct net_device *dev, const u8 *bssid,
			       const u8 *replay_ctr, gfp_t gfp)
{}
EXPORT_SYMBOL();

static void
nl80211_pmksa_candidate_notify(struct cfg80211_registered_device *rdev,
			       struct net_device *netdev, int index,
			       const u8 *bssid, bool preauth, gfp_t gfp)
{}

void cfg80211_pmksa_candidate_notify(struct net_device *dev, int index,
				     const u8 *bssid, bool preauth, gfp_t gfp)
{}
EXPORT_SYMBOL();

static void nl80211_ch_switch_notify(struct cfg80211_registered_device *rdev,
				     struct net_device *netdev,
				     unsigned int link_id,
				     struct cfg80211_chan_def *chandef,
				     gfp_t gfp,
				     enum nl80211_commands notif,
				     u8 count, bool quiet)
{}

void cfg80211_ch_switch_notify(struct net_device *dev,
			       struct cfg80211_chan_def *chandef,
			       unsigned int link_id)
{}
EXPORT_SYMBOL();

void cfg80211_ch_switch_started_notify(struct net_device *dev,
				       struct cfg80211_chan_def *chandef,
				       unsigned int link_id, u8 count,
				       bool quiet)
{}
EXPORT_SYMBOL();

int cfg80211_bss_color_notify(struct net_device *dev,
			      enum nl80211_commands cmd, u8 count,
			      u64 color_bitmap, u8 link_id)
{}
EXPORT_SYMBOL();

void
nl80211_radar_notify(struct cfg80211_registered_device *rdev,
		     const struct cfg80211_chan_def *chandef,
		     enum nl80211_radar_event event,
		     struct net_device *netdev, gfp_t gfp)
{}

void cfg80211_sta_opmode_change_notify(struct net_device *dev, const u8 *mac,
				       struct sta_opmode_info *sta_opmode,
				       gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_probe_status(struct net_device *dev, const u8 *addr,
			   u64 cookie, bool acked, s32 ack_signal,
			   bool is_valid_ack_signal, gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_report_obss_beacon_khz(struct wiphy *wiphy, const u8 *frame,
				     size_t len, int freq, int sig_dbm)
{}
EXPORT_SYMBOL();

#ifdef CONFIG_PM
static int cfg80211_net_detect_results(struct sk_buff *msg,
				       struct cfg80211_wowlan_wakeup *wakeup)
{}

void cfg80211_report_wowlan_wakeup(struct wireless_dev *wdev,
				   struct cfg80211_wowlan_wakeup *wakeup,
				   gfp_t gfp)
{}
EXPORT_SYMBOL();
#endif

void cfg80211_tdls_oper_request(struct net_device *dev, const u8 *peer,
				enum nl80211_tdls_operation oper,
				u16 reason_code, gfp_t gfp)
{}
EXPORT_SYMBOL();

static int nl80211_netlink_notify(struct notifier_block * nb,
				  unsigned long state,
				  void *_notify)
{}

static struct notifier_block nl80211_netlink_notifier =;

void cfg80211_ft_event(struct net_device *netdev,
		       struct cfg80211_ft_event_params *ft_event)
{}
EXPORT_SYMBOL();

void cfg80211_crit_proto_stopped(struct wireless_dev *wdev, gfp_t gfp)
{}
EXPORT_SYMBOL();

void nl80211_send_ap_stopped(struct wireless_dev *wdev, unsigned int link_id)
{}

int cfg80211_external_auth_request(struct net_device *dev,
				   struct cfg80211_external_auth_params *params,
				   gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_update_owe_info_event(struct net_device *netdev,
				    struct cfg80211_update_owe_info *owe_info,
				    gfp_t gfp)
{}
EXPORT_SYMBOL();

void cfg80211_schedule_channels_check(struct wireless_dev *wdev)
{}
EXPORT_SYMBOL();

/* initialisation/exit functions */

int __init nl80211_init(void)
{}

void nl80211_exit(void)
{}