2017-11-01 15:07:57 +01:00
|
|
|
/* SPDX-License-Identifier: GPL-2.0 */
|
2007-04-23 12:20:05 -07:00
|
|
|
/*
|
|
|
|
|
* Wireless configuration interface internals.
|
|
|
|
|
*
|
2010-01-17 15:49:02 +01:00
|
|
|
* Copyright 2006-2010 Johannes Berg <johannes@sipsolutions.net>
|
2025-03-08 23:03:27 +02:00
|
|
|
* Copyright (C) 2018-2025 Intel Corporation
|
2007-04-23 12:20:05 -07:00
|
|
|
*/
|
|
|
|
|
#ifndef __NET_WIRELESS_CORE_H
|
|
|
|
|
#define __NET_WIRELESS_CORE_H
|
|
|
|
|
#include <linux/list.h>
|
|
|
|
|
#include <linux/netdevice.h>
|
2009-02-10 21:25:55 +01:00
|
|
|
#include <linux/rbtree.h>
|
2009-05-02 00:37:21 -04:00
|
|
|
#include <linux/debugfs.h>
|
2009-06-02 13:01:41 +02:00
|
|
|
#include <linux/rfkill.h>
|
|
|
|
|
#include <linux/workqueue.h>
|
2012-07-04 13:28:18 +02:00
|
|
|
#include <linux/rtnetlink.h>
|
2007-04-23 12:20:05 -07:00
|
|
|
#include <net/genetlink.h>
|
|
|
|
|
#include <net/cfg80211.h>
|
2008-11-12 14:22:02 -08:00
|
|
|
#include "reg.h"
|
2007-04-23 12:20:05 -07:00
|
|
|
|
2012-12-03 18:23:37 +01:00
|
|
|
|
|
|
|
|
#define WIPHY_IDX_INVALID -1
|
|
|
|
|
|
2025-06-09 21:35:19 +03:00
|
|
|
struct cfg80211_scan_request_int {
|
|
|
|
|
struct cfg80211_scan_info info;
|
|
|
|
|
bool notified;
|
|
|
|
|
/* must be last - variable members */
|
|
|
|
|
struct cfg80211_scan_request req;
|
|
|
|
|
};
|
|
|
|
|
|
2007-04-23 12:20:05 -07:00
|
|
|
struct cfg80211_registered_device {
|
2009-05-16 23:13:46 +01:00
|
|
|
const struct cfg80211_ops *ops;
|
2007-04-23 12:20:05 -07:00
|
|
|
struct list_head list;
|
|
|
|
|
|
2009-06-02 13:01:41 +02:00
|
|
|
/* rfkill support */
|
|
|
|
|
struct rfkill_ops rfkill_ops;
|
2019-08-30 14:24:44 +03:00
|
|
|
struct work_struct rfkill_block;
|
2009-06-02 13:01:41 +02:00
|
|
|
|
2008-11-12 14:22:02 -08:00
|
|
|
/* ISO / IEC 3166 alpha2 for which this device is receiving
|
|
|
|
|
* country IEs on, this can help disregard country IEs from APs
|
|
|
|
|
* on the same alpha2 quickly. The alpha2 may differ from
|
|
|
|
|
* cfg80211_regdomain's alpha2 when an intersection has occurred.
|
|
|
|
|
* If the AP is reconfigured this can also be used to tell us if
|
|
|
|
|
* the country on the country IE changed. */
|
|
|
|
|
char country_ie_alpha2[2];
|
|
|
|
|
|
2014-12-15 19:26:00 +02:00
|
|
|
/*
|
|
|
|
|
* the driver requests the regulatory core to set this regulatory
|
|
|
|
|
* domain as the wiphy's. Only used for %REGULATORY_WIPHY_SELF_MANAGED
|
|
|
|
|
* devices using the regulatory_set_wiphy_regd() API
|
|
|
|
|
*/
|
|
|
|
|
const struct ieee80211_regdomain *requested_regd;
|
|
|
|
|
|
2008-11-12 14:22:02 -08:00
|
|
|
/* If a Country IE has been received this tells us the environment
|
|
|
|
|
* which its telling us its in. This defaults to ENVIRON_ANY */
|
|
|
|
|
enum environment_cap env;
|
|
|
|
|
|
2007-04-23 12:20:05 -07:00
|
|
|
/* wiphy index, internal only */
|
2009-02-21 00:04:19 -05:00
|
|
|
int wiphy_idx;
|
2007-04-23 12:20:05 -07:00
|
|
|
|
2016-05-03 16:52:04 +03:00
|
|
|
/* protected by RTNL */
|
2012-06-15 14:33:17 +02:00
|
|
|
int devlist_generation, wdev_id;
|
2016-05-03 16:26:40 +03:00
|
|
|
int opencount;
|
2009-08-18 19:51:57 +02:00
|
|
|
wait_queue_head_t dev_wait;
|
2007-04-23 12:20:05 -07:00
|
|
|
|
2012-10-26 14:49:25 -07:00
|
|
|
struct list_head beacon_registrations;
|
|
|
|
|
spinlock_t beacon_registrations_lock;
|
2011-11-04 11:18:17 +01:00
|
|
|
|
2012-07-04 13:28:18 +02:00
|
|
|
/* protected by RTNL only */
|
2012-06-29 12:47:01 +02:00
|
|
|
int num_running_ifaces;
|
|
|
|
|
int num_running_monitor_ifaces;
|
2018-10-01 11:52:07 +02:00
|
|
|
u64 cookie_counter;
|
2012-06-29 12:47:01 +02:00
|
|
|
|
2009-02-10 21:25:55 +01:00
|
|
|
/* BSSes/scanning */
|
|
|
|
|
spinlock_t bss_lock;
|
|
|
|
|
struct list_head bss_list;
|
|
|
|
|
struct rb_root bss_tree;
|
|
|
|
|
u32 bss_generation;
|
2016-11-15 12:05:11 +01:00
|
|
|
u32 bss_entries;
|
2025-06-09 21:35:19 +03:00
|
|
|
struct cfg80211_scan_request_int *scan_req; /* protected by RTNL */
|
|
|
|
|
struct cfg80211_scan_request_int *int_scan_req;
|
2014-01-22 11:14:19 +02:00
|
|
|
struct sk_buff *scan_msg;
|
2017-04-21 13:05:00 +01:00
|
|
|
struct list_head sched_scan_req_list;
|
2018-06-18 17:11:14 +02:00
|
|
|
time64_t suspend_at;
|
2023-06-06 14:49:33 +02:00
|
|
|
struct wiphy_work scan_done_wk;
|
2009-02-10 21:25:55 +01:00
|
|
|
|
2013-11-13 13:37:47 +01:00
|
|
|
struct genl_info *cur_cmd_info;
|
2009-07-01 21:26:51 +02:00
|
|
|
|
2009-07-02 09:13:27 +02:00
|
|
|
struct work_struct conn_work;
|
2009-07-07 03:56:11 +02:00
|
|
|
struct work_struct event_work;
|
2009-07-02 09:13:27 +02:00
|
|
|
|
2013-02-08 18:16:19 +01:00
|
|
|
struct delayed_work dfs_update_channels_wk;
|
|
|
|
|
|
2021-11-29 14:11:24 +01:00
|
|
|
struct wireless_dev *background_radar_wdev;
|
|
|
|
|
struct cfg80211_chan_def background_radar_chandef;
|
|
|
|
|
struct delayed_work background_cac_done_wk;
|
|
|
|
|
struct work_struct background_cac_abort_wk;
|
2021-10-23 11:10:50 +02:00
|
|
|
|
2013-04-18 15:49:00 +02:00
|
|
|
/* netlink port which started critical protocol (0 means not started) */
|
|
|
|
|
u32 crit_proto_nlportid;
|
|
|
|
|
|
2013-06-28 11:51:26 -07:00
|
|
|
struct cfg80211_coalesce *coalesce;
|
|
|
|
|
|
2014-03-24 17:57:27 +01:00
|
|
|
struct work_struct destroy_work;
|
2023-06-06 14:49:32 +02:00
|
|
|
struct wiphy_work sched_scan_stop_wk;
|
2017-04-28 13:40:28 +01:00
|
|
|
struct work_struct sched_scan_res_wk;
|
2014-12-15 13:25:39 +02:00
|
|
|
|
2017-02-27 17:04:35 +05:30
|
|
|
struct cfg80211_chan_def radar_chandef;
|
|
|
|
|
struct work_struct propagate_radar_detect_wk;
|
|
|
|
|
|
|
|
|
|
struct cfg80211_chan_def cac_done_chandef;
|
|
|
|
|
struct work_struct propagate_cac_done_wk;
|
|
|
|
|
|
2020-06-04 12:04:20 +02:00
|
|
|
struct work_struct mgmt_registrations_update_wk;
|
2021-10-25 13:31:12 +02:00
|
|
|
/* lock for all wdev lists */
|
|
|
|
|
spinlock_t mgmt_registrations_lock;
|
2020-06-04 12:04:20 +02:00
|
|
|
|
2023-06-06 14:49:25 +02:00
|
|
|
struct work_struct wiphy_work;
|
|
|
|
|
struct list_head wiphy_work_list;
|
|
|
|
|
/* protects the list above */
|
|
|
|
|
spinlock_t wiphy_work_lock;
|
|
|
|
|
bool suspended;
|
|
|
|
|
|
2007-04-23 12:20:05 -07:00
|
|
|
/* must be last because of the way we do wiphy_priv(),
|
|
|
|
|
* and it should at least be aligned to NETDEV_ALIGN */
|
2012-12-28 12:22:02 +01:00
|
|
|
struct wiphy wiphy __aligned(NETDEV_ALIGN);
|
2007-04-23 12:20:05 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
static inline
|
2014-04-21 12:53:03 +08:00
|
|
|
struct cfg80211_registered_device *wiphy_to_rdev(struct wiphy *wiphy)
|
2007-04-23 12:20:05 -07:00
|
|
|
{
|
|
|
|
|
BUG_ON(!wiphy);
|
|
|
|
|
return container_of(wiphy, struct cfg80211_registered_device, wiphy);
|
|
|
|
|
}
|
|
|
|
|
|
2011-05-04 15:37:28 +02:00
|
|
|
static inline void
|
|
|
|
|
cfg80211_rdev_free_wowlan(struct cfg80211_registered_device *rdev)
|
|
|
|
|
{
|
2013-05-15 09:30:07 +02:00
|
|
|
#ifdef CONFIG_PM
|
2011-05-04 15:37:28 +02:00
|
|
|
int i;
|
|
|
|
|
|
2013-05-15 09:30:07 +02:00
|
|
|
if (!rdev->wiphy.wowlan_config)
|
2011-05-04 15:37:28 +02:00
|
|
|
return;
|
2013-05-15 09:30:07 +02:00
|
|
|
for (i = 0; i < rdev->wiphy.wowlan_config->n_patterns; i++)
|
|
|
|
|
kfree(rdev->wiphy.wowlan_config->patterns[i].mask);
|
|
|
|
|
kfree(rdev->wiphy.wowlan_config->patterns);
|
|
|
|
|
if (rdev->wiphy.wowlan_config->tcp &&
|
|
|
|
|
rdev->wiphy.wowlan_config->tcp->sock)
|
|
|
|
|
sock_release(rdev->wiphy.wowlan_config->tcp->sock);
|
|
|
|
|
kfree(rdev->wiphy.wowlan_config->tcp);
|
2014-09-17 11:55:28 +03:00
|
|
|
kfree(rdev->wiphy.wowlan_config->nd_config);
|
2013-05-15 09:30:07 +02:00
|
|
|
kfree(rdev->wiphy.wowlan_config);
|
|
|
|
|
#endif
|
2011-05-04 15:37:28 +02:00
|
|
|
}
|
2009-11-25 15:13:00 +01:00
|
|
|
|
2018-10-01 11:52:07 +02:00
|
|
|
static inline u64 cfg80211_assign_cookie(struct cfg80211_registered_device *rdev)
|
|
|
|
|
{
|
|
|
|
|
u64 r = ++rdev->cookie_counter;
|
|
|
|
|
|
|
|
|
|
if (WARN_ON(r == 0))
|
|
|
|
|
r = ++rdev->cookie_counter;
|
|
|
|
|
|
|
|
|
|
return r;
|
|
|
|
|
}
|
|
|
|
|
|
2009-11-25 15:13:00 +01:00
|
|
|
extern struct workqueue_struct *cfg80211_wq;
|
2009-07-07 03:56:12 +02:00
|
|
|
extern struct list_head cfg80211_rdev_list;
|
2009-08-07 16:17:38 +02:00
|
|
|
extern int cfg80211_rdev_list_generation;
|
2007-04-23 12:20:05 -07:00
|
|
|
|
2023-08-28 13:59:32 +02:00
|
|
|
/* This is constructed like this so it can be used in if/else */
|
|
|
|
|
static inline int for_each_rdev_check_rtnl(void)
|
|
|
|
|
{
|
|
|
|
|
ASSERT_RTNL();
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
#define for_each_rdev(rdev) \
|
|
|
|
|
if (for_each_rdev_check_rtnl()) {} else \
|
|
|
|
|
list_for_each_entry(rdev, &cfg80211_rdev_list, list)
|
|
|
|
|
|
2024-09-04 08:39:15 +05:30
|
|
|
enum bss_source_type {
|
|
|
|
|
BSS_SOURCE_DIRECT = 0,
|
|
|
|
|
BSS_SOURCE_MBSSID,
|
|
|
|
|
BSS_SOURCE_STA_PROFILE,
|
|
|
|
|
};
|
|
|
|
|
|
2009-02-10 21:25:55 +01:00
|
|
|
struct cfg80211_internal_bss {
|
|
|
|
|
struct list_head list;
|
2013-02-01 02:06:18 +01:00
|
|
|
struct list_head hidden_list;
|
2009-02-10 21:25:55 +01:00
|
|
|
struct rb_node rbn;
|
|
|
|
|
unsigned long ts;
|
2013-02-01 02:06:18 +01:00
|
|
|
unsigned long refcount;
|
2009-07-02 17:20:43 +02:00
|
|
|
atomic_t hold;
|
2009-03-22 21:57:28 +02:00
|
|
|
|
2016-07-05 17:10:13 +03:00
|
|
|
/* time at the start of the reception of the first octet of the
|
|
|
|
|
* timestamp field of the last beacon/probe received for this BSS.
|
|
|
|
|
* The time is the TSF of the BSS specified by %parent_bssid.
|
|
|
|
|
*/
|
|
|
|
|
u64 parent_tsf;
|
|
|
|
|
|
|
|
|
|
/* the BSS according to which %parent_tsf is set. This is set to
|
|
|
|
|
* the BSS that the interface that requested the scan was connected to
|
|
|
|
|
* when the beacon/probe was received.
|
|
|
|
|
*/
|
|
|
|
|
u8 parent_bssid[ETH_ALEN] __aligned(2);
|
|
|
|
|
|
2024-09-04 08:39:16 +05:30
|
|
|
enum bss_source_type bss_source;
|
|
|
|
|
|
2009-02-10 21:25:55 +01:00
|
|
|
/* must be last because of priv member */
|
|
|
|
|
struct cfg80211_bss pub;
|
|
|
|
|
};
|
|
|
|
|
|
2009-07-02 17:20:43 +02:00
|
|
|
static inline struct cfg80211_internal_bss *bss_from_pub(struct cfg80211_bss *pub)
|
|
|
|
|
{
|
|
|
|
|
return container_of(pub, struct cfg80211_internal_bss, pub);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static inline void cfg80211_hold_bss(struct cfg80211_internal_bss *bss)
|
|
|
|
|
{
|
|
|
|
|
atomic_inc(&bss->hold);
|
2019-01-21 12:25:59 +02:00
|
|
|
if (bss->pub.transmitted_bss) {
|
|
|
|
|
bss = container_of(bss->pub.transmitted_bss,
|
2019-01-21 12:22:21 +02:00
|
|
|
struct cfg80211_internal_bss, pub);
|
|
|
|
|
atomic_inc(&bss->hold);
|
|
|
|
|
}
|
2009-07-02 17:20:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static inline void cfg80211_unhold_bss(struct cfg80211_internal_bss *bss)
|
|
|
|
|
{
|
|
|
|
|
int r = atomic_dec_return(&bss->hold);
|
|
|
|
|
WARN_ON(r < 0);
|
2019-01-21 12:25:59 +02:00
|
|
|
if (bss->pub.transmitted_bss) {
|
|
|
|
|
bss = container_of(bss->pub.transmitted_bss,
|
2019-01-21 12:22:21 +02:00
|
|
|
struct cfg80211_internal_bss, pub);
|
|
|
|
|
r = atomic_dec_return(&bss->hold);
|
|
|
|
|
WARN_ON(r < 0);
|
|
|
|
|
}
|
2009-07-02 17:20:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2009-07-07 03:56:12 +02:00
|
|
|
struct cfg80211_registered_device *cfg80211_rdev_by_wiphy_idx(int wiphy_idx);
|
2009-02-21 00:04:26 -05:00
|
|
|
int get_wiphy_idx(struct wiphy *wiphy);
|
|
|
|
|
|
|
|
|
|
struct wiphy *wiphy_idx_to_wiphy(int wiphy_idx);
|
|
|
|
|
|
2009-07-14 00:33:35 +02:00
|
|
|
int cfg80211_switch_netns(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net *net);
|
2007-09-20 13:09:35 -04:00
|
|
|
|
2020-10-09 13:58:22 +02:00
|
|
|
void cfg80211_init_wdev(struct wireless_dev *wdev);
|
|
|
|
|
void cfg80211_register_wdev(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev);
|
2018-09-13 14:12:03 +02:00
|
|
|
|
2012-06-29 12:47:01 +02:00
|
|
|
static inline bool cfg80211_has_monitors_only(struct cfg80211_registered_device *rdev)
|
|
|
|
|
{
|
2021-01-22 16:19:43 +01:00
|
|
|
lockdep_assert_held(&rdev->wiphy.mtx);
|
2012-06-29 12:47:01 +02:00
|
|
|
|
|
|
|
|
return rdev->num_running_ifaces == rdev->num_running_monitor_ifaces &&
|
|
|
|
|
rdev->num_running_ifaces > 0;
|
|
|
|
|
}
|
|
|
|
|
|
2009-07-07 03:56:11 +02:00
|
|
|
enum cfg80211_event_type {
|
|
|
|
|
EVENT_CONNECT_RESULT,
|
|
|
|
|
EVENT_ROAMED,
|
|
|
|
|
EVENT_DISCONNECTED,
|
|
|
|
|
EVENT_IBSS_JOINED,
|
2014-04-09 15:11:01 +02:00
|
|
|
EVENT_STOPPED,
|
2017-09-29 14:21:49 +02:00
|
|
|
EVENT_PORT_AUTHORIZED,
|
2009-07-07 03:56:11 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
struct cfg80211_event {
|
|
|
|
|
struct list_head list;
|
|
|
|
|
enum cfg80211_event_type type;
|
|
|
|
|
|
|
|
|
|
union {
|
2017-03-31 00:22:33 +03:00
|
|
|
struct cfg80211_connect_resp_params cr;
|
2017-04-26 10:58:49 +03:00
|
|
|
struct cfg80211_roam_info rm;
|
2009-07-07 03:56:11 +02:00
|
|
|
struct {
|
|
|
|
|
const u8 *ie;
|
|
|
|
|
size_t ie_len;
|
|
|
|
|
u16 reason;
|
2015-05-22 16:22:20 +02:00
|
|
|
bool locally_generated;
|
2009-07-07 03:56:11 +02:00
|
|
|
} dc;
|
|
|
|
|
struct {
|
|
|
|
|
u8 bssid[ETH_ALEN];
|
2014-01-29 17:53:43 +01:00
|
|
|
struct ieee80211_channel *channel;
|
2009-07-07 03:56:11 +02:00
|
|
|
} ij;
|
2017-09-29 14:21:49 +02:00
|
|
|
struct {
|
2023-09-26 16:02:22 +05:30
|
|
|
u8 peer_addr[ETH_ALEN];
|
2022-09-07 18:14:48 +05:30
|
|
|
const u8 *td_bitmap;
|
|
|
|
|
u8 td_bitmap_len;
|
2017-09-29 14:21:49 +02:00
|
|
|
} pa;
|
2009-07-07 03:56:11 +02:00
|
|
|
};
|
2025-11-27 15:41:23 +05:30
|
|
|
int link_id;
|
2009-07-07 03:56:11 +02:00
|
|
|
};
|
|
|
|
|
|
2009-07-08 14:22:54 +02:00
|
|
|
struct cfg80211_cached_keys {
|
2023-01-16 15:24:11 +01:00
|
|
|
struct key_params params[4];
|
|
|
|
|
u8 data[4][WLAN_KEY_LEN_WEP104];
|
2016-09-13 16:39:38 +02:00
|
|
|
int def;
|
2009-07-08 14:22:54 +02:00
|
|
|
};
|
|
|
|
|
|
2012-10-26 14:49:25 -07:00
|
|
|
struct cfg80211_beacon_registration {
|
|
|
|
|
struct list_head list;
|
|
|
|
|
u32 nlportid;
|
|
|
|
|
};
|
2009-07-07 03:56:11 +02:00
|
|
|
|
2017-02-10 10:02:31 +01:00
|
|
|
struct cfg80211_cqm_config {
|
2023-08-16 15:38:04 +02:00
|
|
|
struct rcu_head rcu_head;
|
2017-02-10 10:02:31 +01:00
|
|
|
u32 rssi_hyst;
|
|
|
|
|
s32 last_rssi_event_value;
|
2023-08-16 15:38:04 +02:00
|
|
|
enum nl80211_cqm_rssi_threshold_event last_rssi_event_type;
|
2023-11-06 23:17:16 +01:00
|
|
|
bool use_range_api;
|
2017-02-10 10:02:31 +01:00
|
|
|
int n_rssi_thresholds;
|
2023-08-17 14:15:24 -07:00
|
|
|
s32 rssi_thresholds[] __counted_by(n_rssi_thresholds);
|
2017-02-10 10:02:31 +01:00
|
|
|
};
|
|
|
|
|
|
2023-08-16 15:38:04 +02:00
|
|
|
void cfg80211_cqm_rssi_notify_work(struct wiphy *wiphy,
|
|
|
|
|
struct wiphy_work *work);
|
|
|
|
|
|
2014-03-24 17:57:27 +01:00
|
|
|
void cfg80211_destroy_ifaces(struct cfg80211_registered_device *rdev);
|
|
|
|
|
|
2026-03-18 14:39:17 +02:00
|
|
|
void cfg80211_close_dependents(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev);
|
|
|
|
|
|
2007-04-23 12:20:05 -07:00
|
|
|
/* free object */
|
2013-10-18 13:48:25 -07:00
|
|
|
void cfg80211_dev_free(struct cfg80211_registered_device *rdev);
|
2007-04-23 12:20:05 -07:00
|
|
|
|
2013-10-18 13:48:25 -07:00
|
|
|
int cfg80211_dev_rename(struct cfg80211_registered_device *rdev,
|
|
|
|
|
char *newname);
|
2007-09-20 13:09:35 -04:00
|
|
|
|
2008-01-24 19:38:38 +01:00
|
|
|
void ieee80211_set_bitrate_flags(struct wiphy *wiphy);
|
|
|
|
|
|
2014-04-21 12:53:02 +08:00
|
|
|
void cfg80211_bss_expire(struct cfg80211_registered_device *rdev);
|
|
|
|
|
void cfg80211_bss_age(struct cfg80211_registered_device *rdev,
|
2009-02-11 17:14:43 -05:00
|
|
|
unsigned long age_secs);
|
2019-07-26 16:39:34 +00:00
|
|
|
void cfg80211_update_assoc_bss_entry(struct wireless_dev *wdev,
|
2022-04-14 16:50:57 +02:00
|
|
|
unsigned int link,
|
2019-07-26 16:39:34 +00:00
|
|
|
struct ieee80211_channel *channel);
|
2009-02-10 21:25:55 +01:00
|
|
|
|
2009-04-19 21:24:32 +02:00
|
|
|
/* IBSS */
|
2018-03-26 12:52:45 -05:00
|
|
|
int __cfg80211_join_ibss(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev,
|
|
|
|
|
struct cfg80211_ibss_params *params,
|
|
|
|
|
struct cfg80211_cached_keys *connkeys);
|
2009-04-20 18:43:46 +02:00
|
|
|
void cfg80211_clear_ibss(struct net_device *dev, bool nowext);
|
2009-04-19 21:24:32 +02:00
|
|
|
int cfg80211_leave_ibss(struct cfg80211_registered_device *rdev,
|
2009-04-20 18:43:46 +02:00
|
|
|
struct net_device *dev, bool nowext);
|
2014-01-29 17:53:43 +01:00
|
|
|
void __cfg80211_ibss_joined(struct net_device *dev, const u8 *bssid,
|
|
|
|
|
struct ieee80211_channel *channel);
|
2009-07-08 14:22:54 +02:00
|
|
|
int cfg80211_ibss_wext_join(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev);
|
2009-04-19 21:24:32 +02:00
|
|
|
|
2010-12-03 09:20:44 +01:00
|
|
|
/* mesh */
|
|
|
|
|
extern const struct mesh_config default_mesh_config;
|
2010-12-16 17:37:49 -08:00
|
|
|
extern const struct mesh_setup default_mesh_setup;
|
2010-12-03 09:20:44 +01:00
|
|
|
int __cfg80211_join_mesh(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev,
|
2012-05-16 23:50:20 +02:00
|
|
|
struct mesh_setup *setup,
|
2010-12-03 09:20:44 +01:00
|
|
|
const struct mesh_config *conf);
|
|
|
|
|
int cfg80211_leave_mesh(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev);
|
2012-11-08 21:25:48 +01:00
|
|
|
int cfg80211_set_mesh_channel(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev,
|
|
|
|
|
struct cfg80211_chan_def *chandef);
|
2010-12-03 09:20:44 +01:00
|
|
|
|
2014-11-03 10:33:18 +01:00
|
|
|
/* OCB */
|
|
|
|
|
int cfg80211_join_ocb(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev,
|
|
|
|
|
struct ocb_setup *setup);
|
|
|
|
|
int cfg80211_leave_ocb(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev);
|
|
|
|
|
|
2012-06-29 12:46:56 +02:00
|
|
|
/* AP */
|
|
|
|
|
int cfg80211_stop_ap(struct cfg80211_registered_device *rdev,
|
2022-04-14 16:50:57 +02:00
|
|
|
struct net_device *dev, int link,
|
|
|
|
|
bool notify);
|
2012-06-29 12:46:56 +02:00
|
|
|
|
2009-07-02 17:20:43 +02:00
|
|
|
/* MLME */
|
|
|
|
|
int cfg80211_mlme_auth(struct cfg80211_registered_device *rdev,
|
2013-05-15 17:44:01 +02:00
|
|
|
struct net_device *dev,
|
2022-06-01 22:42:28 +02:00
|
|
|
struct cfg80211_auth_request *req);
|
2009-07-02 17:20:43 +02:00
|
|
|
int cfg80211_mlme_assoc(struct cfg80211_registered_device *rdev,
|
2013-02-21 20:09:09 +01:00
|
|
|
struct net_device *dev,
|
2024-01-02 21:35:44 +02:00
|
|
|
struct cfg80211_assoc_request *req,
|
|
|
|
|
struct netlink_ext_ack *extack);
|
2009-07-02 17:20:43 +02:00
|
|
|
int cfg80211_mlme_deauth(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev, const u8 *bssid,
|
2010-04-04 09:37:19 +03:00
|
|
|
const u8 *ie, int ie_len, u16 reason,
|
|
|
|
|
bool local_state_change);
|
2009-07-02 17:20:43 +02:00
|
|
|
int cfg80211_mlme_disassoc(struct cfg80211_registered_device *rdev,
|
2022-06-27 16:19:18 +02:00
|
|
|
struct net_device *dev, const u8 *ap_addr,
|
2010-04-04 09:37:19 +03:00
|
|
|
const u8 *ie, int ie_len, u16 reason,
|
|
|
|
|
bool local_state_change);
|
2009-07-02 17:20:43 +02:00
|
|
|
void cfg80211_mlme_down(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev);
|
2010-08-12 15:38:38 +02:00
|
|
|
int cfg80211_mlme_register_mgmt(struct wireless_dev *wdev, u32 snd_pid,
|
|
|
|
|
u16 frame_type, const u8 *match_data,
|
2020-04-17 12:40:15 +02:00
|
|
|
int match_len, bool multicast_rx,
|
|
|
|
|
struct netlink_ext_ack *extack);
|
2020-04-17 12:43:01 +02:00
|
|
|
void cfg80211_mgmt_registrations_update_wk(struct work_struct *wk);
|
2010-08-12 15:38:38 +02:00
|
|
|
void cfg80211_mlme_unregister_socket(struct wireless_dev *wdev, u32 nlpid);
|
|
|
|
|
void cfg80211_mlme_purge_registrations(struct wireless_dev *wdev);
|
|
|
|
|
int cfg80211_mlme_mgmt_tx(struct cfg80211_registered_device *rdev,
|
2012-06-15 15:30:18 +02:00
|
|
|
struct wireless_dev *wdev,
|
2013-11-18 19:06:49 +02:00
|
|
|
struct cfg80211_mgmt_tx_params *params,
|
|
|
|
|
u64 *cookie);
|
2011-11-18 11:31:59 -08:00
|
|
|
void cfg80211_oper_and_ht_capa(struct ieee80211_ht_cap *ht_capa,
|
|
|
|
|
const struct ieee80211_ht_cap *ht_capa_mask);
|
2013-02-21 17:36:01 +01:00
|
|
|
void cfg80211_oper_and_vht_capa(struct ieee80211_vht_cap *vht_capa,
|
|
|
|
|
const struct ieee80211_vht_cap *vht_capa_mask);
|
2009-07-02 17:20:43 +02:00
|
|
|
|
2013-05-16 00:55:45 +02:00
|
|
|
/* SME events */
|
2009-07-01 21:26:54 +02:00
|
|
|
int cfg80211_connect(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev,
|
2009-07-08 14:22:54 +02:00
|
|
|
struct cfg80211_connect_params *connect,
|
2013-05-15 17:44:01 +02:00
|
|
|
struct cfg80211_cached_keys *connkeys,
|
|
|
|
|
const u8 *prev_bssid);
|
2017-03-31 00:22:33 +03:00
|
|
|
void __cfg80211_connect_result(struct net_device *dev,
|
|
|
|
|
struct cfg80211_connect_resp_params *params,
|
|
|
|
|
bool wextev);
|
2013-05-16 00:55:45 +02:00
|
|
|
void __cfg80211_disconnected(struct net_device *dev, const u8 *ie,
|
|
|
|
|
size_t ie_len, u16 reason, bool from_ap);
|
2009-07-01 21:26:54 +02:00
|
|
|
int cfg80211_disconnect(struct cfg80211_registered_device *rdev,
|
2009-07-01 21:26:56 +02:00
|
|
|
struct net_device *dev, u16 reason,
|
|
|
|
|
bool wextev);
|
2011-05-16 19:40:15 +03:00
|
|
|
void __cfg80211_roamed(struct wireless_dev *wdev,
|
2017-04-26 10:58:49 +03:00
|
|
|
struct cfg80211_roam_info *info);
|
2023-09-26 16:02:22 +05:30
|
|
|
void __cfg80211_port_authorized(struct wireless_dev *wdev, const u8 *peer_addr,
|
2022-09-07 18:14:48 +05:30
|
|
|
const u8 *td_bitmap, u8 td_bitmap_len);
|
2009-07-08 14:22:54 +02:00
|
|
|
int cfg80211_mgd_wext_connect(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev);
|
2017-01-06 16:33:43 -05:00
|
|
|
void cfg80211_autodisconnect_wk(struct work_struct *work);
|
2009-07-01 21:26:54 +02:00
|
|
|
|
2013-05-16 00:55:45 +02:00
|
|
|
/* SME implementation */
|
2009-07-02 09:13:27 +02:00
|
|
|
void cfg80211_conn_work(struct work_struct *work);
|
2013-05-16 00:55:45 +02:00
|
|
|
void cfg80211_sme_scan_done(struct net_device *dev);
|
|
|
|
|
bool cfg80211_sme_rx_assoc_resp(struct wireless_dev *wdev, u16 status);
|
|
|
|
|
void cfg80211_sme_rx_auth(struct wireless_dev *wdev, const u8 *buf, size_t len);
|
|
|
|
|
void cfg80211_sme_disassoc(struct wireless_dev *wdev);
|
|
|
|
|
void cfg80211_sme_deauth(struct wireless_dev *wdev);
|
|
|
|
|
void cfg80211_sme_auth_timeout(struct wireless_dev *wdev);
|
|
|
|
|
void cfg80211_sme_assoc_timeout(struct wireless_dev *wdev);
|
2016-12-08 17:22:09 +01:00
|
|
|
void cfg80211_sme_abandon_assoc(struct wireless_dev *wdev);
|
2009-07-02 09:13:27 +02:00
|
|
|
|
2009-05-11 13:54:58 +02:00
|
|
|
/* internal helpers */
|
2011-09-21 18:14:56 +03:00
|
|
|
bool cfg80211_supported_cipher_suite(struct wiphy *wiphy, u32 cipher);
|
2020-12-05 03:28:25 +05:30
|
|
|
bool cfg80211_valid_key_idx(struct cfg80211_registered_device *rdev,
|
|
|
|
|
int key_idx, bool pairwise);
|
2009-07-08 14:22:54 +02:00
|
|
|
int cfg80211_validate_key_settings(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct key_params *params, int key_idx,
|
2010-10-05 19:39:30 +02:00
|
|
|
bool pairwise, const u8 *mac_addr);
|
2023-06-06 14:49:33 +02:00
|
|
|
void __cfg80211_scan_done(struct wiphy *wiphy, struct wiphy_work *wk);
|
2014-01-22 11:14:19 +02:00
|
|
|
void ___cfg80211_scan_done(struct cfg80211_registered_device *rdev,
|
|
|
|
|
bool send_message);
|
2017-04-21 13:05:00 +01:00
|
|
|
void cfg80211_add_sched_scan_req(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct cfg80211_sched_scan_request *req);
|
|
|
|
|
int cfg80211_sched_scan_req_possible(struct cfg80211_registered_device *rdev,
|
|
|
|
|
bool want_multi);
|
2017-04-28 13:40:28 +01:00
|
|
|
void cfg80211_sched_scan_results_wk(struct work_struct *work);
|
2017-04-21 13:05:00 +01:00
|
|
|
int cfg80211_stop_sched_scan_req(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct cfg80211_sched_scan_request *req,
|
|
|
|
|
bool driver_initiated);
|
2011-05-11 17:09:35 +03:00
|
|
|
int __cfg80211_stop_sched_scan(struct cfg80211_registered_device *rdev,
|
2017-04-21 13:05:00 +01:00
|
|
|
u64 reqid, bool driver_initiated);
|
2009-07-08 14:22:54 +02:00
|
|
|
void cfg80211_upload_connect_keys(struct wireless_dev *wdev);
|
2009-08-21 14:51:05 +02:00
|
|
|
int cfg80211_change_iface(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev, enum nl80211_iftype ntype,
|
2017-04-12 11:23:28 +02:00
|
|
|
struct vif_params *params);
|
2009-08-21 14:51:05 +02:00
|
|
|
void cfg80211_process_rdev_events(struct cfg80211_registered_device *rdev);
|
2023-08-28 13:59:33 +02:00
|
|
|
void cfg80211_process_wiphy_works(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wiphy_work *end);
|
2012-08-02 18:41:48 +01:00
|
|
|
void cfg80211_process_wdev_events(struct wireless_dev *wdev);
|
2009-05-11 13:54:58 +02:00
|
|
|
|
2017-01-04 18:58:30 +01:00
|
|
|
bool cfg80211_does_bw_fit_range(const struct ieee80211_freq_range *freq_range,
|
|
|
|
|
u32 center_freq_khz, u32 bw_khz);
|
|
|
|
|
|
2020-09-18 11:33:13 +02:00
|
|
|
int cfg80211_scan(struct cfg80211_registered_device *rdev);
|
|
|
|
|
|
2019-02-01 11:09:54 +01:00
|
|
|
extern struct work_struct cfg80211_disconnect_work;
|
|
|
|
|
|
2023-12-11 09:05:20 +02:00
|
|
|
#define NL80211_BSS_USE_FOR_ALL (NL80211_BSS_USE_FOR_NORMAL | \
|
|
|
|
|
NL80211_BSS_USE_FOR_MLD_LINK)
|
|
|
|
|
|
2013-02-08 18:16:19 +01:00
|
|
|
void cfg80211_set_dfs_state(struct wiphy *wiphy,
|
|
|
|
|
const struct cfg80211_chan_def *chandef,
|
|
|
|
|
enum nl80211_dfs_state dfs_state);
|
|
|
|
|
|
2026-02-06 18:15:49 +01:00
|
|
|
void cfg80211_set_cac_state(struct wiphy *wiphy,
|
|
|
|
|
const struct cfg80211_chan_def *chandef,
|
|
|
|
|
bool cac_ongoing);
|
|
|
|
|
|
2013-02-08 18:16:19 +01:00
|
|
|
void cfg80211_dfs_channels_update_work(struct work_struct *work);
|
|
|
|
|
|
2017-02-27 17:04:33 +05:30
|
|
|
void cfg80211_sched_dfs_chan_update(struct cfg80211_registered_device *rdev);
|
|
|
|
|
|
2021-10-23 11:10:50 +02:00
|
|
|
int
|
2021-11-29 14:11:24 +01:00
|
|
|
cfg80211_start_background_radar_detection(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev,
|
|
|
|
|
struct cfg80211_chan_def *chandef);
|
2021-10-23 11:10:50 +02:00
|
|
|
|
2025-11-21 17:40:21 +01:00
|
|
|
void cfg80211_stop_radar_detection(struct wireless_dev *wdev);
|
2021-11-29 14:11:24 +01:00
|
|
|
void cfg80211_stop_background_radar_detection(struct wireless_dev *wdev);
|
2021-10-23 11:10:50 +02:00
|
|
|
|
2021-11-29 14:11:24 +01:00
|
|
|
void cfg80211_background_cac_done_wk(struct work_struct *work);
|
2021-10-27 11:03:42 +02:00
|
|
|
|
2021-11-29 14:11:24 +01:00
|
|
|
void cfg80211_background_cac_abort_wk(struct work_struct *work);
|
2021-10-23 11:10:50 +02:00
|
|
|
|
2017-02-27 17:04:33 +05:30
|
|
|
bool cfg80211_any_wiphy_oper_chan(struct wiphy *wiphy,
|
|
|
|
|
struct ieee80211_channel *chan);
|
|
|
|
|
|
|
|
|
|
bool cfg80211_beaconing_iface_active(struct wireless_dev *wdev);
|
|
|
|
|
|
|
|
|
|
bool cfg80211_is_sub_chan(struct cfg80211_chan_def *chandef,
|
2022-04-14 16:50:57 +02:00
|
|
|
struct ieee80211_channel *chan,
|
|
|
|
|
bool primary_only);
|
|
|
|
|
bool cfg80211_wdev_on_sub_chan(struct wireless_dev *wdev,
|
|
|
|
|
struct ieee80211_channel *chan,
|
|
|
|
|
bool primary_only);
|
2024-02-06 16:54:08 +02:00
|
|
|
bool _cfg80211_chandef_usable(struct wiphy *wiphy,
|
|
|
|
|
const struct cfg80211_chan_def *chandef,
|
2024-05-23 12:09:46 +02:00
|
|
|
u32 prohibited_flags,
|
|
|
|
|
u32 permitting_flags);
|
2017-02-27 17:04:33 +05:30
|
|
|
|
2013-02-08 18:16:19 +01:00
|
|
|
static inline unsigned int elapsed_jiffies_msecs(unsigned long start)
|
|
|
|
|
{
|
|
|
|
|
unsigned long end = jiffies;
|
|
|
|
|
|
|
|
|
|
if (end >= start)
|
|
|
|
|
return jiffies_to_msecs(end - start);
|
|
|
|
|
|
2014-06-17 13:07:02 +03:00
|
|
|
return jiffies_to_msecs(end + (ULONG_MAX - start) + 1);
|
2013-02-08 18:16:19 +01:00
|
|
|
}
|
|
|
|
|
|
2012-06-06 08:18:22 +02:00
|
|
|
int cfg80211_set_monitor_channel(struct cfg80211_registered_device *rdev,
|
2024-10-09 10:25:47 +02:00
|
|
|
struct net_device *dev,
|
2012-11-08 21:25:48 +01:00
|
|
|
struct cfg80211_chan_def *chandef);
|
2009-08-07 17:22:35 +02:00
|
|
|
|
2011-07-18 18:08:35 +02:00
|
|
|
int ieee80211_get_ratemask(struct ieee80211_supported_band *sband,
|
|
|
|
|
const u8 *rates, unsigned int n_rates,
|
|
|
|
|
u32 *mask);
|
|
|
|
|
|
2011-05-09 18:41:15 +02:00
|
|
|
int cfg80211_validate_beacon_int(struct cfg80211_registered_device *rdev,
|
2016-10-12 18:26:51 +05:30
|
|
|
enum nl80211_iftype iftype, u32 beacon_int);
|
2011-05-09 18:41:15 +02:00
|
|
|
|
2012-06-29 12:47:01 +02:00
|
|
|
void cfg80211_update_iface_num(struct cfg80211_registered_device *rdev,
|
|
|
|
|
enum nl80211_iftype iftype, int num);
|
|
|
|
|
|
2026-03-18 14:39:17 +02:00
|
|
|
void cfg80211_leave_locked(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev, int link_id);
|
|
|
|
|
|
2013-02-28 10:55:25 +01:00
|
|
|
void cfg80211_leave(struct cfg80211_registered_device *rdev,
|
2025-11-27 15:41:23 +05:30
|
|
|
struct wireless_dev *wdev,
|
|
|
|
|
int link_id);
|
2013-02-28 10:55:25 +01:00
|
|
|
|
2013-03-19 15:04:07 +01:00
|
|
|
void cfg80211_stop_p2p_device(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev);
|
|
|
|
|
|
2016-09-20 17:31:13 +03:00
|
|
|
void cfg80211_stop_nan(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev);
|
|
|
|
|
|
2026-03-18 14:39:15 +02:00
|
|
|
int cfg80211_nan_set_local_schedule(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev,
|
|
|
|
|
struct cfg80211_nan_local_sched *sched);
|
|
|
|
|
|
2019-05-01 18:25:24 +05:30
|
|
|
struct cfg80211_internal_bss *
|
|
|
|
|
cfg80211_bss_update(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct cfg80211_internal_bss *tmp,
|
|
|
|
|
bool signal_valid, unsigned long ts);
|
2024-05-23 12:09:47 +02:00
|
|
|
|
|
|
|
|
enum ieee80211_ap_reg_power
|
2025-11-10 14:10:30 +02:00
|
|
|
cfg80211_get_6ghz_power_type(const u8 *elems, size_t elems_len,
|
|
|
|
|
u32 client_flags);
|
2024-05-23 12:09:47 +02:00
|
|
|
|
2009-08-21 12:23:49 +02:00
|
|
|
#ifdef CONFIG_CFG80211_DEVELOPER_WARNINGS
|
|
|
|
|
#define CFG80211_DEV_WARN_ON(cond) WARN_ON(cond)
|
|
|
|
|
#else
|
|
|
|
|
/*
|
|
|
|
|
* Trick to enable using it as a condition,
|
|
|
|
|
* and also not give a warning when it's
|
|
|
|
|
* not used that way.
|
|
|
|
|
*/
|
|
|
|
|
#define CFG80211_DEV_WARN_ON(cond) ({bool __r = (cond); __r; })
|
|
|
|
|
#endif
|
|
|
|
|
|
2018-09-10 13:29:12 +02:00
|
|
|
void cfg80211_release_pmsr(struct wireless_dev *wdev, u32 portid);
|
|
|
|
|
void cfg80211_pmsr_wdev_down(struct wireless_dev *wdev);
|
|
|
|
|
void cfg80211_pmsr_free_wk(struct work_struct *work);
|
|
|
|
|
|
2022-07-06 09:57:42 +02:00
|
|
|
void cfg80211_remove_link(struct wireless_dev *wdev, unsigned int link_id);
|
|
|
|
|
void cfg80211_remove_links(struct wireless_dev *wdev);
|
|
|
|
|
int cfg80211_remove_virtual_intf(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct wireless_dev *wdev);
|
2023-03-17 19:51:53 +05:30
|
|
|
void cfg80211_wdev_release_link_bsses(struct wireless_dev *wdev, u16 link_mask);
|
2022-07-06 09:57:42 +02:00
|
|
|
|
2025-01-02 16:19:55 +02:00
|
|
|
int cfg80211_assoc_ml_reconf(struct cfg80211_registered_device *rdev,
|
|
|
|
|
struct net_device *dev,
|
2025-03-08 23:03:27 +02:00
|
|
|
struct cfg80211_ml_reconf_req *req);
|
|
|
|
|
|
2024-01-29 22:09:19 +01:00
|
|
|
/**
|
|
|
|
|
* struct cfg80211_colocated_ap - colocated AP information
|
|
|
|
|
*
|
|
|
|
|
* @list: linked list to all colocated APs
|
|
|
|
|
* @bssid: BSSID of the reported AP
|
|
|
|
|
* @ssid: SSID of the reported AP
|
|
|
|
|
* @ssid_len: length of the ssid
|
|
|
|
|
* @center_freq: frequency the reported AP is on
|
|
|
|
|
* @unsolicited_probe: the reported AP is part of an ESS, where all the APs
|
|
|
|
|
* that operate in the same channel as the reported AP and that might be
|
|
|
|
|
* detected by a STA receiving this frame, are transmitting unsolicited
|
|
|
|
|
* Probe Response frames every 20 TUs
|
|
|
|
|
* @oct_recommended: OCT is recommended to exchange MMPDUs with the reported AP
|
|
|
|
|
* @same_ssid: the reported AP has the same SSID as the reporting AP
|
|
|
|
|
* @multi_bss: the reported AP is part of a multiple BSSID set
|
|
|
|
|
* @transmitted_bssid: the reported AP is the transmitting BSSID
|
|
|
|
|
* @colocated_ess: all the APs that share the same ESS as the reported AP are
|
|
|
|
|
* colocated and can be discovered via legacy bands.
|
|
|
|
|
* @short_ssid_valid: short_ssid is valid and can be used
|
|
|
|
|
* @short_ssid: the short SSID for this SSID
|
|
|
|
|
* @psd_20: The 20MHz PSD EIRP of the primary 20MHz channel for the reported AP
|
|
|
|
|
*/
|
|
|
|
|
struct cfg80211_colocated_ap {
|
|
|
|
|
struct list_head list;
|
|
|
|
|
u8 bssid[ETH_ALEN];
|
|
|
|
|
u8 ssid[IEEE80211_MAX_SSID_LEN];
|
|
|
|
|
size_t ssid_len;
|
|
|
|
|
u32 short_ssid;
|
|
|
|
|
u32 center_freq;
|
|
|
|
|
u8 unsolicited_probe:1,
|
|
|
|
|
oct_recommended:1,
|
|
|
|
|
same_ssid:1,
|
|
|
|
|
multi_bss:1,
|
|
|
|
|
transmitted_bssid:1,
|
|
|
|
|
colocated_ess:1,
|
|
|
|
|
short_ssid_valid:1;
|
|
|
|
|
s8 psd_20;
|
|
|
|
|
};
|
|
|
|
|
|
2023-12-20 16:19:52 +01:00
|
|
|
#if IS_ENABLED(CONFIG_CFG80211_KUNIT_TEST)
|
|
|
|
|
#define EXPORT_SYMBOL_IF_CFG80211_KUNIT(sym) EXPORT_SYMBOL_IF_KUNIT(sym)
|
|
|
|
|
#define VISIBLE_IF_CFG80211_KUNIT
|
2024-01-29 22:09:19 +01:00
|
|
|
void cfg80211_free_coloc_ap_list(struct list_head *coloc_ap_list);
|
|
|
|
|
|
|
|
|
|
int cfg80211_parse_colocated_ap(const struct cfg80211_bss_ies *ies,
|
|
|
|
|
struct list_head *list);
|
|
|
|
|
|
2023-12-20 16:19:52 +01:00
|
|
|
size_t cfg80211_gen_new_ie(const u8 *ie, size_t ielen,
|
|
|
|
|
const u8 *subie, size_t subie_len,
|
|
|
|
|
u8 *new_ie, size_t new_ie_len);
|
|
|
|
|
#else
|
|
|
|
|
#define EXPORT_SYMBOL_IF_CFG80211_KUNIT(sym)
|
|
|
|
|
#define VISIBLE_IF_CFG80211_KUNIT static
|
|
|
|
|
#endif /* IS_ENABLED(CONFIG_CFG80211_KUNIT_TEST) */
|
|
|
|
|
|
2007-04-23 12:20:05 -07:00
|
|
|
#endif /* __NET_WIRELESS_CORE_H */
|