Path: blob/main/sys/contrib/dev/iwlwifi/fw/api/txq.h
48425 views
/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */1/*2* Copyright (C) 2005-2014, 2019-2021, 2023-2024 Intel Corporation3* Copyright (C) 2013-2015 Intel Mobile Communications GmbH4* Copyright (C) 2016-2017 Intel Deutschland GmbH5*/6#ifndef __iwl_fw_api_txq_h__7#define __iwl_fw_api_txq_h__89/*10* DQA queue numbers11*12* @IWL_MVM_DQA_CMD_QUEUE: a queue reserved for sending HCMDs to the FW13* @IWL_MVM_DQA_AUX_QUEUE: a queue reserved for aux frames14* @IWL_MVM_DQA_P2P_DEVICE_QUEUE: a queue reserved for P2P device frames15* @IWL_MVM_DQA_INJECT_MONITOR_QUEUE: a queue reserved for injection using16* monitor mode. Note this queue is the same as the queue for P2P device17* but we can't have active monitor mode along with P2P device anyway.18* @IWL_MVM_DQA_GCAST_QUEUE: a queue reserved for P2P GO/SoftAP GCAST frames19* @IWL_MVM_DQA_BSS_CLIENT_QUEUE: a queue reserved for BSS activity, to ensure20* that we are never left without the possibility to connect to an AP.21* @IWL_MVM_DQA_MIN_MGMT_QUEUE: first TXQ in pool for MGMT and non-QOS frames.22* Each MGMT queue is mapped to a single STA23* MGMT frames are frames that return true on ieee80211_is_mgmt()24* @IWL_MVM_DQA_MAX_MGMT_QUEUE: last TXQ in pool for MGMT frames25* @IWL_MVM_DQA_AP_PROBE_RESP_QUEUE: a queue reserved for P2P GO/SoftAP probe26* responses27* @IWL_MVM_DQA_MIN_DATA_QUEUE: first TXQ in pool for DATA frames.28* DATA frames are intended for !ieee80211_is_mgmt() frames, but if29* the MGMT TXQ pool is exhausted, mgmt frames can be sent on DATA queues30* as well31* @IWL_MVM_DQA_MAX_DATA_QUEUE: last TXQ in pool for DATA frames32*/33enum iwl_mvm_dqa_txq {34IWL_MVM_DQA_CMD_QUEUE = 0,35IWL_MVM_DQA_AUX_QUEUE = 1,36IWL_MVM_DQA_P2P_DEVICE_QUEUE = 2,37IWL_MVM_DQA_INJECT_MONITOR_QUEUE = 2,38IWL_MVM_DQA_GCAST_QUEUE = 3,39IWL_MVM_DQA_BSS_CLIENT_QUEUE = 4,40IWL_MVM_DQA_MIN_MGMT_QUEUE = 5,41IWL_MVM_DQA_MAX_MGMT_QUEUE = 8,42IWL_MVM_DQA_AP_PROBE_RESP_QUEUE = 9,43IWL_MVM_DQA_MIN_DATA_QUEUE = 10,44IWL_MVM_DQA_MAX_DATA_QUEUE = 30,45};4647enum iwl_mvm_tx_fifo {48IWL_MVM_TX_FIFO_BK = 0,49IWL_MVM_TX_FIFO_BE,50IWL_MVM_TX_FIFO_VI,51IWL_MVM_TX_FIFO_VO,52IWL_MVM_TX_FIFO_MCAST = 5,53IWL_MVM_TX_FIFO_CMD = 7,54};5556enum iwl_gen2_tx_fifo {57IWL_GEN2_TX_FIFO_CMD = 0,58IWL_GEN2_EDCA_TX_FIFO_BK,59IWL_GEN2_EDCA_TX_FIFO_BE,60IWL_GEN2_EDCA_TX_FIFO_VI,61IWL_GEN2_EDCA_TX_FIFO_VO,62IWL_GEN2_TRIG_TX_FIFO_BK,63IWL_GEN2_TRIG_TX_FIFO_BE,64IWL_GEN2_TRIG_TX_FIFO_VI,65IWL_GEN2_TRIG_TX_FIFO_VO,66};6768enum iwl_bz_tx_fifo {69IWL_BZ_EDCA_TX_FIFO_BK,70IWL_BZ_EDCA_TX_FIFO_BE,71IWL_BZ_EDCA_TX_FIFO_VI,72IWL_BZ_EDCA_TX_FIFO_VO,73IWL_BZ_TRIG_TX_FIFO_BK,74IWL_BZ_TRIG_TX_FIFO_BE,75IWL_BZ_TRIG_TX_FIFO_VI,76IWL_BZ_TRIG_TX_FIFO_VO,77};78/**79* enum iwl_tx_queue_cfg_actions - TXQ config options80* @TX_QUEUE_CFG_ENABLE_QUEUE: enable a queue81* @TX_QUEUE_CFG_TFD_SHORT_FORMAT: use short TFD format82*/83enum iwl_tx_queue_cfg_actions {84TX_QUEUE_CFG_ENABLE_QUEUE = BIT(0),85TX_QUEUE_CFG_TFD_SHORT_FORMAT = BIT(1),86};8788#define IWL_DEFAULT_QUEUE_SIZE_EHT (512 * 4)89#define IWL_DEFAULT_QUEUE_SIZE_HE 102490#define IWL_DEFAULT_QUEUE_SIZE 25691#define IWL_MGMT_QUEUE_SIZE 1692#define IWL_CMD_QUEUE_SIZE 3293/**94* struct iwl_tx_queue_cfg_cmd - txq hw scheduler config command95* @sta_id: station id96* @tid: tid of the queue97* @flags: see &enum iwl_tx_queue_cfg_actions98* @cb_size: size of TFD cyclic buffer. Value is exponent - 3.99* Minimum value 0 (8 TFDs), maximum value 5 (256 TFDs)100* @byte_cnt_addr: address of byte count table101* @tfdq_addr: address of TFD circular buffer102*/103struct iwl_tx_queue_cfg_cmd {104u8 sta_id;105u8 tid;106__le16 flags;107__le32 cb_size;108__le64 byte_cnt_addr;109__le64 tfdq_addr;110} __packed; /* TX_QUEUE_CFG_CMD_API_S_VER_2 */111112/**113* struct iwl_tx_queue_cfg_rsp - response to txq hw scheduler config114* @queue_number: queue number assigned to this RA -TID115* @flags: set on failure116* @write_pointer: initial value for write pointer117* @reserved: reserved118*/119struct iwl_tx_queue_cfg_rsp {120__le16 queue_number;121__le16 flags;122__le16 write_pointer;123__le16 reserved;124} __packed; /* TX_QUEUE_CFG_RSP_API_S_VER_2 */125126#endif /* __iwl_fw_api_txq_h__ */127128129