aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/cfg80211.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/cfg80211.h')
-rw-r--r--include/net/cfg80211.h288
1 files changed, 174 insertions, 114 deletions
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index 4ebb816241fa..7b44ba0a7632 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -520,37 +520,41 @@ ieee80211_chandef_max_power(struct cfg80211_chan_def *chandef)
520 * 520 *
521 * @SURVEY_INFO_NOISE_DBM: noise (in dBm) was filled in 521 * @SURVEY_INFO_NOISE_DBM: noise (in dBm) was filled in
522 * @SURVEY_INFO_IN_USE: channel is currently being used 522 * @SURVEY_INFO_IN_USE: channel is currently being used
523 * @SURVEY_INFO_CHANNEL_TIME: channel active time (in ms) was filled in 523 * @SURVEY_INFO_TIME: active time (in ms) was filled in
524 * @SURVEY_INFO_CHANNEL_TIME_BUSY: channel busy time was filled in 524 * @SURVEY_INFO_TIME_BUSY: busy time was filled in
525 * @SURVEY_INFO_CHANNEL_TIME_EXT_BUSY: extension channel busy time was filled in 525 * @SURVEY_INFO_TIME_EXT_BUSY: extension channel busy time was filled in
526 * @SURVEY_INFO_CHANNEL_TIME_RX: channel receive time was filled in 526 * @SURVEY_INFO_TIME_RX: receive time was filled in
527 * @SURVEY_INFO_CHANNEL_TIME_TX: channel transmit time was filled in 527 * @SURVEY_INFO_TIME_TX: transmit time was filled in
528 * @SURVEY_INFO_TIME_SCAN: scan time was filled in
528 * 529 *
529 * Used by the driver to indicate which info in &struct survey_info 530 * Used by the driver to indicate which info in &struct survey_info
530 * it has filled in during the get_survey(). 531 * it has filled in during the get_survey().
531 */ 532 */
532enum survey_info_flags { 533enum survey_info_flags {
533 SURVEY_INFO_NOISE_DBM = 1<<0, 534 SURVEY_INFO_NOISE_DBM = BIT(0),
534 SURVEY_INFO_IN_USE = 1<<1, 535 SURVEY_INFO_IN_USE = BIT(1),
535 SURVEY_INFO_CHANNEL_TIME = 1<<2, 536 SURVEY_INFO_TIME = BIT(2),
536 SURVEY_INFO_CHANNEL_TIME_BUSY = 1<<3, 537 SURVEY_INFO_TIME_BUSY = BIT(3),
537 SURVEY_INFO_CHANNEL_TIME_EXT_BUSY = 1<<4, 538 SURVEY_INFO_TIME_EXT_BUSY = BIT(4),
538 SURVEY_INFO_CHANNEL_TIME_RX = 1<<5, 539 SURVEY_INFO_TIME_RX = BIT(5),
539 SURVEY_INFO_CHANNEL_TIME_TX = 1<<6, 540 SURVEY_INFO_TIME_TX = BIT(6),
541 SURVEY_INFO_TIME_SCAN = BIT(7),
540}; 542};
541 543
542/** 544/**
543 * struct survey_info - channel survey response 545 * struct survey_info - channel survey response
544 * 546 *
545 * @channel: the channel this survey record reports, mandatory 547 * @channel: the channel this survey record reports, may be %NULL for a single
548 * record to report global statistics
546 * @filled: bitflag of flags from &enum survey_info_flags 549 * @filled: bitflag of flags from &enum survey_info_flags
547 * @noise: channel noise in dBm. This and all following fields are 550 * @noise: channel noise in dBm. This and all following fields are
548 * optional 551 * optional
549 * @channel_time: amount of time in ms the radio spent on the channel 552 * @time: amount of time in ms the radio was turn on (on the channel)
550 * @channel_time_busy: amount of time the primary channel was sensed busy 553 * @time_busy: amount of time the primary channel was sensed busy
551 * @channel_time_ext_busy: amount of time the extension channel was sensed busy 554 * @time_ext_busy: amount of time the extension channel was sensed busy
552 * @channel_time_rx: amount of time the radio spent receiving data 555 * @time_rx: amount of time the radio spent receiving data
553 * @channel_time_tx: amount of time the radio spent transmitting data 556 * @time_tx: amount of time the radio spent transmitting data
557 * @time_scan: amount of time the radio spent for scanning
554 * 558 *
555 * Used by dump_survey() to report back per-channel survey information. 559 * Used by dump_survey() to report back per-channel survey information.
556 * 560 *
@@ -559,11 +563,12 @@ enum survey_info_flags {
559 */ 563 */
560struct survey_info { 564struct survey_info {
561 struct ieee80211_channel *channel; 565 struct ieee80211_channel *channel;
562 u64 channel_time; 566 u64 time;
563 u64 channel_time_busy; 567 u64 time_busy;
564 u64 channel_time_ext_busy; 568 u64 time_ext_busy;
565 u64 channel_time_rx; 569 u64 time_rx;
566 u64 channel_time_tx; 570 u64 time_tx;
571 u64 time_scan;
567 u32 filled; 572 u32 filled;
568 s8 noise; 573 s8 noise;
569}; 574};
@@ -861,75 +866,6 @@ int cfg80211_check_station_change(struct wiphy *wiphy,
861 enum cfg80211_station_type statype); 866 enum cfg80211_station_type statype);
862 867
863/** 868/**
864 * enum station_info_flags - station information flags
865 *
866 * Used by the driver to indicate which info in &struct station_info
867 * it has filled in during get_station() or dump_station().
868 *
869 * @STATION_INFO_INACTIVE_TIME: @inactive_time filled
870 * @STATION_INFO_RX_BYTES: @rx_bytes filled
871 * @STATION_INFO_TX_BYTES: @tx_bytes filled
872 * @STATION_INFO_RX_BYTES64: @rx_bytes filled with 64-bit value
873 * @STATION_INFO_TX_BYTES64: @tx_bytes filled with 64-bit value
874 * @STATION_INFO_LLID: @llid filled
875 * @STATION_INFO_PLID: @plid filled
876 * @STATION_INFO_PLINK_STATE: @plink_state filled
877 * @STATION_INFO_SIGNAL: @signal filled
878 * @STATION_INFO_TX_BITRATE: @txrate fields are filled
879 * (tx_bitrate, tx_bitrate_flags and tx_bitrate_mcs)
880 * @STATION_INFO_RX_PACKETS: @rx_packets filled with 32-bit value
881 * @STATION_INFO_TX_PACKETS: @tx_packets filled with 32-bit value
882 * @STATION_INFO_TX_RETRIES: @tx_retries filled
883 * @STATION_INFO_TX_FAILED: @tx_failed filled
884 * @STATION_INFO_RX_DROP_MISC: @rx_dropped_misc filled
885 * @STATION_INFO_SIGNAL_AVG: @signal_avg filled
886 * @STATION_INFO_RX_BITRATE: @rxrate fields are filled
887 * @STATION_INFO_BSS_PARAM: @bss_param filled
888 * @STATION_INFO_CONNECTED_TIME: @connected_time filled
889 * @STATION_INFO_ASSOC_REQ_IES: @assoc_req_ies filled
890 * @STATION_INFO_STA_FLAGS: @sta_flags filled
891 * @STATION_INFO_BEACON_LOSS_COUNT: @beacon_loss_count filled
892 * @STATION_INFO_T_OFFSET: @t_offset filled
893 * @STATION_INFO_LOCAL_PM: @local_pm filled
894 * @STATION_INFO_PEER_PM: @peer_pm filled
895 * @STATION_INFO_NONPEER_PM: @nonpeer_pm filled
896 * @STATION_INFO_CHAIN_SIGNAL: @chain_signal filled
897 * @STATION_INFO_CHAIN_SIGNAL_AVG: @chain_signal_avg filled
898 * @STATION_INFO_EXPECTED_THROUGHPUT: @expected_throughput filled
899 */
900enum station_info_flags {
901 STATION_INFO_INACTIVE_TIME = BIT(0),
902 STATION_INFO_RX_BYTES = BIT(1),
903 STATION_INFO_TX_BYTES = BIT(2),
904 STATION_INFO_LLID = BIT(3),
905 STATION_INFO_PLID = BIT(4),
906 STATION_INFO_PLINK_STATE = BIT(5),
907 STATION_INFO_SIGNAL = BIT(6),
908 STATION_INFO_TX_BITRATE = BIT(7),
909 STATION_INFO_RX_PACKETS = BIT(8),
910 STATION_INFO_TX_PACKETS = BIT(9),
911 STATION_INFO_TX_RETRIES = BIT(10),
912 STATION_INFO_TX_FAILED = BIT(11),
913 STATION_INFO_RX_DROP_MISC = BIT(12),
914 STATION_INFO_SIGNAL_AVG = BIT(13),
915 STATION_INFO_RX_BITRATE = BIT(14),
916 STATION_INFO_BSS_PARAM = BIT(15),
917 STATION_INFO_CONNECTED_TIME = BIT(16),
918 STATION_INFO_ASSOC_REQ_IES = BIT(17),
919 STATION_INFO_STA_FLAGS = BIT(18),
920 STATION_INFO_BEACON_LOSS_COUNT = BIT(19),
921 STATION_INFO_T_OFFSET = BIT(20),
922 STATION_INFO_LOCAL_PM = BIT(21),
923 STATION_INFO_PEER_PM = BIT(22),
924 STATION_INFO_NONPEER_PM = BIT(23),
925 STATION_INFO_RX_BYTES64 = BIT(24),
926 STATION_INFO_TX_BYTES64 = BIT(25),
927 STATION_INFO_CHAIN_SIGNAL = BIT(26),
928 STATION_INFO_CHAIN_SIGNAL_AVG = BIT(27),
929 STATION_INFO_EXPECTED_THROUGHPUT = BIT(28),
930};
931
932/**
933 * enum station_info_rate_flags - bitrate info flags 869 * enum station_info_rate_flags - bitrate info flags
934 * 870 *
935 * Used by the driver to indicate the specific rate transmission 871 * Used by the driver to indicate the specific rate transmission
@@ -937,22 +873,35 @@ enum station_info_flags {
937 * 873 *
938 * @RATE_INFO_FLAGS_MCS: mcs field filled with HT MCS 874 * @RATE_INFO_FLAGS_MCS: mcs field filled with HT MCS
939 * @RATE_INFO_FLAGS_VHT_MCS: mcs field filled with VHT MCS 875 * @RATE_INFO_FLAGS_VHT_MCS: mcs field filled with VHT MCS
940 * @RATE_INFO_FLAGS_40_MHZ_WIDTH: 40 MHz width transmission
941 * @RATE_INFO_FLAGS_80_MHZ_WIDTH: 80 MHz width transmission
942 * @RATE_INFO_FLAGS_80P80_MHZ_WIDTH: 80+80 MHz width transmission
943 * @RATE_INFO_FLAGS_160_MHZ_WIDTH: 160 MHz width transmission
944 * @RATE_INFO_FLAGS_SHORT_GI: 400ns guard interval 876 * @RATE_INFO_FLAGS_SHORT_GI: 400ns guard interval
945 * @RATE_INFO_FLAGS_60G: 60GHz MCS 877 * @RATE_INFO_FLAGS_60G: 60GHz MCS
946 */ 878 */
947enum rate_info_flags { 879enum rate_info_flags {
948 RATE_INFO_FLAGS_MCS = BIT(0), 880 RATE_INFO_FLAGS_MCS = BIT(0),
949 RATE_INFO_FLAGS_VHT_MCS = BIT(1), 881 RATE_INFO_FLAGS_VHT_MCS = BIT(1),
950 RATE_INFO_FLAGS_40_MHZ_WIDTH = BIT(2), 882 RATE_INFO_FLAGS_SHORT_GI = BIT(2),
951 RATE_INFO_FLAGS_80_MHZ_WIDTH = BIT(3), 883 RATE_INFO_FLAGS_60G = BIT(3),
952 RATE_INFO_FLAGS_80P80_MHZ_WIDTH = BIT(4), 884};
953 RATE_INFO_FLAGS_160_MHZ_WIDTH = BIT(5), 885
954 RATE_INFO_FLAGS_SHORT_GI = BIT(6), 886/**
955 RATE_INFO_FLAGS_60G = BIT(7), 887 * enum rate_info_bw - rate bandwidth information
888 *
889 * Used by the driver to indicate the rate bandwidth.
890 *
891 * @RATE_INFO_BW_5: 5 MHz bandwidth
892 * @RATE_INFO_BW_10: 10 MHz bandwidth
893 * @RATE_INFO_BW_20: 20 MHz bandwidth
894 * @RATE_INFO_BW_40: 40 MHz bandwidth
895 * @RATE_INFO_BW_80: 80 MHz bandwidth
896 * @RATE_INFO_BW_160: 160 MHz bandwidth
897 */
898enum rate_info_bw {
899 RATE_INFO_BW_5,
900 RATE_INFO_BW_10,
901 RATE_INFO_BW_20,
902 RATE_INFO_BW_40,
903 RATE_INFO_BW_80,
904 RATE_INFO_BW_160,
956}; 905};
957 906
958/** 907/**
@@ -964,12 +913,14 @@ enum rate_info_flags {
964 * @mcs: mcs index if struct describes a 802.11n bitrate 913 * @mcs: mcs index if struct describes a 802.11n bitrate
965 * @legacy: bitrate in 100kbit/s for 802.11abg 914 * @legacy: bitrate in 100kbit/s for 802.11abg
966 * @nss: number of streams (VHT only) 915 * @nss: number of streams (VHT only)
916 * @bw: bandwidth (from &enum rate_info_bw)
967 */ 917 */
968struct rate_info { 918struct rate_info {
969 u8 flags; 919 u8 flags;
970 u8 mcs; 920 u8 mcs;
971 u16 legacy; 921 u16 legacy;
972 u8 nss; 922 u8 nss;
923 u8 bw;
973}; 924};
974 925
975/** 926/**
@@ -1003,6 +954,24 @@ struct sta_bss_parameters {
1003 u16 beacon_interval; 954 u16 beacon_interval;
1004}; 955};
1005 956
957/**
958 * struct cfg80211_tid_stats - per-TID statistics
959 * @filled: bitmap of flags using the bits of &enum nl80211_tid_stats to
960 * indicate the relevant values in this struct are filled
961 * @rx_msdu: number of received MSDUs
962 * @tx_msdu: number of (attempted) transmitted MSDUs
963 * @tx_msdu_retries: number of retries (not counting the first) for
964 * transmitted MSDUs
965 * @tx_msdu_failed: number of failed transmitted MSDUs
966 */
967struct cfg80211_tid_stats {
968 u32 filled;
969 u64 rx_msdu;
970 u64 tx_msdu;
971 u64 tx_msdu_retries;
972 u64 tx_msdu_failed;
973};
974
1006#define IEEE80211_MAX_CHAINS 4 975#define IEEE80211_MAX_CHAINS 4
1007 976
1008/** 977/**
@@ -1010,11 +979,12 @@ struct sta_bss_parameters {
1010 * 979 *
1011 * Station information filled by driver for get_station() and dump_station. 980 * Station information filled by driver for get_station() and dump_station.
1012 * 981 *
1013 * @filled: bitflag of flags from &enum station_info_flags 982 * @filled: bitflag of flags using the bits of &enum nl80211_sta_info to
983 * indicate the relevant values in this struct for them
1014 * @connected_time: time(in secs) since a station is last connected 984 * @connected_time: time(in secs) since a station is last connected
1015 * @inactive_time: time since last station activity (tx/rx) in milliseconds 985 * @inactive_time: time since last station activity (tx/rx) in milliseconds
1016 * @rx_bytes: bytes received from this station 986 * @rx_bytes: bytes (size of MPDUs) received from this station
1017 * @tx_bytes: bytes transmitted to this station 987 * @tx_bytes: bytes (size of MPDUs) transmitted to this station
1018 * @llid: mesh local link id 988 * @llid: mesh local link id
1019 * @plid: mesh peer link id 989 * @plid: mesh peer link id
1020 * @plink_state: mesh peer link state 990 * @plink_state: mesh peer link state
@@ -1027,10 +997,10 @@ struct sta_bss_parameters {
1027 * @chain_signal_avg: per-chain signal strength average in dBm 997 * @chain_signal_avg: per-chain signal strength average in dBm
1028 * @txrate: current unicast bitrate from this station 998 * @txrate: current unicast bitrate from this station
1029 * @rxrate: current unicast bitrate to this station 999 * @rxrate: current unicast bitrate to this station
1030 * @rx_packets: packets received from this station 1000 * @rx_packets: packets (MSDUs & MMPDUs) received from this station
1031 * @tx_packets: packets transmitted to this station 1001 * @tx_packets: packets (MSDUs & MMPDUs) transmitted to this station
1032 * @tx_retries: cumulative retry counts 1002 * @tx_retries: cumulative retry counts (MPDUs)
1033 * @tx_failed: number of failed transmissions (retries exceeded, no ACK) 1003 * @tx_failed: number of failed transmissions (MPDUs) (retries exceeded, no ACK)
1034 * @rx_dropped_misc: Dropped for un-specified reason. 1004 * @rx_dropped_misc: Dropped for un-specified reason.
1035 * @bss_param: current BSS parameters 1005 * @bss_param: current BSS parameters
1036 * @generation: generation number for nl80211 dumps. 1006 * @generation: generation number for nl80211 dumps.
@@ -1050,6 +1020,11 @@ struct sta_bss_parameters {
1050 * @nonpeer_pm: non-peer mesh STA power save mode 1020 * @nonpeer_pm: non-peer mesh STA power save mode
1051 * @expected_throughput: expected throughput in kbps (including 802.11 headers) 1021 * @expected_throughput: expected throughput in kbps (including 802.11 headers)
1052 * towards this station. 1022 * towards this station.
1023 * @rx_beacon: number of beacons received from this peer
1024 * @rx_beacon_signal_avg: signal strength average (in dBm) for beacons received
1025 * from this peer
1026 * @pertid: per-TID statistics, see &struct cfg80211_tid_stats, using the last
1027 * (IEEE80211_NUM_TIDS) index for MSDUs not encapsulated in QoS-MPDUs.
1053 */ 1028 */
1054struct station_info { 1029struct station_info {
1055 u32 filled; 1030 u32 filled;
@@ -1090,10 +1065,9 @@ struct station_info {
1090 1065
1091 u32 expected_throughput; 1066 u32 expected_throughput;
1092 1067
1093 /* 1068 u64 rx_beacon;
1094 * Note: Add a new enum station_info_flags value for each new field and 1069 u8 rx_beacon_signal_avg;
1095 * use it to check which fields are initialized. 1070 struct cfg80211_tid_stats pertid[IEEE80211_NUM_TIDS + 1];
1096 */
1097}; 1071};
1098 1072
1099/** 1073/**
@@ -1516,6 +1490,9 @@ struct cfg80211_match_set {
1516 * @mac_addr_mask: MAC address mask used with randomisation, bits that 1490 * @mac_addr_mask: MAC address mask used with randomisation, bits that
1517 * are 0 in the mask should be randomised, bits that are 1 should 1491 * are 0 in the mask should be randomised, bits that are 1 should
1518 * be taken from the @mac_addr 1492 * be taken from the @mac_addr
1493 * @rcu_head: RCU callback used to free the struct
1494 * @owner_nlportid: netlink portid of owner (if this should is a request
1495 * owned by a particular socket)
1519 */ 1496 */
1520struct cfg80211_sched_scan_request { 1497struct cfg80211_sched_scan_request {
1521 struct cfg80211_ssid *ssids; 1498 struct cfg80211_ssid *ssids;
@@ -1537,6 +1514,8 @@ struct cfg80211_sched_scan_request {
1537 struct wiphy *wiphy; 1514 struct wiphy *wiphy;
1538 struct net_device *dev; 1515 struct net_device *dev;
1539 unsigned long scan_start; 1516 unsigned long scan_start;
1517 struct rcu_head rcu_head;
1518 u32 owner_nlportid;
1540 1519
1541 /* keep last */ 1520 /* keep last */
1542 struct ieee80211_channel *channels[0]; 1521 struct ieee80211_channel *channels[0];
@@ -3011,6 +2990,8 @@ struct wiphy_vendor_command {
3011 * @regulatory_flags: wiphy regulatory flags, see 2990 * @regulatory_flags: wiphy regulatory flags, see
3012 * &enum ieee80211_regulatory_flags 2991 * &enum ieee80211_regulatory_flags
3013 * @features: features advertised to nl80211, see &enum nl80211_feature_flags. 2992 * @features: features advertised to nl80211, see &enum nl80211_feature_flags.
2993 * @ext_features: extended features advertised to nl80211, see
2994 * &enum nl80211_ext_feature_index.
3014 * @bss_priv_size: each BSS struct has private data allocated with it, 2995 * @bss_priv_size: each BSS struct has private data allocated with it,
3015 * this variable determines its size 2996 * this variable determines its size
3016 * @max_scan_ssids: maximum number of SSIDs the device can scan for in 2997 * @max_scan_ssids: maximum number of SSIDs the device can scan for in
@@ -3120,6 +3101,7 @@ struct wiphy {
3120 u16 max_acl_mac_addrs; 3101 u16 max_acl_mac_addrs;
3121 3102
3122 u32 flags, regulatory_flags, features; 3103 u32 flags, regulatory_flags, features;
3104 u8 ext_features[DIV_ROUND_UP(NUM_NL80211_EXT_FEATURES, 8)];
3123 3105
3124 u32 ap_sme_capa; 3106 u32 ap_sme_capa;
3125 3107
@@ -3808,6 +3790,34 @@ const u8 *cfg80211_find_vendor_ie(unsigned int oui, u8 oui_type,
3808int regulatory_hint(struct wiphy *wiphy, const char *alpha2); 3790int regulatory_hint(struct wiphy *wiphy, const char *alpha2);
3809 3791
3810/** 3792/**
3793 * regulatory_set_wiphy_regd - set regdom info for self managed drivers
3794 * @wiphy: the wireless device we want to process the regulatory domain on
3795 * @rd: the regulatory domain informatoin to use for this wiphy
3796 *
3797 * Set the regulatory domain information for self-managed wiphys, only they
3798 * may use this function. See %REGULATORY_WIPHY_SELF_MANAGED for more
3799 * information.
3800 *
3801 * Return: 0 on success. -EINVAL, -EPERM
3802 */
3803int regulatory_set_wiphy_regd(struct wiphy *wiphy,
3804 struct ieee80211_regdomain *rd);
3805
3806/**
3807 * regulatory_set_wiphy_regd_sync_rtnl - set regdom for self-managed drivers
3808 * @wiphy: the wireless device we want to process the regulatory domain on
3809 * @rd: the regulatory domain information to use for this wiphy
3810 *
3811 * This functions requires the RTNL to be held and applies the new regdomain
3812 * synchronously to this wiphy. For more details see
3813 * regulatory_set_wiphy_regd().
3814 *
3815 * Return: 0 on success. -EINVAL, -EPERM
3816 */
3817int regulatory_set_wiphy_regd_sync_rtnl(struct wiphy *wiphy,
3818 struct ieee80211_regdomain *rd);
3819
3820/**
3811 * wiphy_apply_custom_regulatory - apply a custom driver regulatory domain 3821 * wiphy_apply_custom_regulatory - apply a custom driver regulatory domain
3812 * @wiphy: the wireless device we want to process the regulatory domain on 3822 * @wiphy: the wireless device we want to process the regulatory domain on
3813 * @regd: the custom regulatory domain to use for this wiphy 3823 * @regd: the custom regulatory domain to use for this wiphy
@@ -4565,13 +4575,27 @@ void cfg80211_new_sta(struct net_device *dev, const u8 *mac_addr,
4565 struct station_info *sinfo, gfp_t gfp); 4575 struct station_info *sinfo, gfp_t gfp);
4566 4576
4567/** 4577/**
4578 * cfg80211_del_sta_sinfo - notify userspace about deletion of a station
4579 * @dev: the netdev
4580 * @mac_addr: the station's address
4581 * @sinfo: the station information/statistics
4582 * @gfp: allocation flags
4583 */
4584void cfg80211_del_sta_sinfo(struct net_device *dev, const u8 *mac_addr,
4585 struct station_info *sinfo, gfp_t gfp);
4586
4587/**
4568 * cfg80211_del_sta - notify userspace about deletion of a station 4588 * cfg80211_del_sta - notify userspace about deletion of a station
4569 * 4589 *
4570 * @dev: the netdev 4590 * @dev: the netdev
4571 * @mac_addr: the station's address 4591 * @mac_addr: the station's address
4572 * @gfp: allocation flags 4592 * @gfp: allocation flags
4573 */ 4593 */
4574void cfg80211_del_sta(struct net_device *dev, const u8 *mac_addr, gfp_t gfp); 4594static inline void cfg80211_del_sta(struct net_device *dev,
4595 const u8 *mac_addr, gfp_t gfp)
4596{
4597 cfg80211_del_sta_sinfo(dev, mac_addr, NULL, gfp);
4598}
4575 4599
4576/** 4600/**
4577 * cfg80211_conn_failed - connection request failed notification 4601 * cfg80211_conn_failed - connection request failed notification
@@ -5033,6 +5057,42 @@ void cfg80211_stop_iface(struct wiphy *wiphy, struct wireless_dev *wdev,
5033 */ 5057 */
5034void cfg80211_shutdown_all_interfaces(struct wiphy *wiphy); 5058void cfg80211_shutdown_all_interfaces(struct wiphy *wiphy);
5035 5059
5060/**
5061 * wiphy_ext_feature_set - set the extended feature flag
5062 *
5063 * @wiphy: the wiphy to modify.
5064 * @ftidx: extended feature bit index.
5065 *
5066 * The extended features are flagged in multiple bytes (see
5067 * &struct wiphy.@ext_features)
5068 */
5069static inline void wiphy_ext_feature_set(struct wiphy *wiphy,
5070 enum nl80211_ext_feature_index ftidx)
5071{
5072 u8 *ft_byte;
5073
5074 ft_byte = &wiphy->ext_features[ftidx / 8];
5075 *ft_byte |= BIT(ftidx % 8);
5076}
5077
5078/**
5079 * wiphy_ext_feature_isset - check the extended feature flag
5080 *
5081 * @wiphy: the wiphy to modify.
5082 * @ftidx: extended feature bit index.
5083 *
5084 * The extended features are flagged in multiple bytes (see
5085 * &struct wiphy.@ext_features)
5086 */
5087static inline bool
5088wiphy_ext_feature_isset(struct wiphy *wiphy,
5089 enum nl80211_ext_feature_index ftidx)
5090{
5091 u8 ft_byte;
5092
5093 ft_byte = wiphy->ext_features[ftidx / 8];
5094 return (ft_byte & BIT(ftidx % 8)) != 0;
5095}
5036 5096
5037/* ethtool helper */ 5097/* ethtool helper */
5038void cfg80211_get_drvinfo(struct net_device *dev, struct ethtool_drvinfo *info); 5098void cfg80211_get_drvinfo(struct net_device *dev, struct ethtool_drvinfo *info);