wifi: iwlwifi: Add support for a new version for link config command
authorYedidya Benshimol <yedidya.ben.shimol@intel.com>
Tue, 6 May 2025 19:40:52 +0000 (22:40 +0300)
committerMiri Korenblit <miriam.rachel.korenblit@intel.com>
Fri, 9 May 2025 12:36:15 +0000 (15:36 +0300)
Add support for a new version of link configuration command
which includes NPCA and high priority TX traffic support for wifi8.

Signed-off-by: Yedidya Benshimol <yedidya.ben.shimol@intel.com>
Link: https://patch.msgid.link/20250506194102.3407967-6-miriam.rachel.korenblit@intel.com
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
drivers/net/wireless/intel/iwlwifi/fw/api/mac-cfg.h
drivers/net/wireless/intel/iwlwifi/fw/api/mac.h

index 53b7340ef8a1d4b8a122408c5296c4e6bbe228de..b9f559dac39f0f208c943f3229bed263996cda16 100644 (file)
@@ -488,6 +488,24 @@ enum iwl_link_modify_bandwidth {
        IWL_LINK_MODIFY_BW_320,
 };
 
+/**
+ * struct iwl_npca_params - NPCA parameters (non-primary channel access)
+ *
+ * @switch_delay: after switch, delay TX according to destination AP
+ * @switch_back_delay: switch back to control channel before OBSS frame end
+ * @min_dur_threshold: minimum PPDU time to switch to the non-primary
+ *     NPCA channel
+ * @flags: NPCA flags - bit 0: puncturing allowed, bit 1: new TX allowed
+ * @reserved: reserved for alignment purposes
+ */
+struct iwl_npca_params {
+       u8 switch_delay;
+       u8 switch_back_delay;
+       __le16 min_dur_threshold;
+       __le16 flags;
+       __le16 reserved;
+} __packed; /* NPCA_PARAM_API_S_VER_1 */
+
 /**
  * struct iwl_link_config_cmd - command structure to configure the LINK context
  *     in MLD API
@@ -545,6 +563,8 @@ enum iwl_link_modify_bandwidth {
  *     IEEE802.11REVme-D5.0
  * @ibss_bssid_addr: bssid for ibss
  * @reserved_for_ibss_bssid_addr: reserved
+ * @npca_params: NPCA parameters
+ * @prio_edca_params: priority EDCA parameters for enhanced QoS
  * @reserved3: reserved for future use
  */
 struct iwl_link_config_cmd {
@@ -592,8 +612,10 @@ struct iwl_link_config_cmd {
        u8 ul_mu_data_disable;
        u8 ibss_bssid_addr[6];
        __le16 reserved_for_ibss_bssid_addr;
-       __le32 reserved3[8];
-} __packed; /* LINK_CONTEXT_CONFIG_CMD_API_S_VER_1, _VER_2, _VER_3, _VER_4, _VER_5, _VER_6 */
+       struct iwl_npca_params npca_params; /* since _VER_7 */
+       struct iwl_ac_qos prio_edca_params; /* since _VER_7 */
+       __le32 reserved3[4];
+} __packed; /* LINK_CONTEXT_CONFIG_CMD_API_S_VER_1, _VER_2, _VER_3, _VER_4, _VER_5, _VER_6, _VER_7 */
 
 /* Currently FW supports link ids in the range 0-3 and can have
  * at most two active links for each vif.
index 26301c0b06a1f2146d29f646ee1c6e9bbf5aa175..2a174c00b712906050937c23c2a65e62f1a56143 100644 (file)
@@ -1,6 +1,6 @@
 /* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
 /*
- * Copyright (C) 2012-2014, 2018-2022, 2024 Intel Corporation
+ * Copyright (C) 2012-2014, 2018-2022, 2024-2025 Intel Corporation
  * Copyright (C) 2017 Intel Deutschland GmbH
  */
 #ifndef __iwl_fw_api_mac_h__
@@ -287,9 +287,9 @@ struct iwl_ac_qos {
        __le16 cw_min;
        __le16 cw_max;
        u8 aifsn;
-       u8 fifos_mask;
+       u8 fifos_mask; /* not in use since _VER_3 */
        __le16 edca_txop;
-} __packed; /* AC_QOS_API_S_VER_2 */
+} __packed; /* AC_QOS_API_S_VER_2, _VER_3 */
 
 /**
  * struct iwl_mac_ctx_cmd - command structure to configure MAC contexts