Lines Matching +full:combined +full:- +full:power +full:- +full:req

1 /* SPDX-License-Identifier: GPL-2.0-only */
3 * mac80211 <-> driver interface
5 * Copyright 2002-2005, Devicescape Software, Inc.
6 * Copyright 2006-2007 Jiri Benc <jbenc@suse.cz>
7 * Copyright 2007-2010 Johannes Berg <johannes@sipsolutions.net>
8 * Copyright 2013-2014 Intel Mobile Communications GmbH
9 * Copyright (C) 2015 - 2017 Intel Deutschland GmbH
10 * Copyright (C) 2018 - 2022 Intel Corporation
31 * only partial functionality in hard- or firmware. This document
32 * defines the interface between mac80211 and low-level hardware
40 * called in hardware interrupt context. The low-level driver must not call any
42 * call, the low-level driver should first ACK the interrupt and perform the
47 * use the non-IRQ-safe functions!
102 * Intermediate queues (struct ieee80211_txq) are kept per-sta per-tid, with
103 * another per-sta for non-data/non-mgmt and bufferable management frames, and
104 * a single per-vif queue for multicast data frames.
106 * The driver is expected to initialize its private per-queue data for stations
148 * enum ieee80211_max_queues - maximum number of queues
155 IEEE80211_MAX_QUEUE_MAP = BIT(IEEE80211_MAX_QUEUES) - 1,
161 * enum ieee80211_ac_numbers - AC numbers as used in mac80211
175 * struct ieee80211_tx_queue_params - transmit queue configuration
182 * 2^n-1 in the range 1..32767]
186 * @uapsd: is U-APSD mode enabled for the queue
209 * enum ieee80211_chanctx_change - change flag for channel context
226 * struct ieee80211_chanctx_conf - channel context that vifs may be tuned to
228 * This is the driver-visible part. The ieee80211_chanctx
254 * enum ieee80211_chanctx_switch_mode - channel context switch mode
262 * implement this as an on-the-fly chandef switch of the existing
273 * struct ieee80211_vif_chanctx_switch - vif chanctx switch information
293 * enum ieee80211_bss_change - BSS change notification flags
321 * @BSS_CHANGED_TXPOWER: TX power setting changed for this interface
330 * @BSS_CHANGED_MU_GROUPS: VHT MU-MIMO group id or user position changed
389 * enum ieee80211_event_type - event to be notified to the low level driver
405 * enum ieee80211_rssi_event_data - relevant when event type is %RSSI_EVENT
415 * struct ieee80211_rssi_event - data attached to an %RSSI_EVENT
423 * enum ieee80211_mlme_event_data - relevant when event type is %MLME_EVENT
437 * enum ieee80211_mlme_event_status - relevant when event type is %MLME_EVENT
449 * struct ieee80211_mlme_event - data attached to an %MLME_EVENT
461 * struct ieee80211_ba_event - data attached for BlockAck related events
473 * struct ieee80211_event - event to be sent to the driver
490 * struct ieee80211_mu_group_data - STA's VHT MU-MIMO group data
492 * This structure describes the group id data of VHT MU-MIMO
494 * @membership: 64 bits array - a bit is set if station is member of the group
503 * struct ieee80211_ftm_responder_params - FTM responder parameters
518 * struct ieee80211_fils_discovery - FILS discovery parameters from
519 * IEEE Std 802.11ai-2016, Annex C.3 MIB detail.
521 * @min_interval: Minimum packet interval in TUs (0 - 10000)
522 * @max_interval: Maximum packet interval in TUs (0 - 10000)
530 * struct ieee80211_bss_conf - holds the BSS's changing parameters
536 * @link_id: link ID, or 0 for non-MLO
539 * @ack_enabled: indicates support to receive a multi-TID that solicits either
555 * with the %BSS_CHANGED_BEACON_INFO flag, will be non-zero then.
578 * @mcast_rate: per-band multicast rate index + 1 (0: disabled)
581 * @chandef: Channel definition for this BSS -- the hardware might be
583 * @mu_group: VHT MU-MIMO group membership data
597 * @qos: This is a QoS-enabled BSS.
598 * @hidden_ssid: The SSID of the current vif is hidden. Only valid in AP-mode.
599 * @txpower: TX power in dBm. INT_MIN means not configured.
600 * @txpower_type: TX power adjustment used to control per packet Transmit
601 * Power Control (TPC) in lower driver for the current vif. In particular
637 * @power_type: power type of BSS for 6 GHz
638 * @tx_pwr_env: transmit power envelope array of BSS.
640 * @pwr_reduction: power constraint of BSS.
643 * write-protected by sdata_lock and local->mtx so holding either is fine
645 * @mu_mimo_owner: indicates interface owns MU-MIMO capability
647 * when it is not assigned. This pointer is RCU-protected due to the TX
652 * write-protected by sdata_lock and local->mtx so holding either is fine
731 * enum mac80211_tx_info_flags - flags to describe transmission information/status
740 * assign sequence numbers to QoS-data frames but cannot do so correctly
741 * for non-QoS-data and management frames because beacons need them from
745 * 802.11-2007 7.1.3.4.1 paragraph 3. This flag will always be set for
752 * @IEEE80211_TX_CTL_AMPDU: this frame should be sent as part of an A-MPDU
773 * off-channel operation.
781 * frame (PS-Poll or uAPSD) or a non-bufferable MMPDU and must
797 * @IEEE80211_TX_CTL_STBC: Enables Space-Time Block Coding (STBC) for this
800 * the off-channel channel when a remain-on-channel offload is done
801 * in hardware -- normal packets still flow and are expected to be
813 * PS-Poll responses.
823 * This flag must not be set for frames that don't request no-ack
868 * enum mac80211_tx_control_flags - flags to describe transmit control
873 * frame (PS-Poll or uAPSD).
875 * @IEEE80211_TX_CTRL_AMSDU: This frame is an A-MSDU frame
895 * These flags are used in tx_info->control.flags.
917 * enum mac80211_tx_status_flags - flags to describe transmit status
921 * These flags are used in tx_info->status.flags.
941 * enum mac80211_rate_control_flags - per-rate flags set by the
948 * @IEEE80211_TX_RC_USE_CTS_PROTECT: CTS-to-self protection is required.
995 * struct ieee80211_tx_rate - rate selection/status
1001 * A value of -1 for @idx indicates an invalid rate and, if used
1013 * { 3, 2 }, { 2, 2 }, { 1, 4 }, { -1, 0 }, { -1, 0 }
1021 * { 3, 2 }, { 2, 2 }, { 1, 1 }, { -1, 0 } ...
1038 WARN_ON((nss - 1) & ~0x7); in ieee80211_rate_set_vht()
1039 rate->idx = ((nss - 1) << 4) | mcs; in ieee80211_rate_set_vht()
1045 return rate->idx & 0xF; in ieee80211_rate_get_vht_mcs()
1051 return (rate->idx >> 4) + 1; in ieee80211_rate_get_vht_nss()
1055 * struct ieee80211_tx_info - skb transmit information
1057 * This structure is placed in skb->cb for three uses:
1058 * (1) mac80211 TX control - mac80211 tells the driver what to do
1060 * (3) TX status information - driver tells mac80211 what happened
1165 * in increments of 4us and clamp the maximum to 2**12-1 in ieee80211_info_set_tx_time_est()
1167 info->tx_time_est = min_t(u16, tx_time_est, 4095) >> 2; in ieee80211_info_set_tx_time_est()
1168 return info->tx_time_est << 2; in ieee80211_info_set_tx_time_est()
1174 return info->tx_time_est << 2; in ieee80211_info_get_tx_time_est()
1178 * struct ieee80211_rate_status - mrr stage for status path
1181 * dynamic way to report about used rates and power levels per packet.
1185 * @tx_power_idx An idx into the ieee80211_hw->tx_power_levels list of the
1186 * corresponding wifi hardware. The idx shall point to the power level
1196 * struct ieee80211_tx_status - extended tx status info for rate control
1220 * struct ieee80211_scan_ies - descriptors for different blocks of IEs
1241 return (struct ieee80211_tx_info *)skb->cb; in IEEE80211_SKB_CB()
1246 return (struct ieee80211_rx_status *)skb->cb; in IEEE80211_SKB_RXCB()
1250 * ieee80211_tx_info_clear_status - clear TX status
1275 info->status.rates[i].count = 0; in ieee80211_tx_info_clear_status()
1276 memset_after(&info->status, 0, rates); in ieee80211_tx_info_clear_status()
1281 * enum mac80211_rx_flags - receive flags
1297 * de-duplication by itself.
1312 * Valid only for data frames (mainly A-MPDU)
1313 * @RX_FLAG_AMPDU_DETAILS: A-MPDU details are known, in particular the reference
1315 * each A-MPDU
1317 * subframes of a single A-MPDU
1318 * @RX_FLAG_AMPDU_IS_LAST: this subframe is the last subframe of the A-MPDU
1333 * @RX_FLAG_AMSDU_MORE: Some drivers may prefer to report separate A-MSDU
1335 * All, but the last MSDU from an A-MSDU should have this flag set. E.g.
1336 * if an A-MSDU has 3 frames, the first 2 must have the flag set, while
1338 * deal with retransmission/duplication recovery properly since A-MSDU
1340 * either regular MSDU or singly A-MSDUs. Subframes must not be
1342 * @RX_FLAG_RADIOTAP_VENDOR_DATA: This frame contains vendor-specific
1343 * radiotap data in the skb->data (before the frame) as described by
1350 * @RX_FLAG_AMPDU_EOF_BIT: Value of the EOF bit in the A-MPDU delimiter for this
1356 * - DATA3_DATA_MCS
1357 * - DATA3_DATA_DCM
1358 * - DATA3_CODING
1359 * - DATA5_GI
1360 * - DATA5_DATA_BW_RU_ALLOC
1361 * - DATA6_NSTS
1362 * - DATA3_STBC
1367 * @RX_FLAG_RADIOTAP_LSIG: L-SIG radiotap data is present
1369 * the "0-length PSDU" field included there. The value for it is
1410 * enum mac80211_rx_encoding_flags - MCS & bandwidth flags
1414 * @RX_ENC_FLAG_HT_GF: This frame was received in a HT-greenfield transmission,
1419 * @RX_ENC_FLAG_STBC_MASK: STBC 2 bit bitmask. 1 - Nss=1, 2 - Nss=2, 3 - Nss=3
1441 * struct ieee80211_rx_status - receive status
1443 * The low-level driver should provide this information (the subset
1447 * @mactime: value in microseconds of the 64-bit Time Synchronization Function
1459 * for data (other) frames - for those it only affects radiotap reporting.
1466 * @chain_signal: per-chain signal strength, in dBm (unlike @signal, doesn't
1480 * @ampdu_reference: A-MPDU reference number, must be a different value for
1481 * each A-MPDU but the same for each subframe within one A-MPDU
1482 * @ampdu_delimiter_crc: A-MPDU delimiter CRC
1483 * @zero_length_psdu_type: radiotap type of the 0-length PSDU
1518 return MHZ_TO_KHZ(rx_status->freq) + in ieee80211_rx_status_to_khz()
1519 (rx_status->freq_offset ? 500 : 0); in ieee80211_rx_status_to_khz()
1523 * struct ieee80211_vendor_radiotap - vendor radiotap data information
1529 * description itself (which has a fixed 2-byte alignment)
1530 * Must be a power of two, and be set to at least 1!
1541 * This struct, including the vendor data, goes into the skb->data before
1556 * enum ieee80211_conf_flags - configuration flags
1560 * @IEEE80211_CONF_MONITOR: there's a monitor interface present -- use this
1563 * @IEEE80211_CONF_PS: Enable 802.11 power save mode (managed mode only).
1564 * This is the power save mode defined by IEEE 802.11-2007 section 11.2,
1587 * enum ieee80211_conf_changed - denotes which configuration changed
1592 * @IEEE80211_CONF_CHANGE_POWER: the TX power changed
1612 * enum ieee80211_smps_mode - spatial multiplexing power save mode
1631 * struct ieee80211_conf - configuration of the device
1639 * in power saving. Power saving will not be enabled until a beacon
1645 * @power_level: requested transmit power (in dBm), backward compatibility
1679 * struct ieee80211_channel_switch - holds the channel switch data
1684 * @timestamp: value in microseconds of the 64-bit Time Synchronization
1708 * enum ieee80211_vif_flags - virtual interface flags
1713 * monitoring on this virtual interface -- i.e. it can monitor
1716 * @IEEE80211_VIF_SUPPORTS_UAPSD: The device can do U-APSD for this
1733 * enum ieee80211_offload_flags - virtual interface offload flags
1738 * @IEEE80211_OFFLOAD_ENCAP_4ADDR: support 4-address mode encapsulation offload
1751 * struct ieee80211_vif_cfg - interface configuration
1755 * @ps: power-save mode (STA only). This flag is NOT affected by
1771 * @ap_addr: AP MLD address, or BSSID for non-MLO connections
1791 * struct ieee80211_vif - per-interface data
1800 * @link_conf: in case of MLD, the per-link BSS configuration,
1802 * @valid_links: bitmap of valid links, or 0 for non-MLO.
1803 * @active_links: The bitmap of active links, or 0 for non-MLO.
1808 * interface, i.e. a GO or p2p-sta respectively
1819 * @cab_queue: content-after-beacon (DTIM beacon really) queue, AP mode only
1831 * protected by fq->lock.
1832 * @offload_flags: 802.3 -> 802.11 enapsulation offload flags, see
1869 for (link_id = 0; link_id < ARRAY_SIZE((vif)->link_conf); link_id++) \
1870 if ((!(vif)->active_links || \
1871 (vif)->active_links & BIT(link_id)) && \
1872 (link = rcu_dereference((vif)->link_conf[link_id])))
1877 return vif->type == NL80211_IFTYPE_MESH_POINT; in ieee80211_vif_is_mesh()
1883 * wdev_to_ieee80211_vif - return a vif struct from a wdev
1896 * ieee80211_vif_to_wdev - return a wdev struct from a vif
1906 * lockdep_vif_mutex_held - for lockdep checks on link poiners
1911 return lockdep_is_held(&ieee80211_vif_to_wdev(vif)->mtx); in lockdep_vif_mutex_held()
1915 rcu_dereference_protected((vif)->link_conf[link_id], \
1919 * enum ieee80211_key_flags - key flags
1978 * struct ieee80211_key_conf - key information
1990 * @keyidx: the key index (0-3)
1992 * @key: key material. For ALG_TKIP the key is encoded as a 256-bit (32 byte)
1994 * - Temporal Encryption Key (128 bits)
1995 * - Temporal Authenticator Tx MIC Key (64 bits)
1996 * - Temporal Authenticator Rx MIC Key (64 bits)
1999 * @link_id: the link ID for MLO, or -1 for non-MLO or pairwise keys
2020 * struct ieee80211_key_seq - key sequence counter
2031 * @hw: data for HW-only (e.g. cipher scheme) keys
2059 * enum set_key_cmd - key command
2072 * enum ieee80211_sta_state - station state
2091 * enum ieee80211_sta_rx_bandwidth - station RX bandwidth
2111 * struct ieee80211_sta_rates - station rate selection table
2115 * Overriding entries per-packet is possible by using cb tx control.
2129 * struct ieee80211_sta_txpwr - station txpower configuration
2133 * @power: indicates the tx power, in dBm, to be used when sending data frames
2135 * @type: In particular if TPC %type is NL80211_TX_POWER_LIMITED then tx power
2137 * %type is NL80211_TX_POWER_AUTOMATIC then it indicates default tx power.
2142 s16 power; member
2147 * struct ieee80211_sta_aggregates - info that is aggregated from active links
2149 * Used for any per-link data that needs to be aggregated and updated in the
2152 * @max_amsdu_len: indicates the maximal length of an A-MSDU in bytes.
2157 * A-MSDU maximal size is min(max_amsdu_len, 4065) bytes.
2158 * * If the skb is not part of a BA agreement, the A-MSDU maximal
2162 * driver. This is defined by the spec (IEEE 802.11-2012 section
2164 * @max_rc_amsdu_len: Maximum A-MSDU size in bytes recommended by rate control.
2165 * @max_tid_amsdu_len: Maximum A-MSDU size in bytes for this TID
2175 * struct ieee80211_link_sta - station Link specific info
2179 * @addr: MAC address of the Link STA. For non-MLO STA this is same as the addr
2195 * @txpwr: the station tx power configuration
2218 * struct ieee80211_sta - station table entry
2221 * communicating with. Since stations are RCU-managed in
2249 * A-MSDU. Taken from the Extended Capabilities element. 0 means
2255 * @txq: per-TID data TX queues (if driver uses the TXQ abstraction); note that
2256 * the last entry (%IEEE80211_NUM_TIDS) is used for non-data frames
2268 * @valid_links: bitmap of valid links, or 0 for non-MLO
2308 rcu_dereference_protected((sta)->link[link_id], \
2312 for (link_id = 0; link_id < ARRAY_SIZE((sta)->link); link_id++) \
2313 if ((!(vif)->active_links || \
2314 (vif)->active_links & BIT(link_id)) && \
2318 * enum sta_notify_cmd - sta notify command
2321 * indicates if an associated station made a power state transition.
2331 * struct ieee80211_tx_control - TX control data
2341 * struct ieee80211_txq - Software intermediate tx queue
2344 * @sta: station table entry, %NULL for per-vif queue
2345 * @tid: the TID for this queue (unused for per-vif queue),
2346 * %IEEE80211_NUM_TIDS for non-data (if enabled)
2348 * @drv_priv: driver private area, sized by hw->txq_data_size
2364 * enum ieee80211_hw_flags - hardware flags
2391 * for power saving stations in the hardware/firmware and others
2394 * multicast frames when there are power saving stations so that
2412 * Hardware supports 11n A-MPDU aggregation.
2415 * Hardware has power save support (i.e. can go to sleep).
2433 * periodic keep-alives to the AP and probing the AP on beacon loss.
2440 * per-station GTKs as used by IBSS RSN or during fast transition. If
2441 * the device doesn't support per-station GTKs, but can be asked not
2453 * @IEEE80211_HW_TX_AMPDU_SETUP_IN_HW: The device handles TX A-MPDU session
2462 * be created. It is expected user-space will create vifs as
2466 * crypto algorithms can be done in software - so don't automatically
2471 * @IEEE80211_HW_SUPPORT_FAST_XMIT: The driver/hardware supports fast-xmit,
2475 * @IEEE80211_HW_QUEUE_CONTROL: The driver wants to control per-interface
2494 * @IEEE80211_HW_CHANCTX_STA_CSA: Support 802.11h based channel-switch (CSA)
2508 * @IEEE80211_HW_SUPPORTS_AMSDU_IN_AMPDU: The driver supports receiving A-MSDUs
2509 * within A-MPDU.
2525 * which implies using per-CPU station statistics.
2528 * A-MSDU frames. Requires software tx queueing and fast-xmit support.
2530 * limit the maximum A-MSDU size based on the current tx rate by setting
2534 * skbs, needed for zero-copy software A-MSDU.
2551 * beacon was heard. This is required in multi-channel scenarios, where the
2557 * support QoS NDP for AP probing - that's most likely a driver bug.
2565 * but if the rate control is built-in then it must be set by the driver.
2568 * @IEEE80211_HW_STA_MMPDU_TXQ: use the extra non-TID per-station TXQ for all
2572 * @IEEE80211_HW_TX_STATUS_NO_AMPDU_LEN: Driver does not report accurate A-MPDU
2582 * A-MPDU sessions active while rekeying with Extended Key ID.
2665 * struct ieee80211_hw - hardware information and state
2719 * sub-frames) to be used for A-MPDU block ack receiver
2732 * @max_tx_fragments: maximum number of tx buffers per (A)-MSDU, sum
2733 * of 1 + skb_shinfo(skb)->nr_frags for each skb in the frag_list.
2750 * @units_pos member is set to a non-negative value then the timestamp
2756 * @radiotap_timestamp.accuracy: If non-negative, fills the accuracy in the
2764 * for each access category if it is uAPSD trigger-enabled and delivery-
2767 * that corresponding AC is both trigger- and delivery-enabled. '0' means
2786 * @tx_power_levels: a list of power levels supported by the wifi hardware.
2787 * The power levels can be specified either as integer or fractions.
2788 * The power level at idx 0 shall be the maximum positive power level.
2834 return test_bit(flg, hw->flags); in _ieee80211_hw_check()
2841 return __set_bit(flg, hw->flags); in _ieee80211_hw_set()
2846 * struct ieee80211_scan_request - hw scan request
2848 * @ies: pointers different parts of IEs (in req.ie)
2849 * @req: cfg80211 request.
2855 struct cfg80211_scan_request req; member
2859 * struct ieee80211_tdls_ch_sw_params - TDLS channel switch parameters
2861 * @sta: peer this TDLS channel-switch request/response came from
2862 * @chandef: channel referenced in a TDLS channel-switch request
2864 * @status: channel-switch response status
2866 * @switch_time: switch-timing parameter received in the frame
2867 * @switch_timeout: switch-timing parameter received in the frame
2868 * @tmpl_skb: TDLS switch-channel response template
2869 * @ch_sw_tm_ie: offset of the channel-switch timing IE inside @tmpl_skb
2884 * wiphy_to_ieee80211_hw - return a mac80211 driver hw struct from a wiphy
2890 * structure can then access it via hw->priv. Note that mac802111 drivers should
2899 * SET_IEEE80211_DEV - set device for 802.11 hardware
2906 set_wiphy_dev(hw->wiphy, dev); in SET_IEEE80211_DEV()
2910 * SET_IEEE80211_PERM_ADDR - set the permanent MAC address for 802.11 hardware
2917 memcpy(hw->wiphy->perm_addr, addr, ETH_ALEN); in SET_IEEE80211_PERM_ADDR()
2924 if (WARN_ON_ONCE(c->control.rates[0].idx < 0)) in ieee80211_get_tx_rate()
2926 return &hw->wiphy->bands[c->band]->bitrates[c->control.rates[0].idx]; in ieee80211_get_tx_rate()
2933 if (c->control.rts_cts_rate_idx < 0) in ieee80211_get_rts_cts_rate()
2935 return &hw->wiphy->bands[c->band]->bitrates[c->control.rts_cts_rate_idx]; in ieee80211_get_rts_cts_rate()
2942 if (c->control.rates[idx + 1].idx < 0) in ieee80211_get_alt_retry_rate()
2944 return &hw->wiphy->bands[c->band]->bitrates[c->control.rates[idx + 1].idx]; in ieee80211_get_alt_retry_rate()
2948 * ieee80211_free_txskb - free TX skb
2976 * the key is now in use, -%EOPNOTSUPP or -%ENOSPC if it couldn't be
3012 * when they are able to replace in-use PTK keys according to the following
3017 at the time of the key deletion (including re-transmits),
3040 * IEEE 802.11-2007 section 11.2 is enabled. This is not to be confused
3058 * hardware stays awake for a user-specified period of time after sending a
3061 * there's data traffic and still saving significantly power in idle
3075 * Driver informs U-APSD client support by enabling
3079 * utilize U-APSD, dynamic powersave is disabled for voip AC and all frames
3082 * Note: U-APSD client mode is not yet supported with
3090 * which will reduce system power consumption. It usually works so that
3099 * whenever power save is enabled, that is %IEEE80211_CONF_PS is set. When
3100 * power save is enabled, the stack will not check for beacon loss and the
3113 * - a list of information element IDs
3114 * - a list of OUIs for the vendor information element
3128 * the various vendor-assigned IEs with unknown contents (128, 129, 133-136,
3148 * DOC: Spatial multiplexing power save
3150 * SMPS (Spatial multiplexing power save) is a mechanism to conserve
3151 * power in an 802.11n implementation. For details on the mechanism
3152 * and rationale, please refer to 802.11 (as amended by 802.11n-2009)
3153 * "11.2.3 SM power save".
3177 * in monitor mode. However, for best CPU usage and power consumption,
3187 * for the combined multicast address list of all virtual interfaces.
3216 * client powersaving, both "legacy" PS (PS-Poll/null data) and uAPSD.
3220 * will not poll with PS-Poll and trigger with uAPSD at the same time.
3231 * handle PS-Poll/uAPSD.
3245 * it can PS-Poll, or it can possibly start a uAPSD service period.
3248 * the station sends a PS-Poll or a uAPSD trigger frame, mac80211
3253 * response to a PS-Poll) also has %IEEE80211_TX_STATUS_EOSP set to
3259 * Additionally, non-bufferable MMPDUs can also be transmitted by
3267 * transmitted to a certain station is out-of-band communication to
3285 * there is more data on other TIDs -- the TIDs to release frames
3290 * shorten service periods (or abort PS-Poll responses), it must
3292 * are buffered in the driver -- those must remain buffered to avoid
3303 * Note that if the driver ever buffers frames other than QoS-data
3304 * frames, it must take care to never send a non-QoS-data frame as
3305 * the last frame in a service period, adding a QoS-nulldata frame
3306 * after a non-QoS-data frame if needed.
3313 * assignment of per-interface AC software queues to hardware queues. This
3315 * 1) off-channel transmissions might get stuck behind other frames
3317 * 3) after-DTIM frames could get stuck behind other frames
3341 * after-DTIM queue for AP: 8
3342 * off-channel queue: 9
3353 * and the second virtual interface with 4-7.
3365 * enum ieee80211_filter_flags - hardware filter flags
3370 * but this has negative impact on power consumption.
3412 * enum ieee80211_ampdu_mlme_action - A-MPDU actions
3457 * struct ieee80211_ampdu_params - AMPDU action parameters
3468 * @amsdu: indicates the peer's ability to receive A-MSDU within A-MPDU.
3484 * enum ieee80211_frame_release_type - frame release reason
3485 * @IEEE80211_FRAME_RELEASE_PSPOLL: frame released for PS-Poll
3487 * frame received on trigger-enabled AC
3495 * enum ieee80211_rate_control_changed - flags to indicate what changed
3499 * information -- for HT20/40 the IEEE80211_HT_CAP_SUP_WIDTH_20_40
3516 * enum ieee80211_roc_type - remain on channel type
3534 * enum ieee80211_reconfig_type - reconfig type
3550 * struct ieee80211_prep_tx_info - prepare TX information
3551 * @duration: if non-zero, hint about the required duration,
3565 * struct ieee80211_ops - callbacks from mac80211 to the driver
3573 * The low-level driver should send the frame out based on
3584 * to avoid acknowledging frames before a non-monitor device
3668 * non-MLO connections.
3709 * offloading. The index can be 0-3, or -1 for unsetting it.
3715 * that power save is disabled.
3716 * The @req ie/ie_len members are rewritten by mac80211 to contain the
3718 * at all but just send them after the SSID -- mac80211 includes the
3730 * @cancel_hw_scan: Ask the low-level tp cancel the active hw scan.
3735 * scan_work after the low-level driver was already suspended.
3757 * @get_stats: Return low-level statistics.
3790 * @sta_notify: Notifies low level driver about power state transition of an
3795 * @sta_set_txpwr: Configure the station tx power. This callback set the tx
3796 * power for the station.
3804 * isn't safe to use the pointer, not even RCU protected - no RCU grace
3829 * let the driver pre-fill the statistics. The driver can fill most of
3831 * all of them make sense - see the source for which ones are possible.
3865 * Returns non-zero if this device sent the last beacon.
3868 * @get_survey: Return per-channel survey information
3871 * need to set wiphy->rfkill_poll to %true before registration,
3876 * in IEEE 802.11-2007 section 17.3.8.6 and modify ACK timeout
3877 * accordingly; coverage class equals to -1 to enable ACK timeout
3900 * reject TX/RX mask combinations they cannot support by returning -EINVAL
3905 * @remain_on_channel: Starts an off-channel period on the given channel, must
3908 * offload. Frames to transmit on the off-channel channel are transmitted
3910 * duration (which will always be non-zero) expires, the driver must call
3915 * @cancel_remain_on_channel: Requests that an ongoing off-channel period is
3923 * queues before entering power save.
3935 * to release some frames, either for PS-poll or uAPSD.
3938 * the frames being released then it must still set the more-data bit in
3940 * more-data bit must always be set.
3942 * from, for PS-poll it will always have only a single bit set.
3943 * In the case this is used for a PS-poll initiated release, the
3946 * on the TX status (and must report TX status) so that the PS-poll
3948 * responses for a retried PS-poll frame.
3971 * @get_et_sset_count: Ethtool API to get string-set count.
3976 * and perhaps other supported types of ethtool data-sets.
3979 * before associated. In multi-channel scenarios, a virtual interface is
4001 * a TDLS discovery-request, we expect a reply to arrive on the AP's
4003 * setup-response is a direct packet not buffered by the AP.
4005 * discovery-request. The recommended period of protection is at least
4059 * gets a CSA or a userspace initiated channel-switch), allowing
4079 * @get_txpower: get current maximum tx power (in dBm) based on configuration
4082 * @tdls_channel_switch: Start channel-switching with a TDLS peer. The driver
4083 * is responsible for continually initiating channel-switching operations
4085 * driver receives a channel-switch request template and the location of
4086 * the switch-timing IE within the template as part of the invocation.
4088 * optionally copy the skb for further re-use.
4089 * @tdls_cancel_channel_switch: Stop channel-switching with a TDLS peer. Both
4091 * @tdls_recv_channel_switch: a TDLS channel-switch related frame (request or
4094 * an ongoing channel-switch operation. In addition, a channel-switch
4096 * switch-timing IE within the template. The skb can only be used within
4120 * aggregating two specific frames in the same A-MSDU. The relation
4122 * skb is always a real frame, head may or may not be an A-MSDU.
4134 * 4-address mode
4135 * @set_sar_specs: Update the SAR (TX power) settings.
4158 * new links bitmaps may be 0 if going from/to a non-MLO situation.
4165 * i.e. passed to @sta_add/@sta_state with sta->valid_links not zero.
4230 struct ieee80211_scan_request *req);
4235 struct cfg80211_sched_scan_request *req,
4298 * Perform a certain A-MPDU action.
4308 * - ``TX: 1.....7``
4309 * - ``RX: 2....7`` (lost frame #1)
4310 * - ``TX: 8..1...``
4312 * which is invalid since #1 was now re-transmitted well past the
4315 * - ``TX: 1 or``
4316 * - ``TX: 18 or``
4317 * - ``TX: 81``
4525 * ieee80211_alloc_hw_nm - Allocate a new hardware device
4545 * ieee80211_alloc_hw - Allocate a new hardware device
4566 * ieee80211_register_hw - Register hardware device
4579 * struct ieee80211_tpt_blink - throughput blink description
4590 * enum ieee80211_tpt_led_trigger_flags - throughput trigger flags
4614 * ieee80211_get_tx_led_name - get name of TX LED
4635 * ieee80211_get_rx_led_name - get name of RX LED
4656 * ieee80211_get_assoc_led_name - get name of association LED
4677 * ieee80211_get_radio_led_name - get name of radio LED
4698 * ieee80211_create_tpt_led_trigger - create throughput LED trigger
4701 * @blink_table: the blink table -- needs to be ordered by throughput
4723 * ieee80211_unregister_hw - Unregister a hardware device
4733 * ieee80211_free_hw - free hardware descriptor
4744 * ieee80211_restart_hw - restart hardware completely
4750 * calling the ->start() operation. The driver will need to reset all
4758 * ieee80211_rx_list - receive frame and store processed skbs in a list
4783 * ieee80211_rx_napi - receive frame from NAPI context
4808 * ieee80211_rx - receive frame
4833 * ieee80211_rx_irqsafe - receive frame
4848 * ieee80211_rx_ni - receive frame (in process context)
4869 * ieee80211_sta_ps_transition - PS transition for connected sta
4883 * Return: 0 on success. -EINVAL when the requested PS mode is already set.
4888 * ieee80211_sta_ps_transition_ni - PS transition for connected sta
4913 * ieee80211_sta_pspoll - PS-Poll frame received
4917 * use this function to inform mac80211 that a PS-Poll frame from a
4926 * ieee80211_sta_uapsd_trigger - (potential) U-APSD trigger frame received
4950 * ieee80211_sta_set_buffered - inform mac80211 about driver-buffered frames
4964 * If all frames are released to the station (due to PS-poll or uAPSD)
4981 * ieee80211_get_tx_rates - get the selected transmit rates for a packet
4983 * Call this function in a driver with per-packet rate selection support
5000 * ieee80211_sta_set_expected_throughput - set the expected tpt for a station
5016 * ieee80211_tx_rate_update - transmit rate update callback
5018 * Drivers should call this functions with a non-NULL pub sta
5031 * ieee80211_tx_status - transmit status callback
5050 * ieee80211_tx_status_ext - extended transmit status callback
5067 * ieee80211_tx_status_noskb - transmit status callback without skb
5095 * ieee80211_tx_status_ni - transmit status callback (in process context)
5115 * ieee80211_tx_status_irqsafe - IRQ-safe transmit status callback
5130 * ieee80211_tx_status_8023 - transmit status callback for 802.3 frame format
5150 * ieee80211_report_low_ack - report non-responding station
5152 * When operating in AP-mode, call this function to report a non-responding
5155 * @sta: the non-responding connected sta
5163 * struct ieee80211_mutable_offsets - mutable beacon offsets
5180 * ieee80211_beacon_get_template - beacon template generation function
5185 * @link_id: the link id to which the beacon belongs (or 0 for a non-MLD AP)
5206 * ieee80211_beacon_get_tim - beacon generation function
5210 * Set to 0 if invalid (in non-AP modes).
5213 * Set to 0 if invalid (in non-AP modes).
5214 * @link_id: the link id to which the beacon belongs (or 0 for a non-MLD AP)
5221 * frame from mac80211 -- it is responsible for calling this function exactly
5234 * ieee80211_beacon_get - beacon generation function
5237 * @link_id: the link id to which the beacon belongs (or 0 for a non-MLD AP)
5251 * ieee80211_beacon_update_cntdwn - request mac80211 to decrement the beacon countdown
5265 * ieee80211_beacon_set_cntdwn - request mac80211 to set beacon countdown
5278 * ieee80211_csa_finish - notify mac80211 about channel switch
5288 * ieee80211_beacon_cntdwn_is_complete - find out if countdown reached 1
5296 * ieee80211_color_change_finish - notify mac80211 about color change
5306 * ieee80211_proberesp_get - retrieve a Probe Response template
5321 * ieee80211_pspoll_get - retrieve a PS Poll template
5338 * ieee80211_nullfunc_get - retrieve a nullfunc template
5364 * ieee80211_probereq_get - retrieve a Probe Request template
5382 * ieee80211_rts_get - RTS frame generation function
5391 * hardware/firmware), the low-level driver uses this function to receive
5392 * the next RTS frame from the 802.11 code. The low-level is responsible
5401 * ieee80211_rts_duration - Get the duration field for an RTS frame
5408 * the duration field, the low-level driver uses this function to receive
5409 * the duration field value in little-endian byteorder.
5418 * ieee80211_ctstoself_get - CTS-to-self frame generation function
5421 * @frame: pointer to the frame that is going to be protected by the CTS-to-self.
5424 * @cts: The buffer where to store the CTS-to-self frame.
5426 * If the CTS-to-self frames are generated by the host system (i.e., not in
5427 * hardware/firmware), the low-level driver uses this function to receive
5428 * the next CTS-to-self frame from the 802.11 code. The low-level is responsible
5429 * for calling this function before and CTS-to-self frame is needed.
5438 * ieee80211_ctstoself_duration - Get the duration field for a CTS-to-self frame
5441 * @frame_len: the length of the frame that is going to be protected by the CTS-to-self.
5444 * If the CTS-to-self is generated in firmware, but the host system must provide
5445 * the duration field, the low-level driver uses this function to receive
5446 * the duration field value in little-endian byteorder.
5456 * ieee80211_generic_frame_duration - Calculate the duration field for a frame
5475 * ieee80211_get_buffered_bc - accessing buffered broadcast and multicast frames
5481 * frames when power saving is used, 802.11 code buffers them in the host
5482 * memory. The low-level driver uses this function to fetch next buffered
5489 * generated with ieee80211_beacon_get() and the low-level driver must thus
5491 * NULL if the previous generated beacon was not DTIM, so the low-level driver
5499 * ieee80211_get_tkip_p1k_iv - get a TKIP phase 1 key for IV32
5511 * ieee80211_get_tkip_p1k - get a TKIP phase 1 key
5524 struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; in ieee80211_get_tkip_p1k()
5525 const u8 *data = (u8 *)hdr + ieee80211_hdrlen(hdr->frame_control); in ieee80211_get_tkip_p1k()
5532 * ieee80211_get_tkip_rx_p1k - get a TKIP phase 1 key for RX
5546 * ieee80211_get_tkip_p2k - get a TKIP phase 2 key
5560 * ieee80211_tkip_add_iv - write TKIP IV and Ext. IV to pos
5575 * ieee80211_get_key_rx_seq - get key RX sequence counter
5578 * @tid: The TID, or -1 for the management frame value (CCMP/GCMP only);
5579 * the value on TID 0 is also used for non-QoS frames. For
5594 * ieee80211_set_key_rx_seq - set key RX sequence counter
5597 * @tid: The TID, or -1 for the management frame value (CCMP/GCMP only);
5598 * the value on TID 0 is also used for non-QoS frames. For
5614 * ieee80211_remove_key - remove the given key
5627 * ieee80211_gtk_rekey_add - add a GTK key from rekeying during WoWLAN
5637 * mac80211-owned memory. In case of errors, the function returns an
5660 * ieee80211_gtk_rekey_notify - notify userspace supplicant of rekeying
5670 * ieee80211_key_mic_failure - increment MIC failure counter for the key
5680 * ieee80211_key_replay - increment replay counter for the key
5690 * ieee80211_wake_queue - wake specific queue
5699 * ieee80211_stop_queue - stop specific queue
5708 * ieee80211_queue_stopped - test status of the queue
5720 * ieee80211_stop_queues - stop all queues
5728 * ieee80211_wake_queues - wake all queues
5736 * ieee80211_scan_completed - completed hardware scan
5750 * ieee80211_sched_scan_results - got results from scheduled scan
5760 * ieee80211_sched_scan_stopped - inform that the scheduled scan has stopped
5772 * enum ieee80211_interface_iteration_flags - interface iteration flags
5777 * haven't been re-added to the driver yet.
5779 * interfaces, even if they haven't been re-added to the driver yet.
5793 * ieee80211_iterate_interfaces - iterate interfaces
5811 * ieee80211_iterate_active_interfaces - iterate active interfaces
5837 * ieee80211_iterate_active_interfaces_atomic - iterate active interfaces
5858 * ieee80211_iterate_active_interfaces_mtx - iterate active interfaces
5865 * callbacks made by mac80211 - both would result in deadlocks.
5880 * ieee80211_iterate_stations - iterate stations
5898 * ieee80211_iterate_stations_atomic - iterate stations
5914 * ieee80211_queue_work - add work onto the mac80211 workqueue
5925 * ieee80211_queue_delayed_work - add work onto the mac80211 workqueue
5939 * ieee80211_start_tx_ba_session - Start a tx Block Ack session.
5954 * ieee80211_start_tx_ba_cb_irqsafe - low level driver ready to aggregate.
5967 * ieee80211_stop_tx_ba_session - Stop a Block Ack session.
5980 * ieee80211_stop_tx_ba_cb_irqsafe - low level driver ready to stop aggregate.
5993 * ieee80211_find_sta - find a station
6007 * ieee80211_find_sta_by_ifaddr - find a station on hardware
6011 * @localaddr: local address (vif->sdata->vif.addr). Use NULL for 'any'.
6033 * ieee80211_find_sta_by_link_addrs - find STA by link addresses
6049 * ieee80211_sta_block_awake - block station from waking up
6060 * This function allows implementing this mode in a race-free
6070 * cause mac80211 to be able to send ps-poll responses, and if
6081 * ieee80211_sta_eosp - notify mac80211 about end of SP
6087 * This applies for PS-Poll as well as uAPSD.
6090 * not mix calls to irqsafe/non-irqsafe versions, this function
6092 * all non-irqsafe, don't mix!
6102 * ieee80211_send_eosp_nullfunc - ask mac80211 to send NDP with EOSP
6115 * will be sent despite the station being in power-save.
6124 * ieee80211_sta_recalc_aggregates - recalculate aggregate data after a change
6127 * Call this function after changing a per-link aggregate data as referenced in
6137 * ieee80211_sta_register_airtime - register airtime usage for a sta/tid
6165 * ieee80211_txq_airtime_check - check if a txq can send frame to device
6177 * ieee80211_iter_keys - iterate keys programmed into the device
6204 * ieee80211_iter_keys_rcu - iterate keys programmed into the device
6228 * ieee80211_iter_chan_contexts_atomic - iterate channel contexts
6243 * found while iterating, whether they've been re-added already
6254 * ieee80211_ap_probereq_get - retrieve a Probe Request template
6271 * ieee80211_beacon_loss - inform hardware does not receive beacons
6282 * ieee80211_connection_loss - inform hardware has lost connection to the AP
6298 * ieee80211_disconnect - request disconnection
6309 * ieee80211_resume_disconnect - disconnect from AP after resume
6332 * ieee80211_hw_restart_disconnect - disconnect from AP after
6342 * ieee80211_cqm_rssi_notify - inform a configured connection quality monitoring
6360 * ieee80211_cqm_beacon_loss_notify - inform CQM of beacon loss
6368 * ieee80211_radar_detected - inform that a radar was detected
6375 * ieee80211_chswitch_done - Complete channel switch process
6379 * Complete the channel switch post-process: set the new operational channel
6385 * ieee80211_channel_switch_disconnect - disconnect due to channel switch error
6397 * ieee80211_request_smps - request SM PS transition
6410 * ieee80211_ready_on_channel - notification of remain-on-channel start
6416 * ieee80211_remain_on_channel_expired - remain_on_channel duration expired
6422 * ieee80211_stop_rx_ba_session - callback to stop existing BA sessions
6429 * therefore prevent the peer device to use a-mpdu aggregation.
6439 * ieee80211_mark_rx_ba_filtered_frames - move RX BA window and mark filtered
6457 * ieee80211_send_bar - send a BlockAckReq frame
6470 * ieee80211_manage_rx_ba_offl - helper to queue an RX BA work
6479 * ieee80211_start_rx_ba_session_offl - start a Rx BA session
6501 * ieee80211_stop_rx_ba_session_offl - stop a Rx BA session
6523 * ieee80211_rx_ba_timer_expired - stop a Rx BA session due to timeout
6540 * struct ieee80211_tx_rate_control - rate control information for/from RC algo
6552 * @short_preamble: whether mac80211 will request short-preamble transmission
6554 * @rate_idx_mask: user-requested (legacy) rate mask
6555 * @rate_idx_mcs_mask: user-requested MCS rate mask (NULL if not in use)
6571 * enum rate_control_capabilities - rate control capabilities
6584 * mac80211 should start A-MPDU sessions on tx
6627 return (sta == NULL || sta->deflink.supp_rates[band] & BIT(index)); in rate_supported()
6636 for (i = 0; i < sband->n_bitrates; i++) in rate_lowest_index()
6637 if (rate_supported(sta, sband->band, i)) in rate_lowest_index()
6653 for (i = 0; i < sband->n_bitrates; i++) in rate_usable_index_exists()
6654 if (rate_supported(sta, sband->band, i)) in rate_usable_index_exists()
6660 * rate_control_set_rates - pass the sta rate selection to mac80211/driver
6681 return conf->chandef.width == NL80211_CHAN_WIDTH_20; in conf_is_ht20()
6687 return conf->chandef.width == NL80211_CHAN_WIDTH_40 && in conf_is_ht40_minus()
6688 conf->chandef.center_freq1 < conf->chandef.chan->center_freq; in conf_is_ht40_minus()
6694 return conf->chandef.width == NL80211_CHAN_WIDTH_40 && in conf_is_ht40_plus()
6695 conf->chandef.center_freq1 > conf->chandef.chan->center_freq; in conf_is_ht40_plus()
6701 return conf->chandef.width == NL80211_CHAN_WIDTH_40; in conf_is_ht40()
6707 return (conf->chandef.width != NL80211_CHAN_WIDTH_5) && in conf_is_ht()
6708 (conf->chandef.width != NL80211_CHAN_WIDTH_10) && in conf_is_ht()
6709 (conf->chandef.width != NL80211_CHAN_WIDTH_20_NOHT); in conf_is_ht()
6731 return ieee80211_iftype_p2p(vif->type, vif->p2p); in ieee80211_vif_type_p2p()
6735 * ieee80211_update_mu_groups - set the VHT MU-MIMO groud data
6739 * @membership: 64 bits array - a bit is set if station is member of the group
6757 * ieee80211_ave_rssi - report the average RSSI for the specified interface
6769 * ieee80211_report_wowlan_wakeup - report WoWLAN wakeup
6781 * ieee80211_tx_prepare_skb - prepare an 802.11 skb for transmission
6795 * ieee80211_parse_tx_radiotap - Sanity-check and parse the radiotap header
6809 * struct ieee80211_noa_data - holds temporary data for tracking P2P NoA state
6836 * ieee80211_parse_p2p_noa - initialize NoA tracking data from P2P IE
6848 * ieee80211_update_p2p_noa - get next pending P2P GO absent state change
6856 * ieee80211_tdls_oper_request - request userspace to perform a TDLS operation
6870 * ieee80211_reserve_tid - request to reserve a specific TID
6891 * ieee80211_unreserve_tid - request to unreserve a specific TID
6907 * ieee80211_tx_dequeue - dequeue a packet from a software tx queue
6917 * skb->cb, e.g. the key pointer, are protected by RCU and thus the
6930 * ieee80211_tx_dequeue_ni - dequeue a packet from a software tx queue
6953 * ieee80211_next_txq - get next tx queue to pull packets from
6965 * ieee80211_txq_schedule_start - start new scheduling round for TXQs
6984 * ieee80211_schedule_txq - schedule a TXQ for transmission
7002 * ieee80211_return_txq - return a TXQ previously acquired by ieee80211_next_txq()
7019 * ieee80211_txq_may_transmit - check whether TXQ is allowed to transmit
7033 * aligned against driver's own round-robin scheduler list. i.e it rotates
7046 * ieee80211_txq_get_depth - get pending frame/byte count of given txq
7049 * txq state can change half-way of this function and the caller may end up
7050 * with "new" frame_cnt and "old" byte_cnt or vice-versa.
7061 * ieee80211_nan_func_terminated - notify about NAN function termination.
7077 * ieee80211_nan_func_match - notify about NAN function match event.
7092 * ieee80211_calc_rx_airtime - calculate estimated transmission airtime for RX.
7107 * ieee80211_calc_tx_airtime - calculate estimated transmission airtime for TX.
7120 * ieee80211_set_hw_80211_encap - enable hardware encapsulation offloading.
7132 * ieee80211_get_fils_discovery_tmpl - Get FILS discovery template.
7144 * ieee80211_get_unsol_bcast_probe_resp_tmpl - Get unsolicited broadcast
7158 * ieeee80211_obss_color_collision_notify - notify userland about a BSS color
7171 * ieee80211_is_tx_data - check if frame is a data frame
7181 struct ieee80211_hdr *hdr = (void *) skb->data; in ieee80211_is_tx_data()
7183 return info->flags & IEEE80211_TX_CTL_HW_80211_ENCAP || in ieee80211_is_tx_data()
7184 ieee80211_is_data(hdr->frame_control); in ieee80211_is_tx_data()
7188 * ieee80211_set_active_links - set active links in client mode
7199 * - change_vif_links(0x11)
7200 * - unassign_vif_chanctx(link_id=0)
7201 * - change_sta_links(0x11) for each affected STA (the AP)
7203 * - remove group keys on the old link (link_id 0)
7204 * - add new group keys (GTK/IGTK/BIGTK) on the new link (link_id 4)
7205 * - change_sta_links(0x10) for each affected STA (the AP)
7206 * - assign_vif_chanctx(link_id=4)
7207 * - change_vif_links(0x10)
7216 * ieee80211_set_active_links_async - asynchronously set active links