![]() |
|
|||
0001 /* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ 0002 /* 0003 * Copyright (C) 2012-2014, 2018-2021 Intel Corporation 0004 * Copyright (C) 2017 Intel Deutschland GmbH 0005 */ 0006 #ifndef __iwl_fw_api_mac_h__ 0007 #define __iwl_fw_api_mac_h__ 0008 0009 /* 0010 * The first MAC indices (starting from 0) are available to the driver, 0011 * AUX indices follows - 1 for non-CDB, 2 for CDB. 0012 */ 0013 #define MAC_INDEX_AUX 4 0014 #define MAC_INDEX_MIN_DRIVER 0 0015 #define NUM_MAC_INDEX_DRIVER MAC_INDEX_AUX 0016 #define NUM_MAC_INDEX (NUM_MAC_INDEX_DRIVER + 1) 0017 #define NUM_MAC_INDEX_CDB (NUM_MAC_INDEX_DRIVER + 2) 0018 0019 #define IWL_MVM_STATION_COUNT_MAX 16 0020 #define IWL_MVM_INVALID_STA 0xFF 0021 0022 enum iwl_ac { 0023 AC_BK, 0024 AC_BE, 0025 AC_VI, 0026 AC_VO, 0027 AC_NUM, 0028 }; 0029 0030 /** 0031 * enum iwl_mac_protection_flags - MAC context flags 0032 * @MAC_PROT_FLG_TGG_PROTECT: 11g protection when transmitting OFDM frames, 0033 * this will require CCK RTS/CTS2self. 0034 * RTS/CTS will protect full burst time. 0035 * @MAC_PROT_FLG_HT_PROT: enable HT protection 0036 * @MAC_PROT_FLG_FAT_PROT: protect 40 MHz transmissions 0037 * @MAC_PROT_FLG_SELF_CTS_EN: allow CTS2self 0038 */ 0039 enum iwl_mac_protection_flags { 0040 MAC_PROT_FLG_TGG_PROTECT = BIT(3), 0041 MAC_PROT_FLG_HT_PROT = BIT(23), 0042 MAC_PROT_FLG_FAT_PROT = BIT(24), 0043 MAC_PROT_FLG_SELF_CTS_EN = BIT(30), 0044 }; 0045 0046 #define MAC_FLG_SHORT_SLOT BIT(4) 0047 #define MAC_FLG_SHORT_PREAMBLE BIT(5) 0048 0049 /** 0050 * enum iwl_mac_types - Supported MAC types 0051 * @FW_MAC_TYPE_FIRST: lowest supported MAC type 0052 * @FW_MAC_TYPE_AUX: Auxiliary MAC (internal) 0053 * @FW_MAC_TYPE_LISTENER: monitor MAC type (?) 0054 * @FW_MAC_TYPE_PIBSS: Pseudo-IBSS 0055 * @FW_MAC_TYPE_IBSS: IBSS 0056 * @FW_MAC_TYPE_BSS_STA: BSS (managed) station 0057 * @FW_MAC_TYPE_P2P_DEVICE: P2P Device 0058 * @FW_MAC_TYPE_P2P_STA: P2P client 0059 * @FW_MAC_TYPE_GO: P2P GO 0060 * @FW_MAC_TYPE_TEST: ? 0061 * @FW_MAC_TYPE_MAX: highest support MAC type 0062 */ 0063 enum iwl_mac_types { 0064 FW_MAC_TYPE_FIRST = 1, 0065 FW_MAC_TYPE_AUX = FW_MAC_TYPE_FIRST, 0066 FW_MAC_TYPE_LISTENER, 0067 FW_MAC_TYPE_PIBSS, 0068 FW_MAC_TYPE_IBSS, 0069 FW_MAC_TYPE_BSS_STA, 0070 FW_MAC_TYPE_P2P_DEVICE, 0071 FW_MAC_TYPE_P2P_STA, 0072 FW_MAC_TYPE_GO, 0073 FW_MAC_TYPE_TEST, 0074 FW_MAC_TYPE_MAX = FW_MAC_TYPE_TEST 0075 }; /* MAC_CONTEXT_TYPE_API_E_VER_1 */ 0076 0077 /** 0078 * enum iwl_tsf_id - TSF hw timer ID 0079 * @TSF_ID_A: use TSF A 0080 * @TSF_ID_B: use TSF B 0081 * @TSF_ID_C: use TSF C 0082 * @TSF_ID_D: use TSF D 0083 * @NUM_TSF_IDS: number of TSF timers available 0084 */ 0085 enum iwl_tsf_id { 0086 TSF_ID_A = 0, 0087 TSF_ID_B = 1, 0088 TSF_ID_C = 2, 0089 TSF_ID_D = 3, 0090 NUM_TSF_IDS = 4, 0091 }; /* TSF_ID_API_E_VER_1 */ 0092 0093 /** 0094 * struct iwl_mac_data_ap - configuration data for AP MAC context 0095 * @beacon_time: beacon transmit time in system time 0096 * @beacon_tsf: beacon transmit time in TSF 0097 * @bi: beacon interval in TU 0098 * @reserved1: reserved 0099 * @dtim_interval: dtim transmit time in TU 0100 * @reserved2: reserved 0101 * @mcast_qid: queue ID for multicast traffic. 0102 * NOTE: obsolete from VER2 and on 0103 * @beacon_template: beacon template ID 0104 */ 0105 struct iwl_mac_data_ap { 0106 __le32 beacon_time; 0107 __le64 beacon_tsf; 0108 __le32 bi; 0109 __le32 reserved1; 0110 __le32 dtim_interval; 0111 __le32 reserved2; 0112 __le32 mcast_qid; 0113 __le32 beacon_template; 0114 } __packed; /* AP_MAC_DATA_API_S_VER_2 */ 0115 0116 /** 0117 * struct iwl_mac_data_ibss - configuration data for IBSS MAC context 0118 * @beacon_time: beacon transmit time in system time 0119 * @beacon_tsf: beacon transmit time in TSF 0120 * @bi: beacon interval in TU 0121 * @reserved: reserved 0122 * @beacon_template: beacon template ID 0123 */ 0124 struct iwl_mac_data_ibss { 0125 __le32 beacon_time; 0126 __le64 beacon_tsf; 0127 __le32 bi; 0128 __le32 reserved; 0129 __le32 beacon_template; 0130 } __packed; /* IBSS_MAC_DATA_API_S_VER_1 */ 0131 0132 /** 0133 * enum iwl_mac_data_policy - policy of the data path for this MAC 0134 * @TWT_SUPPORTED: twt is supported 0135 * @MORE_DATA_ACK_SUPPORTED: AP supports More Data Ack according to 0136 * paragraph 9.4.1.17 in P802.11ax_D4 specification. Used for TWT 0137 * early termination detection. 0138 * @FLEXIBLE_TWT_SUPPORTED: AP supports flexible TWT schedule 0139 * @PROTECTED_TWT_SUPPORTED: AP supports protected TWT frames (with 11w) 0140 * @BROADCAST_TWT_SUPPORTED: AP and STA support broadcast TWT 0141 * @COEX_HIGH_PRIORITY_ENABLE: high priority mode for BT coex, to be used 0142 * during 802.1X negotiation (and allowed during 4-way-HS) 0143 */ 0144 enum iwl_mac_data_policy { 0145 TWT_SUPPORTED = BIT(0), 0146 MORE_DATA_ACK_SUPPORTED = BIT(1), 0147 FLEXIBLE_TWT_SUPPORTED = BIT(2), 0148 PROTECTED_TWT_SUPPORTED = BIT(3), 0149 BROADCAST_TWT_SUPPORTED = BIT(4), 0150 COEX_HIGH_PRIORITY_ENABLE = BIT(5), 0151 }; 0152 0153 /** 0154 * struct iwl_mac_data_sta - configuration data for station MAC context 0155 * @is_assoc: 1 for associated state, 0 otherwise 0156 * @dtim_time: DTIM arrival time in system time 0157 * @dtim_tsf: DTIM arrival time in TSF 0158 * @bi: beacon interval in TU, applicable only when associated 0159 * @reserved1: reserved 0160 * @dtim_interval: DTIM interval in TU, applicable only when associated 0161 * @data_policy: see &enum iwl_mac_data_policy 0162 * @listen_interval: in beacon intervals, applicable only when associated 0163 * @assoc_id: unique ID assigned by the AP during association 0164 * @assoc_beacon_arrive_time: TSF of first beacon after association 0165 */ 0166 struct iwl_mac_data_sta { 0167 __le32 is_assoc; 0168 __le32 dtim_time; 0169 __le64 dtim_tsf; 0170 __le32 bi; 0171 __le32 reserved1; 0172 __le32 dtim_interval; 0173 __le32 data_policy; 0174 __le32 listen_interval; 0175 __le32 assoc_id; 0176 __le32 assoc_beacon_arrive_time; 0177 } __packed; /* STA_MAC_DATA_API_S_VER_2 */ 0178 0179 /** 0180 * struct iwl_mac_data_go - configuration data for P2P GO MAC context 0181 * @ap: iwl_mac_data_ap struct with most config data 0182 * @ctwin: client traffic window in TU (period after TBTT when GO is present). 0183 * 0 indicates that there is no CT window. 0184 * @opp_ps_enabled: indicate that opportunistic PS allowed 0185 */ 0186 struct iwl_mac_data_go { 0187 struct iwl_mac_data_ap ap; 0188 __le32 ctwin; 0189 __le32 opp_ps_enabled; 0190 } __packed; /* GO_MAC_DATA_API_S_VER_1 */ 0191 0192 /** 0193 * struct iwl_mac_data_p2p_sta - configuration data for P2P client MAC context 0194 * @sta: iwl_mac_data_sta struct with most config data 0195 * @ctwin: client traffic window in TU (period after TBTT when GO is present). 0196 * 0 indicates that there is no CT window. 0197 */ 0198 struct iwl_mac_data_p2p_sta { 0199 struct iwl_mac_data_sta sta; 0200 __le32 ctwin; 0201 } __packed; /* P2P_STA_MAC_DATA_API_S_VER_2 */ 0202 0203 /** 0204 * struct iwl_mac_data_pibss - Pseudo IBSS config data 0205 * @stats_interval: interval in TU between statistics notifications to host. 0206 */ 0207 struct iwl_mac_data_pibss { 0208 __le32 stats_interval; 0209 } __packed; /* PIBSS_MAC_DATA_API_S_VER_1 */ 0210 0211 /* 0212 * struct iwl_mac_data_p2p_dev - configuration data for the P2P Device MAC 0213 * context. 0214 * @is_disc_extended: if set to true, P2P Device discoverability is enabled on 0215 * other channels as well. This should be to true only in case that the 0216 * device is discoverable and there is an active GO. Note that setting this 0217 * field when not needed, will increase the number of interrupts and have 0218 * effect on the platform power, as this setting opens the Rx filters on 0219 * all macs. 0220 */ 0221 struct iwl_mac_data_p2p_dev { 0222 __le32 is_disc_extended; 0223 } __packed; /* _P2P_DEV_MAC_DATA_API_S_VER_1 */ 0224 0225 /** 0226 * enum iwl_mac_filter_flags - MAC context filter flags 0227 * @MAC_FILTER_IN_PROMISC: accept all data frames 0228 * @MAC_FILTER_IN_CONTROL_AND_MGMT: pass all management and 0229 * control frames to the host 0230 * @MAC_FILTER_ACCEPT_GRP: accept multicast frames 0231 * @MAC_FILTER_DIS_DECRYPT: don't decrypt unicast frames 0232 * @MAC_FILTER_DIS_GRP_DECRYPT: don't decrypt multicast frames 0233 * @MAC_FILTER_IN_BEACON: transfer foreign BSS's beacons to host 0234 * (in station mode when associated) 0235 * @MAC_FILTER_OUT_BCAST: filter out all broadcast frames 0236 * @MAC_FILTER_IN_CRC32: extract FCS and append it to frames 0237 * @MAC_FILTER_IN_PROBE_REQUEST: pass probe requests to host 0238 */ 0239 enum iwl_mac_filter_flags { 0240 MAC_FILTER_IN_PROMISC = BIT(0), 0241 MAC_FILTER_IN_CONTROL_AND_MGMT = BIT(1), 0242 MAC_FILTER_ACCEPT_GRP = BIT(2), 0243 MAC_FILTER_DIS_DECRYPT = BIT(3), 0244 MAC_FILTER_DIS_GRP_DECRYPT = BIT(4), 0245 MAC_FILTER_IN_BEACON = BIT(6), 0246 MAC_FILTER_OUT_BCAST = BIT(8), 0247 MAC_FILTER_IN_CRC32 = BIT(11), 0248 MAC_FILTER_IN_PROBE_REQUEST = BIT(12), 0249 /** 0250 * @MAC_FILTER_IN_11AX: mark BSS as supporting 802.11ax 0251 */ 0252 MAC_FILTER_IN_11AX = BIT(14), 0253 }; 0254 0255 /** 0256 * enum iwl_mac_qos_flags - QoS flags 0257 * @MAC_QOS_FLG_UPDATE_EDCA: ? 0258 * @MAC_QOS_FLG_TGN: HT is enabled 0259 * @MAC_QOS_FLG_TXOP_TYPE: ? 0260 * 0261 */ 0262 enum iwl_mac_qos_flags { 0263 MAC_QOS_FLG_UPDATE_EDCA = BIT(0), 0264 MAC_QOS_FLG_TGN = BIT(1), 0265 MAC_QOS_FLG_TXOP_TYPE = BIT(4), 0266 }; 0267 0268 /** 0269 * struct iwl_ac_qos - QOS timing params for MAC_CONTEXT_CMD 0270 * @cw_min: Contention window, start value in numbers of slots. 0271 * Should be a power-of-2, minus 1. Device's default is 0x0f. 0272 * @cw_max: Contention window, max value in numbers of slots. 0273 * Should be a power-of-2, minus 1. Device's default is 0x3f. 0274 * @aifsn: Number of slots in Arbitration Interframe Space (before 0275 * performing random backoff timing prior to Tx). Device default 1. 0276 * @fifos_mask: FIFOs used by this MAC for this AC 0277 * @edca_txop: Length of Tx opportunity, in uSecs. Device default is 0. 0278 * 0279 * One instance of this config struct for each of 4 EDCA access categories 0280 * in struct iwl_qosparam_cmd. 0281 * 0282 * Device will automatically increase contention window by (2*CW) + 1 for each 0283 * transmission retry. Device uses cw_max as a bit mask, ANDed with new CW 0284 * value, to cap the CW value. 0285 */ 0286 struct iwl_ac_qos { 0287 __le16 cw_min; 0288 __le16 cw_max; 0289 u8 aifsn; 0290 u8 fifos_mask; 0291 __le16 edca_txop; 0292 } __packed; /* AC_QOS_API_S_VER_2 */ 0293 0294 /** 0295 * struct iwl_mac_ctx_cmd - command structure to configure MAC contexts 0296 * ( MAC_CONTEXT_CMD = 0x28 ) 0297 * @id_and_color: ID and color of the MAC 0298 * @action: action to perform, one of FW_CTXT_ACTION_* 0299 * @mac_type: one of &enum iwl_mac_types 0300 * @tsf_id: TSF HW timer, one of &enum iwl_tsf_id 0301 * @node_addr: MAC address 0302 * @reserved_for_node_addr: reserved 0303 * @bssid_addr: BSSID 0304 * @reserved_for_bssid_addr: reserved 0305 * @cck_rates: basic rates available for CCK 0306 * @ofdm_rates: basic rates available for OFDM 0307 * @protection_flags: combination of &enum iwl_mac_protection_flags 0308 * @cck_short_preamble: 0x20 for enabling short preamble, 0 otherwise 0309 * @short_slot: 0x10 for enabling short slots, 0 otherwise 0310 * @filter_flags: combination of &enum iwl_mac_filter_flags 0311 * @qos_flags: from &enum iwl_mac_qos_flags 0312 * @ac: one iwl_mac_qos configuration for each AC 0313 */ 0314 struct iwl_mac_ctx_cmd { 0315 /* COMMON_INDEX_HDR_API_S_VER_1 */ 0316 __le32 id_and_color; 0317 __le32 action; 0318 /* MAC_CONTEXT_COMMON_DATA_API_S_VER_1 */ 0319 __le32 mac_type; 0320 __le32 tsf_id; 0321 u8 node_addr[6]; 0322 __le16 reserved_for_node_addr; 0323 u8 bssid_addr[6]; 0324 __le16 reserved_for_bssid_addr; 0325 __le32 cck_rates; 0326 __le32 ofdm_rates; 0327 __le32 protection_flags; 0328 __le32 cck_short_preamble; 0329 __le32 short_slot; 0330 __le32 filter_flags; 0331 /* MAC_QOS_PARAM_API_S_VER_1 */ 0332 __le32 qos_flags; 0333 struct iwl_ac_qos ac[AC_NUM+1]; 0334 /* MAC_CONTEXT_COMMON_DATA_API_S */ 0335 union { 0336 struct iwl_mac_data_ap ap; 0337 struct iwl_mac_data_go go; 0338 struct iwl_mac_data_sta sta; 0339 struct iwl_mac_data_p2p_sta p2p_sta; 0340 struct iwl_mac_data_p2p_dev p2p_dev; 0341 struct iwl_mac_data_pibss pibss; 0342 struct iwl_mac_data_ibss ibss; 0343 }; 0344 } __packed; /* MAC_CONTEXT_CMD_API_S_VER_1 */ 0345 0346 #define IWL_NONQOS_SEQ_GET 0x1 0347 #define IWL_NONQOS_SEQ_SET 0x2 0348 struct iwl_nonqos_seq_query_cmd { 0349 __le32 get_set_flag; 0350 __le32 mac_id_n_color; 0351 __le16 value; 0352 __le16 reserved; 0353 } __packed; /* NON_QOS_TX_COUNTER_GET_SET_API_S_VER_1 */ 0354 0355 /** 0356 * struct iwl_missed_beacons_notif - information on missed beacons 0357 * ( MISSED_BEACONS_NOTIFICATION = 0xa2 ) 0358 * @mac_id: interface ID 0359 * @consec_missed_beacons_since_last_rx: number of consecutive missed 0360 * beacons since last RX. 0361 * @consec_missed_beacons: number of consecutive missed beacons 0362 * @num_expected_beacons: number of expected beacons 0363 * @num_recvd_beacons: number of received beacons 0364 */ 0365 struct iwl_missed_beacons_notif { 0366 __le32 mac_id; 0367 __le32 consec_missed_beacons_since_last_rx; 0368 __le32 consec_missed_beacons; 0369 __le32 num_expected_beacons; 0370 __le32 num_recvd_beacons; 0371 } __packed; /* MISSED_BEACON_NTFY_API_S_VER_3 */ 0372 0373 /** 0374 * struct iwl_he_backoff_conf - used for backoff configuration 0375 * Per each trigger-based AC, (set by MU EDCA Parameter set info-element) 0376 * used for backoff configuration of TXF5..TXF8 trigger based. 0377 * The MU-TIMER is reloaded w/ MU_TIME each time a frame from the AC is sent via 0378 * trigger-based TX. 0379 * @cwmin: CW min 0380 * @cwmax: CW max 0381 * @aifsn: AIFSN 0382 * AIFSN=0, means that no backoff from the specified TRIG-BASED AC is 0383 * allowed till the MU-TIMER is 0 0384 * @mu_time: MU time in 8TU units 0385 */ 0386 struct iwl_he_backoff_conf { 0387 __le16 cwmin; 0388 __le16 cwmax; 0389 __le16 aifsn; 0390 __le16 mu_time; 0391 } __packed; /* AC_QOS_DOT11AX_API_S */ 0392 0393 /** 0394 * enum iwl_he_pkt_ext_constellations - PPE constellation indices 0395 * @IWL_HE_PKT_EXT_BPSK: BPSK 0396 * @IWL_HE_PKT_EXT_QPSK: QPSK 0397 * @IWL_HE_PKT_EXT_16QAM: 16-QAM 0398 * @IWL_HE_PKT_EXT_64QAM: 64-QAM 0399 * @IWL_HE_PKT_EXT_256QAM: 256-QAM 0400 * @IWL_HE_PKT_EXT_1024QAM: 1024-QAM 0401 * @IWL_HE_PKT_EXT_RESERVED: reserved value 0402 * @IWL_HE_PKT_EXT_NONE: not defined 0403 */ 0404 enum iwl_he_pkt_ext_constellations { 0405 IWL_HE_PKT_EXT_BPSK = 0, 0406 IWL_HE_PKT_EXT_QPSK, 0407 IWL_HE_PKT_EXT_16QAM, 0408 IWL_HE_PKT_EXT_64QAM, 0409 IWL_HE_PKT_EXT_256QAM, 0410 IWL_HE_PKT_EXT_1024QAM, 0411 IWL_HE_PKT_EXT_RESERVED, 0412 IWL_HE_PKT_EXT_NONE, 0413 }; 0414 0415 #define MAX_HE_SUPP_NSS 2 0416 #define MAX_CHANNEL_BW_INDX_API_D_VER_2 4 0417 #define MAX_CHANNEL_BW_INDX_API_D_VER_3 5 0418 0419 /** 0420 * struct iwl_he_pkt_ext_v1 - QAM thresholds 0421 * The required PPE is set via HE Capabilities IE, per Nss x BW x MCS 0422 * The IE is organized in the following way: 0423 * Support for Nss x BW (or RU) matrix: 0424 * (0=SISO, 1=MIMO2) x (0-20MHz, 1-40MHz, 2-80MHz, 3-160MHz) 0425 * Each entry contains 2 QAM thresholds for 8us and 16us: 0426 * 0=BPSK, 1=QPSK, 2=16QAM, 3=64QAM, 4=256QAM, 5=1024QAM, 6=RES, 7=NONE 0427 * i.e. QAM_th1 < QAM_th2 such if TX uses QAM_tx: 0428 * QAM_tx < QAM_th1 --> PPE=0us 0429 * QAM_th1 <= QAM_tx < QAM_th2 --> PPE=8us 0430 * QAM_th2 <= QAM_tx --> PPE=16us 0431 * @pkt_ext_qam_th: QAM thresholds 0432 * For each Nss/Bw define 2 QAM thrsholds (0..5) 0433 * For rates below the low_th, no need for PPE 0434 * For rates between low_th and high_th, need 8us PPE 0435 * For rates equal or higher then the high_th, need 16us PPE 0436 * Nss (0-siso, 1-mimo2) x BW (0-20MHz, 1-40MHz, 2-80MHz, 3-160MHz) x 0437 * (0-low_th, 1-high_th) 0438 */ 0439 struct iwl_he_pkt_ext_v1 { 0440 u8 pkt_ext_qam_th[MAX_HE_SUPP_NSS][MAX_CHANNEL_BW_INDX_API_D_VER_2][2]; 0441 } __packed; /* PKT_EXT_DOT11AX_API_S_VER_1 */ 0442 0443 /** 0444 * struct iwl_he_pkt_ext_v2 - QAM thresholds 0445 * The required PPE is set via HE Capabilities IE, per Nss x BW x MCS 0446 * The IE is organized in the following way: 0447 * Support for Nss x BW (or RU) matrix: 0448 * (0=SISO, 1=MIMO2) x (0-20MHz, 1-40MHz, 2-80MHz, 3-160MHz) 0449 * Each entry contains 2 QAM thresholds for 8us and 16us: 0450 * 0=BPSK, 1=QPSK, 2=16QAM, 3=64QAM, 4=256QAM, 5=1024QAM, 6=RES, 7=NONE 0451 * i.e. QAM_th1 < QAM_th2 such if TX uses QAM_tx: 0452 * QAM_tx < QAM_th1 --> PPE=0us 0453 * QAM_th1 <= QAM_tx < QAM_th2 --> PPE=8us 0454 * QAM_th2 <= QAM_tx --> PPE=16us 0455 * @pkt_ext_qam_th: QAM thresholds 0456 * For each Nss/Bw define 2 QAM thrsholds (0..5) 0457 * For rates below the low_th, no need for PPE 0458 * For rates between low_th and high_th, need 8us PPE 0459 * For rates equal or higher then the high_th, need 16us PPE 0460 * Nss (0-siso, 1-mimo2) x 0461 * BW (0-20MHz, 1-40MHz, 2-80MHz, 3-160MHz, 4-320MHz) x 0462 * (0-low_th, 1-high_th) 0463 */ 0464 struct iwl_he_pkt_ext_v2 { 0465 u8 pkt_ext_qam_th[MAX_HE_SUPP_NSS][MAX_CHANNEL_BW_INDX_API_D_VER_3][2]; 0466 } __packed; /* PKT_EXT_DOT11AX_API_S_VER_2 */ 0467 0468 /** 0469 * enum iwl_he_sta_ctxt_flags - HE STA context flags 0470 * @STA_CTXT_HE_REF_BSSID_VALID: ref bssid addr valid (for receiving specific 0471 * control frames such as TRIG, NDPA, BACK) 0472 * @STA_CTXT_HE_BSS_COLOR_DIS: BSS color disable, don't use the BSS 0473 * color for RX filter but use MAC header 0474 * @STA_CTXT_HE_PARTIAL_BSS_COLOR: partial BSS color allocation 0475 * @STA_CTXT_HE_32BIT_BA_BITMAP: indicates the receiver supports BA bitmap 0476 * of 32-bits 0477 * @STA_CTXT_HE_PACKET_EXT: indicates that the packet-extension info is valid 0478 * and should be used 0479 * @STA_CTXT_HE_TRIG_RND_ALLOC: indicates that trigger based random allocation 0480 * is enabled according to UORA element existence 0481 * @STA_CTXT_HE_CONST_TRIG_RND_ALLOC: used for AV testing 0482 * @STA_CTXT_HE_ACK_ENABLED: indicates that the AP supports receiving ACK- 0483 * enabled AGG, i.e. both BACK and non-BACK frames in a single AGG 0484 * @STA_CTXT_HE_MU_EDCA_CW: indicates that there is an element of MU EDCA 0485 * parameter set, i.e. the backoff counters for trig-based ACs 0486 * @STA_CTXT_HE_NIC_NOT_ACK_ENABLED: mark that the NIC doesn't support receiving 0487 * ACK-enabled AGG, (i.e. both BACK and non-BACK frames in single AGG). 0488 * If the NIC is not ACK_ENABLED it may use the EOF-bit in first non-0 0489 * len delim to determine if AGG or single. 0490 * @STA_CTXT_HE_RU_2MHZ_BLOCK: indicates that 26-tone RU OFDMA transmission are 0491 * not allowed (as there are OBSS that might classify such transmissions as 0492 * radar pulses). 0493 * @STA_CTXT_HE_NDP_FEEDBACK_ENABLED: mark support for NDP feedback and change 0494 * of threshold 0495 * @STA_CTXT_EHT_PUNCTURE_MASK_VALID: indicates the puncture_mask field is valid 0496 * @STA_CTXT_EHT_LONG_PPE_ENABLED: indicates the PPE requirement should be 0497 * extended to 20us for BW > 160Mhz or for MCS w/ 4096-QAM. 0498 */ 0499 enum iwl_he_sta_ctxt_flags { 0500 STA_CTXT_HE_REF_BSSID_VALID = BIT(4), 0501 STA_CTXT_HE_BSS_COLOR_DIS = BIT(5), 0502 STA_CTXT_HE_PARTIAL_BSS_COLOR = BIT(6), 0503 STA_CTXT_HE_32BIT_BA_BITMAP = BIT(7), 0504 STA_CTXT_HE_PACKET_EXT = BIT(8), 0505 STA_CTXT_HE_TRIG_RND_ALLOC = BIT(9), 0506 STA_CTXT_HE_CONST_TRIG_RND_ALLOC = BIT(10), 0507 STA_CTXT_HE_ACK_ENABLED = BIT(11), 0508 STA_CTXT_HE_MU_EDCA_CW = BIT(12), 0509 STA_CTXT_HE_NIC_NOT_ACK_ENABLED = BIT(13), 0510 STA_CTXT_HE_RU_2MHZ_BLOCK = BIT(14), 0511 STA_CTXT_HE_NDP_FEEDBACK_ENABLED = BIT(15), 0512 STA_CTXT_EHT_PUNCTURE_MASK_VALID = BIT(16), 0513 STA_CTXT_EHT_LONG_PPE_ENABLED = BIT(17), 0514 }; 0515 0516 /** 0517 * enum iwl_he_htc_flags - HE HTC support flags 0518 * @IWL_HE_HTC_SUPPORT: HE-HTC support 0519 * @IWL_HE_HTC_UL_MU_RESP_SCHED: HE UL MU response schedule 0520 * support via A-control field 0521 * @IWL_HE_HTC_BSR_SUPP: BSR support in A-control field 0522 * @IWL_HE_HTC_OMI_SUPP: A-OMI support in A-control field 0523 * @IWL_HE_HTC_BQR_SUPP: A-BQR support in A-control field 0524 */ 0525 enum iwl_he_htc_flags { 0526 IWL_HE_HTC_SUPPORT = BIT(0), 0527 IWL_HE_HTC_UL_MU_RESP_SCHED = BIT(3), 0528 IWL_HE_HTC_BSR_SUPP = BIT(4), 0529 IWL_HE_HTC_OMI_SUPP = BIT(5), 0530 IWL_HE_HTC_BQR_SUPP = BIT(6), 0531 }; 0532 0533 /* 0534 * @IWL_HE_HTC_LINK_ADAP_NO_FEEDBACK: the STA does not provide HE MFB 0535 * @IWL_HE_HTC_LINK_ADAP_UNSOLICITED: the STA provides only unsolicited HE MFB 0536 * @IWL_HE_HTC_LINK_ADAP_BOTH: the STA is capable of providing HE MFB in 0537 * response to HE MRQ and if the STA provides unsolicited HE MFB 0538 */ 0539 #define IWL_HE_HTC_LINK_ADAP_POS (1) 0540 #define IWL_HE_HTC_LINK_ADAP_NO_FEEDBACK (0) 0541 #define IWL_HE_HTC_LINK_ADAP_UNSOLICITED (2 << IWL_HE_HTC_LINK_ADAP_POS) 0542 #define IWL_HE_HTC_LINK_ADAP_BOTH (3 << IWL_HE_HTC_LINK_ADAP_POS) 0543 0544 /** 0545 * struct iwl_he_sta_context_cmd_v1 - configure FW to work with HE AP 0546 * @sta_id: STA id 0547 * @tid_limit: max num of TIDs in TX HE-SU multi-TID agg 0548 * 0 - bad value, 1 - multi-tid not supported, 2..8 - tid limit 0549 * @reserved1: reserved byte for future use 0550 * @reserved2: reserved byte for future use 0551 * @flags: see %iwl_11ax_sta_ctxt_flags 0552 * @ref_bssid_addr: reference BSSID used by the AP 0553 * @reserved0: reserved 2 bytes for aligning the ref_bssid_addr field to 8 bytes 0554 * @htc_flags: which features are supported in HTC 0555 * @frag_flags: frag support in A-MSDU 0556 * @frag_level: frag support level 0557 * @frag_max_num: max num of "open" MSDUs in the receiver (in power of 2) 0558 * @frag_min_size: min frag size (except last frag) 0559 * @pkt_ext: optional, exists according to PPE-present bit in the HE-PHY capa 0560 * @bss_color: 11ax AP ID that is used in the HE SIG-A to mark inter BSS frame 0561 * @htc_trig_based_pkt_ext: default PE in 4us units 0562 * @frame_time_rts_th: HE duration RTS threshold, in units of 32us 0563 * @rand_alloc_ecwmin: random CWmin = 2**ECWmin-1 0564 * @rand_alloc_ecwmax: random CWmax = 2**ECWmax-1 0565 * @reserved3: reserved byte for future use 0566 * @trig_based_txf: MU EDCA Parameter set for the trigger based traffic queues 0567 */ 0568 struct iwl_he_sta_context_cmd_v1 { 0569 u8 sta_id; 0570 u8 tid_limit; 0571 u8 reserved1; 0572 u8 reserved2; 0573 __le32 flags; 0574 0575 /* The below fields are set via Multiple BSSID IE */ 0576 u8 ref_bssid_addr[6]; 0577 __le16 reserved0; 0578 0579 /* The below fields are set via HE-capabilities IE */ 0580 __le32 htc_flags; 0581 0582 u8 frag_flags; 0583 u8 frag_level; 0584 u8 frag_max_num; 0585 u8 frag_min_size; 0586 0587 /* The below fields are set via PPE thresholds element */ 0588 struct iwl_he_pkt_ext_v1 pkt_ext; 0589 0590 /* The below fields are set via HE-Operation IE */ 0591 u8 bss_color; 0592 u8 htc_trig_based_pkt_ext; 0593 __le16 frame_time_rts_th; 0594 0595 /* Random access parameter set (i.e. RAPS) */ 0596 u8 rand_alloc_ecwmin; 0597 u8 rand_alloc_ecwmax; 0598 __le16 reserved3; 0599 0600 /* The below fields are set via MU EDCA parameter set element */ 0601 struct iwl_he_backoff_conf trig_based_txf[AC_NUM]; 0602 } __packed; /* STA_CONTEXT_DOT11AX_API_S_VER_1 */ 0603 0604 /** 0605 * struct iwl_he_sta_context_cmd_v2 - configure FW to work with HE AP 0606 * @sta_id: STA id 0607 * @tid_limit: max num of TIDs in TX HE-SU multi-TID agg 0608 * 0 - bad value, 1 - multi-tid not supported, 2..8 - tid limit 0609 * @reserved1: reserved byte for future use 0610 * @reserved2: reserved byte for future use 0611 * @flags: see %iwl_11ax_sta_ctxt_flags 0612 * @ref_bssid_addr: reference BSSID used by the AP 0613 * @reserved0: reserved 2 bytes for aligning the ref_bssid_addr field to 8 bytes 0614 * @htc_flags: which features are supported in HTC 0615 * @frag_flags: frag support in A-MSDU 0616 * @frag_level: frag support level 0617 * @frag_max_num: max num of "open" MSDUs in the receiver (in power of 2) 0618 * @frag_min_size: min frag size (except last frag) 0619 * @pkt_ext: optional, exists according to PPE-present bit in the HE-PHY capa 0620 * @bss_color: 11ax AP ID that is used in the HE SIG-A to mark inter BSS frame 0621 * @htc_trig_based_pkt_ext: default PE in 4us units 0622 * @frame_time_rts_th: HE duration RTS threshold, in units of 32us 0623 * @rand_alloc_ecwmin: random CWmin = 2**ECWmin-1 0624 * @rand_alloc_ecwmax: random CWmax = 2**ECWmax-1 0625 * @reserved3: reserved byte for future use 0626 * @trig_based_txf: MU EDCA Parameter set for the trigger based traffic queues 0627 * @max_bssid_indicator: indicator of the max bssid supported on the associated 0628 * bss 0629 * @bssid_index: index of the associated VAP 0630 * @ema_ap: AP supports enhanced Multi BSSID advertisement 0631 * @profile_periodicity: number of Beacon periods that are needed to receive the 0632 * complete VAPs info 0633 * @bssid_count: actual number of VAPs in the MultiBSS Set 0634 * @reserved4: alignment 0635 */ 0636 struct iwl_he_sta_context_cmd_v2 { 0637 u8 sta_id; 0638 u8 tid_limit; 0639 u8 reserved1; 0640 u8 reserved2; 0641 __le32 flags; 0642 0643 /* The below fields are set via Multiple BSSID IE */ 0644 u8 ref_bssid_addr[6]; 0645 __le16 reserved0; 0646 0647 /* The below fields are set via HE-capabilities IE */ 0648 __le32 htc_flags; 0649 0650 u8 frag_flags; 0651 u8 frag_level; 0652 u8 frag_max_num; 0653 u8 frag_min_size; 0654 0655 /* The below fields are set via PPE thresholds element */ 0656 struct iwl_he_pkt_ext_v1 pkt_ext; 0657 0658 /* The below fields are set via HE-Operation IE */ 0659 u8 bss_color; 0660 u8 htc_trig_based_pkt_ext; 0661 __le16 frame_time_rts_th; 0662 0663 /* Random access parameter set (i.e. RAPS) */ 0664 u8 rand_alloc_ecwmin; 0665 u8 rand_alloc_ecwmax; 0666 __le16 reserved3; 0667 0668 /* The below fields are set via MU EDCA parameter set element */ 0669 struct iwl_he_backoff_conf trig_based_txf[AC_NUM]; 0670 0671 u8 max_bssid_indicator; 0672 u8 bssid_index; 0673 u8 ema_ap; 0674 u8 profile_periodicity; 0675 u8 bssid_count; 0676 u8 reserved4[3]; 0677 } __packed; /* STA_CONTEXT_DOT11AX_API_S_VER_2 */ 0678 0679 /** 0680 * struct iwl_he_sta_context_cmd_v3 - configure FW to work with HE AP 0681 * @sta_id: STA id 0682 * @tid_limit: max num of TIDs in TX HE-SU multi-TID agg 0683 * 0 - bad value, 1 - multi-tid not supported, 2..8 - tid limit 0684 * @reserved1: reserved byte for future use 0685 * @reserved2: reserved byte for future use 0686 * @flags: see %iwl_11ax_sta_ctxt_flags 0687 * @ref_bssid_addr: reference BSSID used by the AP 0688 * @reserved0: reserved 2 bytes for aligning the ref_bssid_addr field to 8 bytes 0689 * @htc_flags: which features are supported in HTC 0690 * @frag_flags: frag support in A-MSDU 0691 * @frag_level: frag support level 0692 * @frag_max_num: max num of "open" MSDUs in the receiver (in power of 2) 0693 * @frag_min_size: min frag size (except last frag) 0694 * @pkt_ext: optional, exists according to PPE-present bit in the HE-PHY capa 0695 * @bss_color: 11ax AP ID that is used in the HE SIG-A to mark inter BSS frame 0696 * @htc_trig_based_pkt_ext: default PE in 4us units 0697 * @frame_time_rts_th: HE duration RTS threshold, in units of 32us 0698 * @rand_alloc_ecwmin: random CWmin = 2**ECWmin-1 0699 * @rand_alloc_ecwmax: random CWmax = 2**ECWmax-1 0700 * @puncture_mask: puncture mask for EHT 0701 * @trig_based_txf: MU EDCA Parameter set for the trigger based traffic queues 0702 * @max_bssid_indicator: indicator of the max bssid supported on the associated 0703 * bss 0704 * @bssid_index: index of the associated VAP 0705 * @ema_ap: AP supports enhanced Multi BSSID advertisement 0706 * @profile_periodicity: number of Beacon periods that are needed to receive the 0707 * complete VAPs info 0708 * @bssid_count: actual number of VAPs in the MultiBSS Set 0709 * @reserved4: alignment 0710 */ 0711 struct iwl_he_sta_context_cmd_v3 { 0712 u8 sta_id; 0713 u8 tid_limit; 0714 u8 reserved1; 0715 u8 reserved2; 0716 __le32 flags; 0717 0718 /* The below fields are set via Multiple BSSID IE */ 0719 u8 ref_bssid_addr[6]; 0720 __le16 reserved0; 0721 0722 /* The below fields are set via HE-capabilities IE */ 0723 __le32 htc_flags; 0724 0725 u8 frag_flags; 0726 u8 frag_level; 0727 u8 frag_max_num; 0728 u8 frag_min_size; 0729 0730 /* The below fields are set via PPE thresholds element */ 0731 struct iwl_he_pkt_ext_v2 pkt_ext; 0732 0733 /* The below fields are set via HE-Operation IE */ 0734 u8 bss_color; 0735 u8 htc_trig_based_pkt_ext; 0736 __le16 frame_time_rts_th; 0737 0738 /* Random access parameter set (i.e. RAPS) */ 0739 u8 rand_alloc_ecwmin; 0740 u8 rand_alloc_ecwmax; 0741 __le16 puncture_mask; 0742 0743 /* The below fields are set via MU EDCA parameter set element */ 0744 struct iwl_he_backoff_conf trig_based_txf[AC_NUM]; 0745 0746 u8 max_bssid_indicator; 0747 u8 bssid_index; 0748 u8 ema_ap; 0749 u8 profile_periodicity; 0750 u8 bssid_count; 0751 u8 reserved4[3]; 0752 } __packed; /* STA_CONTEXT_DOT11AX_API_S_VER_2 */ 0753 0754 /** 0755 * struct iwl_he_monitor_cmd - configure air sniffer for HE 0756 * @bssid: the BSSID to sniff for 0757 * @reserved1: reserved for dword alignment 0758 * @aid: the AID to track on for HE MU 0759 * @reserved2: reserved for future use 0760 */ 0761 struct iwl_he_monitor_cmd { 0762 u8 bssid[6]; 0763 __le16 reserved1; 0764 __le16 aid; 0765 u8 reserved2[6]; 0766 } __packed; /* HE_AIR_SNIFFER_CONFIG_CMD_API_S_VER_1 */ 0767 0768 #endif /* __iwl_fw_api_mac_h__ */
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.1.0 LXR engine. The LXR team |
![]() ![]() |