1 /* 2 * Copyright (c) 2016-2021 The Linux Foundation. All rights reserved. 3 * Copyright (c) 2021-2023 Qualcomm Innovation Center, Inc. All rights reserved. 4 * 5 * Permission to use, copy, modify, and/or distribute this software for 6 * any purpose with or without fee is hereby granted, provided that the 7 * above copyright notice and this permission notice appear in all 8 * copies. 9 * 10 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL 11 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED 12 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE 13 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL 14 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR 15 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER 16 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 17 * PERFORMANCE OF THIS SOFTWARE. 18 */ 19 20 #include "wlan_ipa_ucfg_api.h" 21 #if defined(CONFIG_HL_SUPPORT) 22 #include "wlan_tgt_def_config_hl.h" 23 #else 24 #include "wlan_tgt_def_config.h" 25 #endif 26 27 #include "qdf_trace.h" 28 #include "qdf_mem.h" 29 #include <cdp_txrx_ops.h> 30 #include "wlan_cfg.h" 31 #include "cfg_ucfg_api.h" 32 #include "hal_api.h" 33 #include "dp_types.h" 34 #include <qdf_module.h> 35 36 /* 37 * The max allowed size for tx comp ring is 8191. 38 * This is limited by h/w ring max size. 39 * As this is not a power of 2 it does not work with nss offload so the 40 * nearest available size which is power of 2 is 4096 chosen for nss 41 */ 42 43 #define WLAN_CFG_TX_RING_MASK_0 BIT(0) 44 #define WLAN_CFG_TX_RING_MASK_1 BIT(1) 45 #define WLAN_CFG_TX_RING_MASK_2 BIT(2) 46 #define WLAN_CFG_TX_RING_MASK_3 BIT(3) 47 #define WLAN_CFG_TX_RING_MASK_4 BIT(4) 48 #define WLAN_CFG_TX_RING_MASK_5 BIT(5) 49 #define WLAN_CFG_TX_RING_MASK_6 BIT(6) 50 #define WLAN_CFG_TX_RING_MASK_7 BIT(7) 51 52 53 #define WLAN_CFG_RX_MON_RING_MASK_0 0x1 54 #define WLAN_CFG_RX_MON_RING_MASK_1 0x2 55 #define WLAN_CFG_RX_MON_RING_MASK_2 0x4 56 #define WLAN_CFG_RX_MON_RING_MASK_3 0x0 57 58 #define WLAN_CFG_TX_MON_RING_MASK_0 BIT(0) 59 #define WLAN_CFG_TX_MON_RING_MASK_1 BIT(1) 60 61 #define WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 0x1 62 #define WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1 0x2 63 #define WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2 0x4 64 65 #define WLAN_CFG_HOST2TXMON_RING_MASK_0 0x1 66 67 #define WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 0x1 68 #define WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1 0x2 69 #define WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2 0x4 70 71 #define WLAN_CFG_RX_ERR_RING_MASK_0 0x1 72 #define WLAN_CFG_RX_ERR_RING_MASK_1 0x0 73 #define WLAN_CFG_RX_ERR_RING_MASK_2 0x0 74 #define WLAN_CFG_RX_ERR_RING_MASK_3 0x0 75 76 #define WLAN_CFG_RX_WBM_REL_RING_MASK_0 0x1 77 #define WLAN_CFG_RX_WBM_REL_RING_MASK_1 0x0 78 #define WLAN_CFG_RX_WBM_REL_RING_MASK_2 0x0 79 #define WLAN_CFG_RX_WBM_REL_RING_MASK_3 0x0 80 81 #define WLAN_CFG_REO_STATUS_RING_MASK_0 0x1 82 #define WLAN_CFG_REO_STATUS_RING_MASK_1 0x0 83 #define WLAN_CFG_REO_STATUS_RING_MASK_2 0x0 84 #define WLAN_CFG_REO_STATUS_RING_MASK_3 0x0 85 86 #define WLAN_CFG_RXDMA2HOST_RING_MASK_0 0x1 87 #define WLAN_CFG_RXDMA2HOST_RING_MASK_1 0x2 88 #define WLAN_CFG_RXDMA2HOST_RING_MASK_2 0x4 89 #define WLAN_CFG_RXDMA2HOST_RING_MASK_3 0x0 90 91 #define WLAN_CFG_HOST2RXDMA_RING_MASK_0 0x1 92 #define WLAN_CFG_HOST2RXDMA_RING_MASK_1 0x2 93 #define WLAN_CFG_HOST2RXDMA_RING_MASK_2 0x4 94 #define WLAN_CFG_HOST2RXDMA_RING_MASK_3 0x0 95 96 #define WLAN_CFG_UMAC_RESET_INTR_MASK_0 0x1 97 98 #define WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0 0x1 99 #define WLAN_CFG_REO2PPE_RING_MASK_0 0x1 100 #define WLAN_CFG_PPE2TCL_RING_MASK_0 0x1 101 102 struct dp_int_mask_assignment { 103 uint8_t tx_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 104 uint8_t rx_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 105 uint8_t rx_mon_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 106 uint8_t host2rxdma_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 107 uint8_t rxdma2host_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 108 uint8_t host2rxdma_mon_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 109 uint8_t rxdma2host_mon_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 110 uint8_t rx_err_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 111 uint8_t rx_wbm_rel_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 112 uint8_t reo_status_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 113 uint8_t rx_ring_near_full_irq_1_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 114 uint8_t rx_ring_near_full_irq_2_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 115 uint8_t tx_ring_near_full_irq_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 116 uint8_t host2txmon_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 117 uint8_t tx_mon_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 118 uint8_t ppeds_wbm_release_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 119 uint8_t reo2ppe_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 120 uint8_t ppe2tcl_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 121 uint8_t umac_reset_intr_mask[WLAN_CFG_INT_NUM_CONTEXTS]; 122 }; 123 124 #if defined(WLAN_MAX_PDEVS) && (WLAN_MAX_PDEVS == 1) 125 /* 126 * For BE, there are 18 available MSI interrupts, assigned in the manner 127 * below. 128 * TX(5) + RX(8) + (REO ERR + WBM ERR)(1) + 129 * (REO status + RXDMA[0] + RXDMA[1])(1) + NEAR_Full_RX(2) + NEAR_Full_TX(1) 130 * For IPA_OFFLOAD enabled case, 2 TX/RX rings would be assigned to IPA. 131 */ 132 133 #ifdef CONFIG_BERYLLIUM 134 #ifdef IPA_OFFLOAD 135 /* 136 * NEAR-FULL IRQ mask should be updated, if any change is made to 137 * the below TX mask. 138 */ 139 static const uint8_t tx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 140 [0] = WLAN_CFG_TX_RING_MASK_0, [1] = WLAN_CFG_TX_RING_MASK_4, 141 [2] = WLAN_CFG_TX_RING_MASK_2}; 142 #else /* !IPA_OFFLOAD */ 143 #ifdef QCA_WIFI_KIWI_V2 144 static const uint8_t tx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 145 [0] = WLAN_CFG_TX_RING_MASK_0, [1] = WLAN_CFG_TX_RING_MASK_4, 146 [2] = WLAN_CFG_TX_RING_MASK_2, [3] = WLAN_CFG_TX_RING_MASK_5, 147 [4] = WLAN_CFG_TX_RING_MASK_6}; 148 #else /* !QCA_WIFI_KIWI_V2 */ 149 static const uint8_t tx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 150 [0] = WLAN_CFG_TX_RING_MASK_0, [1] = WLAN_CFG_TX_RING_MASK_4, 151 [2] = WLAN_CFG_TX_RING_MASK_2, [3] = WLAN_CFG_TX_RING_MASK_6, 152 [4] = WLAN_CFG_TX_RING_MASK_7}; 153 #endif /* QCA_WIFI_KIWI_V2 */ 154 #endif /* IPA_OFFLOAD */ 155 156 static inline const 157 uint8_t *wlan_cfg_get_tx_ring_int_mask(struct wlan_cfg_dp_soc_ctxt *cfg_ctx) 158 { 159 return &tx_ring_mask_msi[0]; 160 } 161 #else 162 static const uint8_t tx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 163 [0] = WLAN_CFG_TX_RING_MASK_0}; 164 165 #ifdef TX_MULTI_TCL 166 static const uint8_t multi_tx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 167 [0] = WLAN_CFG_TX_RING_MASK_0, [4] = WLAN_CFG_TX_RING_MASK_2}; 168 169 #ifdef IPA_OFFLOAD 170 static inline const 171 uint8_t *wlan_cfg_get_tx_ring_int_mask(struct wlan_cfg_dp_soc_ctxt *cfg_ctx) 172 { 173 if (cfg_ctx->ipa_enabled) 174 return &tx_ring_mask_msi[0]; 175 176 return &multi_tx_ring_mask_msi[0]; 177 } 178 #else 179 static inline const 180 uint8_t *wlan_cfg_get_tx_ring_int_mask(struct wlan_cfg_dp_soc_ctxt *cfg_ctx) 181 { 182 return &multi_tx_ring_mask_msi[0]; 183 } 184 #endif /* IPA_OFFLOAD */ 185 #else 186 static inline const 187 uint8_t *wlan_cfg_get_tx_ring_int_mask(struct wlan_cfg_dp_soc_ctxt *cfg_ctx) 188 { 189 return &tx_ring_mask_msi[0]; 190 } 191 #endif /* TX_MULTI_TCL */ 192 #endif /* CONFIG_BERYLLIUM */ 193 194 #ifdef CONFIG_BERYLLIUM 195 #ifdef IPA_OFFLOAD 196 static const uint8_t rx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 197 [5] = WLAN_CFG_RX_RING_MASK_0, [6] = WLAN_CFG_RX_RING_MASK_1, 198 [7] = WLAN_CFG_RX_RING_MASK_2, [9] = WLAN_CFG_RX_RING_MASK_4, 199 [10] = WLAN_CFG_RX_RING_MASK_5, [11] = WLAN_CFG_RX_RING_MASK_6}; 200 #else 201 static const uint8_t rx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 202 [5] = WLAN_CFG_RX_RING_MASK_0, [6] = WLAN_CFG_RX_RING_MASK_1, 203 [7] = WLAN_CFG_RX_RING_MASK_2, [8] = WLAN_CFG_RX_RING_MASK_3, 204 [9] = WLAN_CFG_RX_RING_MASK_4, [10] = WLAN_CFG_RX_RING_MASK_5, 205 [11] = WLAN_CFG_RX_RING_MASK_6, [12] = WLAN_CFG_RX_RING_MASK_7}; 206 #endif /* IPA_OFFLOAD */ 207 #else /* !defined(CONFIG_BERYLLIUM) */ 208 #ifdef IPA_OFFLOAD 209 static const uint8_t rx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 210 [1] = WLAN_CFG_RX_RING_MASK_0, [2] = WLAN_CFG_RX_RING_MASK_1, 211 [3] = WLAN_CFG_RX_RING_MASK_2}; 212 #else 213 static const uint8_t rx_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 214 [1] = WLAN_CFG_RX_RING_MASK_0, [2] = WLAN_CFG_RX_RING_MASK_1, 215 [3] = WLAN_CFG_RX_RING_MASK_2 | WLAN_CFG_RX_RING_MASK_3}; 216 #endif 217 #endif /* CONFIG_BERYLLIUM */ 218 219 #ifdef CONFIG_BERYLLIUM 220 static const uint8_t rxdma2host_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 221 [13] = WLAN_CFG_RXDMA2HOST_RING_MASK_0}; 222 #else 223 static const uint8_t rxdma2host_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 224 [6] = WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 225 WLAN_CFG_RXDMA2HOST_RING_MASK_1}; 226 #endif /* CONFIG_BERYLLIUM */ 227 228 #ifdef CONFIG_BERYLLIUM 229 static const uint8_t rx_mon_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 230 [5] = WLAN_CFG_RX_MON_RING_MASK_0}; 231 #else 232 static const uint8_t rx_mon_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 233 [1] = WLAN_CFG_RX_MON_RING_MASK_0, [2] = WLAN_CFG_RX_MON_RING_MASK_1}; 234 #endif 235 236 static const uint8_t host2rxdma_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = {0}; 237 238 static const uint8_t host2rxdma_mon_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = {0}; 239 240 static const uint8_t rxdma2host_mon_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = {0}; 241 242 #ifdef CONFIG_BERYLLIUM 243 static const uint8_t rx_err_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 244 [14] = WLAN_CFG_RX_ERR_RING_MASK_0}; 245 246 static const uint8_t rx_wbm_rel_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 247 [14] = WLAN_CFG_RX_WBM_REL_RING_MASK_0}; 248 249 static const uint8_t reo_status_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 250 [13] = WLAN_CFG_REO_STATUS_RING_MASK_0}; 251 #else 252 static const uint8_t rx_err_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 253 [6] = WLAN_CFG_RX_ERR_RING_MASK_0}; 254 static const uint8_t rx_wbm_rel_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 255 [6] = WLAN_CFG_RX_WBM_REL_RING_MASK_0}; 256 static const uint8_t reo_status_ring_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 257 [6] = WLAN_CFG_REO_STATUS_RING_MASK_0}; 258 #endif 259 260 #ifdef CONFIG_BERYLLIUM 261 #ifdef WLAN_FEATURE_NEAR_FULL_IRQ 262 static const uint8_t rx_ring_near_full_irq_1_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 263 [15] = WLAN_CFG_RX_NEAR_FULL_IRQ_MASK_1}; 264 static const uint8_t rx_ring_near_full_irq_2_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 265 [16] = WLAN_CFG_RX_NEAR_FULL_IRQ_MASK_1}; 266 static const uint8_t tx_ring_near_full_irq_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 267 [17] = WLAN_CFG_TX_RING_NEAR_FULL_IRQ_MASK}; 268 #else 269 static const uint8_t rx_ring_near_full_irq_1_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 270 0 }; 271 static const uint8_t rx_ring_near_full_irq_2_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 272 0 }; 273 static const uint8_t tx_ring_near_full_irq_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 274 0 }; 275 #endif 276 #else 277 static const uint8_t rx_ring_near_full_irq_1_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 278 0 }; 279 static const uint8_t rx_ring_near_full_irq_2_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 280 0 }; 281 static const uint8_t tx_ring_near_full_irq_mask_msi[WLAN_CFG_INT_NUM_CONTEXTS] = { 282 0 }; 283 #endif 284 285 #else 286 /* Integrated configuration + 16 possible MSI configurations */ 287 #define NUM_INTERRUPT_COMBINATIONS 17 288 /* 289 * This structure contains the best possible mask assignment for a given 290 * number of MSIs available in the system. 291 */ 292 #ifdef IPA_OFFLOAD 293 static struct dp_int_mask_assignment dp_mask_assignment[NUM_INTERRUPT_COMBINATIONS] = { 294 /* Interrupt assignment for integrated configuration */ 295 { 296 /* tx ring masks */ 297 { WLAN_CFG_TX_RING_MASK_0, 298 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 299 /* rx ring masks */ 300 { 0, 0, 0, 0, 0, 0, 0, 301 WLAN_CFG_RX_RING_MASK_0, 302 WLAN_CFG_RX_RING_MASK_1, 303 WLAN_CFG_RX_RING_MASK_2, 304 0}, 305 /* rx mon ring masks */ 306 { 0, 0, 0, 0, 307 WLAN_CFG_RX_MON_RING_MASK_0, 308 WLAN_CFG_RX_MON_RING_MASK_1, 309 WLAN_CFG_RX_MON_RING_MASK_2, 310 0, 0, 0, 0}, 311 /* host2rxdma ring masks */ 312 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 313 /* rxdma2host ring masks */ 314 { WLAN_CFG_RXDMA2HOST_RING_MASK_0, 315 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 316 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 317 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 318 0, 0, 0, 0, 0, 0, 0}, 319 /* host2rxdma mon ring masks */ 320 { 0, 0, 0, 0, 321 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 322 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 323 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 324 0, 0, 0, 0}, 325 /* rxdma2host mon ring masks */ 326 { 0, 0, 0, 0, 327 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 328 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 329 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 330 0, 0, 0, 0}, 331 /* rx err ring masks */ 332 { WLAN_CFG_RX_ERR_RING_MASK_0, 333 WLAN_CFG_RX_ERR_RING_MASK_1, 334 WLAN_CFG_RX_ERR_RING_MASK_2, 335 WLAN_CFG_RX_ERR_RING_MASK_3, 336 0, 0, 0, 0, 0, 0, 0}, 337 /* rx wbm rel ring masks */ 338 { WLAN_CFG_RX_WBM_REL_RING_MASK_0, 339 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 340 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 341 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 342 0, 0, 0, 0, 0, 0, 0}, 343 /* reo status ring masks */ 344 { WLAN_CFG_REO_STATUS_RING_MASK_0, 345 WLAN_CFG_REO_STATUS_RING_MASK_1, 346 WLAN_CFG_REO_STATUS_RING_MASK_2, 347 WLAN_CFG_REO_STATUS_RING_MASK_3, 348 0, 0, 0, 0, 0, 0, 0}, 349 }, 350 /* Interrupt assignment for 1 MSI combination */ 351 { 352 /* tx ring masks */ 353 { WLAN_CFG_TX_RING_MASK_0, 354 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 355 /* rx ring masks */ 356 { WLAN_CFG_RX_RING_MASK_0 | 357 WLAN_CFG_RX_RING_MASK_1 | 358 WLAN_CFG_RX_RING_MASK_2, 359 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 360 /* rx mon ring masks */ 361 { WLAN_CFG_RX_MON_RING_MASK_0 | 362 WLAN_CFG_RX_MON_RING_MASK_1 | 363 WLAN_CFG_RX_MON_RING_MASK_2, 364 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 365 /* host2rxdma ring masks */ 366 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 367 /* rxdma2host ring masks */ 368 { WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 369 WLAN_CFG_RXDMA2HOST_RING_MASK_1 | 370 WLAN_CFG_RXDMA2HOST_RING_MASK_2 | 371 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 372 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 373 /* host2rxdma mon ring masks */ 374 { WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 | 375 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1 | 376 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 377 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 378 /* rxdma2host mon ring masks */ 379 { WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 | 380 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1 | 381 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 382 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 383 /* rx err ring masks */ 384 { WLAN_CFG_RX_ERR_RING_MASK_0 | 385 WLAN_CFG_RX_ERR_RING_MASK_1 | 386 WLAN_CFG_RX_ERR_RING_MASK_2 | 387 WLAN_CFG_RX_ERR_RING_MASK_3, 388 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 389 /* rx wbm rel ring masks */ 390 { WLAN_CFG_RX_WBM_REL_RING_MASK_0 | 391 WLAN_CFG_RX_WBM_REL_RING_MASK_1 | 392 WLAN_CFG_RX_WBM_REL_RING_MASK_2 | 393 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 394 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 395 /* reo status ring masks */ 396 { WLAN_CFG_REO_STATUS_RING_MASK_0 | 397 WLAN_CFG_REO_STATUS_RING_MASK_1 | 398 WLAN_CFG_REO_STATUS_RING_MASK_2 | 399 WLAN_CFG_REO_STATUS_RING_MASK_3, 400 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 401 }, 402 /* Interrupt assignment for 2 MSI combination */ 403 { 404 /* tx ring masks */ 405 { WLAN_CFG_TX_RING_MASK_0, 406 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 407 /* rx ring masks */ 408 { WLAN_CFG_RX_RING_MASK_0 | 409 WLAN_CFG_RX_RING_MASK_1, 410 WLAN_CFG_RX_RING_MASK_2, 411 0, 0, 0, 0, 0, 0, 0, 0, 0}, 412 /* rx mon ring masks */ 413 { WLAN_CFG_RX_MON_RING_MASK_0 | 414 WLAN_CFG_RX_MON_RING_MASK_1, 415 WLAN_CFG_RX_MON_RING_MASK_2, 416 0, 0, 0, 0, 0, 0, 0, 0, 0}, 417 /* host2rxdma ring masks */ 418 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 419 /* rxdma2host ring masks */ 420 { WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 421 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 422 WLAN_CFG_RXDMA2HOST_RING_MASK_2 | 423 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 424 0, 0, 0, 0, 0, 0, 0, 0, 0}, 425 /* host2rxdma mon ring masks */ 426 { WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 | 427 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 428 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 429 0, 0, 0, 0, 0, 0, 0, 0, 0}, 430 /* rxdma2host mon ring masks */ 431 { WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 | 432 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 433 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 434 0, 0, 0, 0, 0, 0, 0, 0, 0}, 435 /* rx err ring masks */ 436 { WLAN_CFG_RX_ERR_RING_MASK_0 | 437 WLAN_CFG_RX_ERR_RING_MASK_1, 438 WLAN_CFG_RX_ERR_RING_MASK_2 | 439 WLAN_CFG_RX_ERR_RING_MASK_3, 440 0, 0, 0, 0, 0, 0, 0, 0, 0}, 441 /* rx wbm rel ring masks */ 442 { WLAN_CFG_RX_WBM_REL_RING_MASK_0 | 443 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 444 WLAN_CFG_RX_WBM_REL_RING_MASK_2 | 445 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 446 0, 0, 0, 0, 0, 0, 0, 0, 0}, 447 /* reo status ring masks */ 448 { WLAN_CFG_REO_STATUS_RING_MASK_0 | 449 WLAN_CFG_REO_STATUS_RING_MASK_1, 450 WLAN_CFG_REO_STATUS_RING_MASK_2 | 451 WLAN_CFG_REO_STATUS_RING_MASK_3, 452 0, 0, 0, 0, 0, 0, 0, 0, 0}, 453 }, 454 /* Interrupt assignment for 3 MSI combination */ 455 { 456 /* tx ring masks */ 457 { WLAN_CFG_TX_RING_MASK_0, 458 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 459 /* rx ring masks */ 460 { WLAN_CFG_RX_RING_MASK_0, 461 WLAN_CFG_RX_RING_MASK_1, 462 WLAN_CFG_RX_RING_MASK_2, 463 0, 0, 0, 0, 0, 0, 0, 0}, 464 /* rx mon ring masks */ 465 { 0, 0, 466 WLAN_CFG_RX_MON_RING_MASK_0 | 467 WLAN_CFG_RX_MON_RING_MASK_1 | 468 WLAN_CFG_RX_MON_RING_MASK_2, 469 0, 0, 0, 0, 0, 0, 0, 0}, 470 /* host2rxdma ring masks */ 471 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 472 /* rxdma2host ring masks */ 473 { 0, 0, 474 WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 475 WLAN_CFG_RXDMA2HOST_RING_MASK_1 | 476 WLAN_CFG_RXDMA2HOST_RING_MASK_2 | 477 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 478 0, 0, 0, 0, 0, 0, 0, 0}, 479 /* host2rxdma mon ring masks */ 480 { 0, 0, 481 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 | 482 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1 | 483 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 484 0, 0, 0, 0, 0, 0, 0, 0}, 485 /* rxdma2host mon ring masks */ 486 { 0, 0, 487 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 | 488 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1 | 489 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 490 0, 0, 0, 0, 0, 0, 0, 0}, 491 /* rx err ring masks */ 492 { 0, 0, 493 WLAN_CFG_RX_ERR_RING_MASK_0 | 494 WLAN_CFG_RX_ERR_RING_MASK_1 | 495 WLAN_CFG_RX_ERR_RING_MASK_2 | 496 WLAN_CFG_RX_ERR_RING_MASK_3, 497 0, 0, 0, 0, 0, 0, 0, 0}, 498 /* rx wbm rel ring masks */ 499 { 0, 0, 500 WLAN_CFG_RX_WBM_REL_RING_MASK_0 | 501 WLAN_CFG_RX_WBM_REL_RING_MASK_1 | 502 WLAN_CFG_RX_WBM_REL_RING_MASK_2 | 503 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 504 0, 0, 0, 0, 0, 0, 0, 0}, 505 /* reo status ring masks */ 506 { 0, 0, 507 WLAN_CFG_REO_STATUS_RING_MASK_0 | 508 WLAN_CFG_REO_STATUS_RING_MASK_1 | 509 WLAN_CFG_REO_STATUS_RING_MASK_2 | 510 WLAN_CFG_REO_STATUS_RING_MASK_3, 511 0, 0, 0, 0, 0, 0, 0, 0}, 512 }, 513 /* Interrupt assignment for 4 MSI combination */ 514 { 515 /* tx ring masks */ 516 { WLAN_CFG_TX_RING_MASK_0, 517 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 518 /* rx ring masks */ 519 { WLAN_CFG_RX_RING_MASK_0, 520 WLAN_CFG_RX_RING_MASK_1, 521 WLAN_CFG_RX_RING_MASK_2, 522 0, 0, 0, 0, 0, 0, 0, 0}, 523 /* rx mon ring masks */ 524 { WLAN_CFG_RX_MON_RING_MASK_0, 525 WLAN_CFG_RX_MON_RING_MASK_1, 526 WLAN_CFG_RX_MON_RING_MASK_2, 527 0, 0, 0, 0, 0, 0, 0, 0}, 528 /* host2rxdma ring masks */ 529 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 530 /* rxdma2host ring masks */ 531 { WLAN_CFG_RXDMA2HOST_RING_MASK_0, 532 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 533 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 534 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 535 0, 0, 0, 0, 0, 0, 0}, 536 /* host2rxdma mon ring masks */ 537 { WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 538 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 539 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 540 0, 0, 0, 0, 0, 0, 0, 0}, 541 /* rxdma2host mon ring masks */ 542 { WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 543 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 544 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 545 0, 0, 0, 0, 0, 0, 0, 0}, 546 /* rx err ring masks */ 547 { WLAN_CFG_RX_ERR_RING_MASK_0, 548 WLAN_CFG_RX_ERR_RING_MASK_1, 549 WLAN_CFG_RX_ERR_RING_MASK_2, 550 WLAN_CFG_RX_ERR_RING_MASK_3, 551 0, 0, 0, 0, 0, 0, 0}, 552 /* rx wbm rel ring masks */ 553 { WLAN_CFG_RX_WBM_REL_RING_MASK_0, 554 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 555 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 556 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 557 0, 0, 0, 0, 0, 0, 0}, 558 /* reo status ring masks */ 559 { WLAN_CFG_REO_STATUS_RING_MASK_0, 560 WLAN_CFG_REO_STATUS_RING_MASK_1, 561 WLAN_CFG_REO_STATUS_RING_MASK_2, 562 WLAN_CFG_REO_STATUS_RING_MASK_3, 563 0, 0, 0, 0, 0, 0, 0}, 564 }, 565 /* Interrupt assignment for 5 MSI combination */ 566 { 567 /* tx ring masks */ 568 { WLAN_CFG_TX_RING_MASK_0, 569 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 570 /* rx ring masks */ 571 { WLAN_CFG_RX_RING_MASK_0, 572 WLAN_CFG_RX_RING_MASK_1, 573 WLAN_CFG_RX_RING_MASK_2, 574 0, 0, 0, 0, 0, 0, 0, 0}, 575 /* rx mon ring masks */ 576 { 0, 0, 0, 0, 577 WLAN_CFG_RX_MON_RING_MASK_0 | 578 WLAN_CFG_RX_MON_RING_MASK_1 | 579 WLAN_CFG_RX_MON_RING_MASK_2, 580 0, 0, 0, 0, 0, 0}, 581 /* host2rxdma ring masks */ 582 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 583 /* rxdma2host ring masks */ 584 { 0, 0, 0, 0, 585 WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 586 WLAN_CFG_RXDMA2HOST_RING_MASK_1 | 587 WLAN_CFG_RXDMA2HOST_RING_MASK_2 | 588 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 589 0, 0, 0, 0, 0, 0}, 590 /* host2rxdma mon ring masks */ 591 { 0, 0, 0, 0, 592 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 | 593 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1 | 594 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 595 0, 0, 0, 0, 0, 0}, 596 /* rxdma2host mon ring masks */ 597 { 0, 0, 0, 0, 598 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 | 599 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1 | 600 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 601 0, 0, 0, 0, 0, 0}, 602 /* rx err ring masks */ 603 { 0, 0, 0, 0, 604 WLAN_CFG_RX_ERR_RING_MASK_0 | 605 WLAN_CFG_RX_ERR_RING_MASK_1 | 606 WLAN_CFG_RX_ERR_RING_MASK_2 | 607 WLAN_CFG_RX_ERR_RING_MASK_3, 608 0, 0, 0, 0, 0, 0}, 609 /* rx wbm rel ring masks */ 610 { 0, 0, 0, 0, 611 WLAN_CFG_RX_WBM_REL_RING_MASK_0 | 612 WLAN_CFG_RX_WBM_REL_RING_MASK_1 | 613 WLAN_CFG_RX_WBM_REL_RING_MASK_2 | 614 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 615 0, 0, 0, 0, 0, 0}, 616 /* reo status ring masks */ 617 { 0, 0, 0, 0, 618 WLAN_CFG_REO_STATUS_RING_MASK_0 | 619 WLAN_CFG_REO_STATUS_RING_MASK_1 | 620 WLAN_CFG_REO_STATUS_RING_MASK_2 | 621 WLAN_CFG_REO_STATUS_RING_MASK_3, 622 0, 0, 0, 0, 0, 0}, 623 }, 624 /* Interrupt assignment for 6 MSI combination */ 625 { 626 /* tx ring masks */ 627 { WLAN_CFG_TX_RING_MASK_0, 628 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 629 /* rx ring masks */ 630 { 0, 0, 631 WLAN_CFG_RX_RING_MASK_0, 632 WLAN_CFG_RX_RING_MASK_1, 633 WLAN_CFG_RX_RING_MASK_2, 634 0, 0, 0, 0, 0, 0}, 635 /* rx mon ring masks */ 636 { WLAN_CFG_RX_MON_RING_MASK_0, 637 WLAN_CFG_RX_MON_RING_MASK_1, 638 WLAN_CFG_RX_MON_RING_MASK_2, 639 0, 0, 0, 0, 0, 0, 0, 0}, 640 /* host2rxdma ring masks */ 641 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 642 /* rxdma2host ring masks */ 643 { WLAN_CFG_RXDMA2HOST_RING_MASK_0, 644 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 645 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 646 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 647 0, 0, 0, 0, 0, 0, 0}, 648 /* host2rxdma mon ring masks */ 649 { WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 650 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 651 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 652 0, 0, 0, 0, 0, 0, 0, 0}, 653 /* rxdma2host mon ring masks */ 654 { WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 655 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 656 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 657 0, 0, 0, 0, 0, 0, 0, 0}, 658 /* rx err ring masks */ 659 { WLAN_CFG_RX_ERR_RING_MASK_0, 660 WLAN_CFG_RX_ERR_RING_MASK_1, 661 WLAN_CFG_RX_ERR_RING_MASK_2, 662 WLAN_CFG_RX_ERR_RING_MASK_3, 663 0, 0, 0, 0, 0, 0, 0}, 664 /* rx wbm rel ring masks */ 665 { WLAN_CFG_RX_WBM_REL_RING_MASK_0, 666 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 667 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 668 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 669 0, 0, 0, 0, 0, 0, 0}, 670 /* reo status ring masks */ 671 { WLAN_CFG_REO_STATUS_RING_MASK_0, 672 WLAN_CFG_REO_STATUS_RING_MASK_1, 673 WLAN_CFG_REO_STATUS_RING_MASK_2, 674 WLAN_CFG_REO_STATUS_RING_MASK_3, 675 0, 0, 0, 0, 0, 0, 0}, 676 }, 677 /* Interrupt assignment for 7 MSI combination */ 678 { 679 /* tx ring masks */ 680 { WLAN_CFG_TX_RING_MASK_0, 681 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 682 /* rx ring masks */ 683 { 0, 0, 0, 684 WLAN_CFG_RX_RING_MASK_0, 685 WLAN_CFG_RX_RING_MASK_1, 686 WLAN_CFG_RX_RING_MASK_2, 687 0, 0, 0, 0}, 688 /* rx mon ring masks */ 689 { 0, 0, 0, 690 WLAN_CFG_RX_MON_RING_MASK_0, 691 WLAN_CFG_RX_MON_RING_MASK_1, 692 WLAN_CFG_RX_MON_RING_MASK_2, 693 0, 0, 0, 0, 0}, 694 /* host2rxdma ring masks */ 695 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 696 /* rxdma2host ring masks */ 697 { 0, 0, 0, 698 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 699 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 700 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 701 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 702 0, 0, 0, 0}, 703 /* host2rxdma mon ring masks */ 704 { 0, 0, 0, 705 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 706 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 707 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 708 0, 0, 0, 0, 0}, 709 /* rxdma2host mon ring masks */ 710 { 0, 0, 0, 711 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 712 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 713 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 714 0, 0, 0, 0, 0}, 715 /* rx err ring masks */ 716 { 0, 0, 0, 717 WLAN_CFG_RX_ERR_RING_MASK_0, 718 WLAN_CFG_RX_ERR_RING_MASK_1, 719 WLAN_CFG_RX_ERR_RING_MASK_2, 720 WLAN_CFG_RX_ERR_RING_MASK_3, 721 0, 0, 0, 0}, 722 /* rx wbm rel ring masks */ 723 { 0, 0, 0, 724 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 725 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 726 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 727 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 728 0, 0, 0, 0}, 729 /* reo status ring masks */ 730 { 0, 0, 0, 731 WLAN_CFG_REO_STATUS_RING_MASK_0, 732 WLAN_CFG_REO_STATUS_RING_MASK_1, 733 WLAN_CFG_REO_STATUS_RING_MASK_2, 734 WLAN_CFG_REO_STATUS_RING_MASK_3, 735 0, 0, 0, 0}, 736 }, 737 /* Interrupt assignment for 8 MSI combination */ 738 { 739 /* tx ring masks */ 740 { WLAN_CFG_TX_RING_MASK_0, 741 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 742 /* rx ring masks */ 743 { 0, 0, 0, 0, 744 WLAN_CFG_RX_RING_MASK_0, 745 WLAN_CFG_RX_RING_MASK_1, 746 WLAN_CFG_RX_RING_MASK_2, 747 0, 0, 0, 0}, 748 /* rx mon ring masks */ 749 { 0, 0, 0, 750 WLAN_CFG_RX_MON_RING_MASK_0, 751 WLAN_CFG_RX_MON_RING_MASK_1, 752 WLAN_CFG_RX_MON_RING_MASK_2, 753 0, 0, 0, 0, 0}, 754 /* host2rxdma ring masks */ 755 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 756 /* rxdma2host ring masks */ 757 { 0, 0, 0, 758 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 759 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 760 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 761 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 762 0, 0, 0, 0}, 763 /* host2rxdma mon ring masks */ 764 { 0, 0, 0, 765 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 766 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 767 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 768 0, 0, 0, 0, 0}, 769 /* rxdma2host mon ring masks */ 770 { 0, 0, 0, 771 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 772 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 773 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 774 0, 0, 0, 0, 0}, 775 /* rx err ring masks */ 776 { 0, 0, 0, 777 WLAN_CFG_RX_ERR_RING_MASK_0, 778 WLAN_CFG_RX_ERR_RING_MASK_1, 779 WLAN_CFG_RX_ERR_RING_MASK_2, 780 WLAN_CFG_RX_ERR_RING_MASK_3, 781 0, 0, 0, 0}, 782 /* rx wbm rel ring masks */ 783 { 0, 0, 0, 784 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 785 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 786 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 787 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 788 0, 0, 0, 0}, 789 /* reo status ring masks */ 790 { 0, 0, 0, 791 WLAN_CFG_REO_STATUS_RING_MASK_0, 792 WLAN_CFG_REO_STATUS_RING_MASK_1, 793 WLAN_CFG_REO_STATUS_RING_MASK_2, 794 WLAN_CFG_REO_STATUS_RING_MASK_3, 795 0, 0, 0, 0}, 796 /* ppe2tcl ring masks */ 797 { 0, 0, 0, 798 WLAN_CFG_REO_STATUS_RING_MASK_0, 799 WLAN_CFG_REO_STATUS_RING_MASK_1, 800 WLAN_CFG_REO_STATUS_RING_MASK_2, 801 WLAN_CFG_REO_STATUS_RING_MASK_3, 802 0, 0, 0, 0}, 803 /* reo2ppe ring masks */ 804 { 0, 0, 0, 805 WLAN_CFG_REO_STATUS_RING_MASK_0, 806 WLAN_CFG_REO_STATUS_RING_MASK_1, 807 WLAN_CFG_REO_STATUS_RING_MASK_2, 808 WLAN_CFG_REO_STATUS_RING_MASK_3, 809 0, 0, 0, 0}, 810 }, 811 }; 812 #else 813 static struct dp_int_mask_assignment dp_mask_assignment[NUM_INTERRUPT_COMBINATIONS] = { 814 /* Interrupt assignment for integrated configuration */ 815 { 816 /* tx ring masks */ 817 { WLAN_CFG_TX_RING_MASK_0, 818 WLAN_CFG_TX_RING_MASK_1, 819 WLAN_CFG_TX_RING_MASK_2, 820 WLAN_CFG_TX_RING_MASK_3, 821 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 822 /* rx ring masks */ 823 { 0, 0, 0, 0, 0, 0, 0, 824 WLAN_CFG_RX_RING_MASK_0, 825 WLAN_CFG_RX_RING_MASK_1, 826 WLAN_CFG_RX_RING_MASK_2, 827 WLAN_CFG_RX_RING_MASK_3, 828 0, 0, 0, 0, 0}, 829 /* rx mon ring masks */ 830 { 0, 0, 0, 0, 831 WLAN_CFG_RX_MON_RING_MASK_0, 832 WLAN_CFG_RX_MON_RING_MASK_1, 833 WLAN_CFG_RX_MON_RING_MASK_2, 834 0, 0, 0, 0, 0, 0, 0, 0, 0}, 835 /* host2rxdma ring masks */ 836 { WLAN_CFG_HOST2RXDMA_RING_MASK_0, 837 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 838 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 839 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 840 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 841 /* rxdma2host ring masks */ 842 { WLAN_CFG_RXDMA2HOST_RING_MASK_0, 843 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 844 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 845 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 846 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 847 /* host2rxdma mon ring masks */ 848 { 0, 0, 0, 0, 849 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 850 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 851 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 852 0, 0, 0, 0, 0, 0, 0, 0, 0}, 853 /* rxdma2host mon ring masks */ 854 { 0, 0, 0, 0, 855 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 856 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 857 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 858 0, 0, 0, 0, 0, 0, 0, 0, 0}, 859 /* rx err ring masks */ 860 { WLAN_CFG_RX_ERR_RING_MASK_0, 861 WLAN_CFG_RX_ERR_RING_MASK_1, 862 WLAN_CFG_RX_ERR_RING_MASK_2, 863 WLAN_CFG_RX_ERR_RING_MASK_3, 864 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 865 /* rx wbm rel ring masks */ 866 { WLAN_CFG_RX_WBM_REL_RING_MASK_0, 867 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 868 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 869 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 870 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 871 /* reo status ring masks */ 872 { WLAN_CFG_REO_STATUS_RING_MASK_0, 873 WLAN_CFG_REO_STATUS_RING_MASK_1, 874 WLAN_CFG_REO_STATUS_RING_MASK_2, 875 WLAN_CFG_REO_STATUS_RING_MASK_3, 876 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 877 /* rx_ring_near_full_irq mask */ 878 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 879 /* rx_ring_near_full_irq_2 mask */ 880 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 881 /* tx_ring_near_full_irq mask */ 882 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 883 /* host2txmon ring masks */ 884 {WLAN_CFG_HOST2TXMON_RING_MASK_0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 885 0, 0, 0, 0, 0, 0}, 886 /* tx mon ring masks */ 887 {WLAN_CFG_TX_MON_RING_MASK_0, WLAN_CFG_TX_MON_RING_MASK_1, 0, 888 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 889 /* umac reset mask */ 890 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 891 WLAN_CFG_UMAC_RESET_INTR_MASK_0}, 892 }, 893 /* Interrupt assignment for 1 MSI combination */ 894 { 895 /* tx ring masks */ 896 { WLAN_CFG_TX_RING_MASK_0 | 897 WLAN_CFG_TX_RING_MASK_1 | 898 WLAN_CFG_TX_RING_MASK_2 | 899 WLAN_CFG_TX_RING_MASK_3, 900 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 901 /* rx ring masks */ 902 { WLAN_CFG_RX_RING_MASK_0 | 903 WLAN_CFG_RX_RING_MASK_1 | 904 WLAN_CFG_RX_RING_MASK_2 | 905 WLAN_CFG_RX_RING_MASK_3, 906 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 907 /* rx mon ring masks */ 908 { WLAN_CFG_RX_MON_RING_MASK_0 | 909 WLAN_CFG_RX_MON_RING_MASK_1 | 910 WLAN_CFG_RX_MON_RING_MASK_2, 911 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 912 /* host2rxdma ring masks */ 913 { WLAN_CFG_HOST2RXDMA_RING_MASK_0 | 914 WLAN_CFG_HOST2RXDMA_RING_MASK_1 | 915 WLAN_CFG_HOST2RXDMA_RING_MASK_2 | 916 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 917 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 918 /* rxdma2host ring masks */ 919 { WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 920 WLAN_CFG_RXDMA2HOST_RING_MASK_1 | 921 WLAN_CFG_RXDMA2HOST_RING_MASK_2 | 922 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 923 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 924 /* host2rxdma mon ring masks */ 925 { WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 | 926 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1 | 927 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 928 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 929 /* rxdma2host mon ring masks */ 930 { WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 | 931 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1 | 932 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 933 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 934 /* rx err ring masks */ 935 { WLAN_CFG_RX_ERR_RING_MASK_0 | 936 WLAN_CFG_RX_ERR_RING_MASK_1 | 937 WLAN_CFG_RX_ERR_RING_MASK_2 | 938 WLAN_CFG_RX_ERR_RING_MASK_3, 939 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 940 /* rx wbm rel ring masks */ 941 { WLAN_CFG_RX_WBM_REL_RING_MASK_0 | 942 WLAN_CFG_RX_WBM_REL_RING_MASK_1 | 943 WLAN_CFG_RX_WBM_REL_RING_MASK_2 | 944 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 945 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 946 /* reo status ring masks */ 947 { WLAN_CFG_REO_STATUS_RING_MASK_0 | 948 WLAN_CFG_REO_STATUS_RING_MASK_1 | 949 WLAN_CFG_REO_STATUS_RING_MASK_2 | 950 WLAN_CFG_REO_STATUS_RING_MASK_3, 951 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 952 /* rx_ring_near_full_irq mask */ 953 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 954 /* rx_ring_near_full_irq_2 mask */ 955 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 956 /* tx_ring_near_full_irq mask */ 957 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 958 /* host2txmon ring masks */ 959 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 960 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 961 /* tx mon ring masks */ 962 { WLAN_CFG_TX_MON_RING_MASK_0 | 963 WLAN_CFG_TX_MON_RING_MASK_1, 964 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 965 /* Reo2ppe ring mask */ 966 {WLAN_CFG_REO2PPE_RING_MASK_0, 0, 0, 0, 967 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 968 /* ppe2tcl ring mask */ 969 {0, WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 970 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 971 /* umac reset mask */ 972 {WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 0, 0, 0, 0, 973 0, 0, 0, 0, 0, 0, 0, 0}, 974 }, 975 /* Interrupt assignment for 2 MSI combination */ 976 { 977 /* tx ring masks */ 978 { WLAN_CFG_TX_RING_MASK_0 | 979 WLAN_CFG_TX_RING_MASK_1, 980 WLAN_CFG_TX_RING_MASK_2 | 981 WLAN_CFG_TX_RING_MASK_3, 982 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 983 /* rx ring masks */ 984 { WLAN_CFG_RX_RING_MASK_0 | 985 WLAN_CFG_RX_RING_MASK_1, 986 WLAN_CFG_RX_RING_MASK_2 | 987 WLAN_CFG_RX_RING_MASK_3, 988 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 989 /* rx mon ring masks */ 990 { WLAN_CFG_RX_MON_RING_MASK_0 | 991 WLAN_CFG_RX_MON_RING_MASK_1, 992 WLAN_CFG_RX_MON_RING_MASK_2, 993 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 994 /* host2rxdma ring masks */ 995 { WLAN_CFG_HOST2RXDMA_RING_MASK_0 | 996 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 997 WLAN_CFG_HOST2RXDMA_RING_MASK_2 | 998 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 999 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1000 /* rxdma2host ring masks */ 1001 { WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 1002 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1003 WLAN_CFG_RXDMA2HOST_RING_MASK_2 | 1004 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1005 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1006 /* host2rxdma mon ring masks */ 1007 { WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 | 1008 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1009 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1010 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1011 /* rxdma2host mon ring masks */ 1012 { WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 | 1013 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1014 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1015 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1016 /* rx err ring masks */ 1017 { WLAN_CFG_RX_ERR_RING_MASK_0 | 1018 WLAN_CFG_RX_ERR_RING_MASK_1, 1019 WLAN_CFG_RX_ERR_RING_MASK_2 | 1020 WLAN_CFG_RX_ERR_RING_MASK_3, 1021 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1022 /* rx wbm rel ring masks */ 1023 { WLAN_CFG_RX_WBM_REL_RING_MASK_0 | 1024 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 1025 WLAN_CFG_RX_WBM_REL_RING_MASK_2 | 1026 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1027 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1028 /* reo status ring masks */ 1029 { WLAN_CFG_REO_STATUS_RING_MASK_0 | 1030 WLAN_CFG_REO_STATUS_RING_MASK_1, 1031 WLAN_CFG_REO_STATUS_RING_MASK_2 | 1032 WLAN_CFG_REO_STATUS_RING_MASK_3, 1033 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1034 /* rx_ring_near_full_irq mask */ 1035 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1036 /* rx_ring_near_full_irq_2 mask */ 1037 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1038 /* tx_ring_near_full_irq mask */ 1039 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1040 /* host2txmon ring masks */ 1041 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1042 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1043 /* tx mon ring masks */ 1044 { WLAN_CFG_TX_MON_RING_MASK_0, 1045 WLAN_CFG_TX_MON_RING_MASK_1, 1046 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1047 /* Reo2ppe ring mask */ 1048 {WLAN_CFG_REO2PPE_RING_MASK_0, 0, 0, 0, 1049 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1050 /* ppe2tcl ring mask */ 1051 {0, WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 1052 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1053 /* umac reset mask */ 1054 {0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 0, 0, 0, 1055 0, 0, 0, 0, 0, 0, 0, 0}, 1056 }, 1057 /* Interrupt assignment for 3 MSI combination */ 1058 { 1059 /* tx ring masks */ 1060 { WLAN_CFG_TX_RING_MASK_0 | 1061 WLAN_CFG_TX_RING_MASK_1, 1062 WLAN_CFG_TX_RING_MASK_2 | 1063 WLAN_CFG_TX_RING_MASK_3, 1064 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1065 /* rx ring masks */ 1066 { WLAN_CFG_RX_RING_MASK_0 | 1067 WLAN_CFG_RX_RING_MASK_1, 1068 WLAN_CFG_RX_RING_MASK_2 | 1069 WLAN_CFG_RX_RING_MASK_3, 1070 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1071 /* rx mon ring masks */ 1072 { 0, 0, 1073 WLAN_CFG_RX_MON_RING_MASK_0 | 1074 WLAN_CFG_RX_MON_RING_MASK_1 | 1075 WLAN_CFG_RX_MON_RING_MASK_2, 1076 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1077 /* host2rxdma ring masks */ 1078 { 0, 0, 1079 WLAN_CFG_HOST2RXDMA_RING_MASK_0 | 1080 WLAN_CFG_HOST2RXDMA_RING_MASK_1 | 1081 WLAN_CFG_HOST2RXDMA_RING_MASK_2 | 1082 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1083 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1084 /* rxdma2host ring masks */ 1085 { 0, 0, 1086 WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 1087 WLAN_CFG_RXDMA2HOST_RING_MASK_1 | 1088 WLAN_CFG_RXDMA2HOST_RING_MASK_2 | 1089 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1090 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1091 /* host2rxdma mon ring masks */ 1092 { 0, 0, 1093 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 | 1094 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1 | 1095 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1096 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1097 /* rxdma2host mon ring masks */ 1098 { 0, 0, 1099 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 | 1100 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1 | 1101 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1102 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1103 /* rx err ring masks */ 1104 { 0, 0, 1105 WLAN_CFG_RX_ERR_RING_MASK_0 | 1106 WLAN_CFG_RX_ERR_RING_MASK_1 | 1107 WLAN_CFG_RX_ERR_RING_MASK_2 | 1108 WLAN_CFG_RX_ERR_RING_MASK_3, 1109 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1110 /* rx wbm rel ring masks */ 1111 { 0, 0, 1112 WLAN_CFG_RX_WBM_REL_RING_MASK_0 | 1113 WLAN_CFG_RX_WBM_REL_RING_MASK_1 | 1114 WLAN_CFG_RX_WBM_REL_RING_MASK_2 | 1115 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1116 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1117 /* reo status ring masks */ 1118 { 0, 0, 1119 WLAN_CFG_REO_STATUS_RING_MASK_0 | 1120 WLAN_CFG_REO_STATUS_RING_MASK_1 | 1121 WLAN_CFG_REO_STATUS_RING_MASK_2 | 1122 WLAN_CFG_REO_STATUS_RING_MASK_3, 1123 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1124 /* rx_ring_near_full_irq mask */ 1125 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1126 /* rx_ring_near_full_irq_2 mask */ 1127 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1128 /* tx_ring_near_full_irq mask */ 1129 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1130 /* host2txmon ring masks */ 1131 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1132 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1133 /* tx mon ring masks */ 1134 { WLAN_CFG_TX_MON_RING_MASK_0, 1135 WLAN_CFG_TX_MON_RING_MASK_1, 1136 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1137 /* Reo2ppe ring mask */ 1138 {WLAN_CFG_REO2PPE_RING_MASK_0, 0, 0, 0, 1139 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1140 /* ppe2tcl ring mask */ 1141 {0, WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 1142 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1143 /* umac reset mask */ 1144 {0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 0, 0, 1145 0, 0, 0, 0, 0, 0, 0, 0}, 1146 }, 1147 /* Interrupt assignment for 4 MSI combination */ 1148 { 1149 /* tx ring masks */ 1150 { WLAN_CFG_TX_RING_MASK_0, 1151 WLAN_CFG_TX_RING_MASK_1, 1152 WLAN_CFG_TX_RING_MASK_2, 1153 WLAN_CFG_TX_RING_MASK_3, 1154 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1155 /* rx ring masks */ 1156 { WLAN_CFG_RX_RING_MASK_0, 1157 WLAN_CFG_RX_RING_MASK_1, 1158 WLAN_CFG_RX_RING_MASK_2, 1159 WLAN_CFG_RX_RING_MASK_3, 1160 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1161 /* rx mon ring masks */ 1162 { WLAN_CFG_RX_MON_RING_MASK_0, 1163 WLAN_CFG_RX_MON_RING_MASK_1, 1164 WLAN_CFG_RX_MON_RING_MASK_2, 1165 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1166 /* host2rxdma ring masks */ 1167 { WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1168 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1169 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1170 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1171 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1172 /* rxdma2host ring masks */ 1173 { WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1174 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1175 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1176 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1177 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1178 /* host2rxdma mon ring masks */ 1179 { WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1180 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1181 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1182 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1183 /* rxdma2host mon ring masks */ 1184 { WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 1185 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1186 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1187 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1188 /* rx err ring masks */ 1189 { WLAN_CFG_RX_ERR_RING_MASK_0, 1190 WLAN_CFG_RX_ERR_RING_MASK_1, 1191 WLAN_CFG_RX_ERR_RING_MASK_2, 1192 WLAN_CFG_RX_ERR_RING_MASK_3, 1193 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1194 /* rx wbm rel ring masks */ 1195 { WLAN_CFG_RX_WBM_REL_RING_MASK_0, 1196 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 1197 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 1198 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1199 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1200 /* reo status ring masks */ 1201 { WLAN_CFG_REO_STATUS_RING_MASK_0, 1202 WLAN_CFG_REO_STATUS_RING_MASK_1, 1203 WLAN_CFG_REO_STATUS_RING_MASK_2, 1204 WLAN_CFG_REO_STATUS_RING_MASK_3, 1205 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1206 /* rx_ring_near_full_irq mask */ 1207 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1208 /* rx_ring_near_full_irq_2 mask */ 1209 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1210 /* tx_ring_near_full_irq mask */ 1211 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1212 /* host2txmon ring masks */ 1213 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1214 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1215 /* tx mon ring masks */ 1216 { WLAN_CFG_TX_MON_RING_MASK_0, 1217 WLAN_CFG_TX_MON_RING_MASK_1, 1218 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1219 /* Reo2ppe ring mask */ 1220 {0, WLAN_CFG_REO2PPE_RING_MASK_0, 0, 0, 0, 1221 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1222 /* ppe2tcl ring mask */ 1223 {0, 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 1224 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1225 /* umac reset mask */ 1226 {0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 0, 1227 0, 0, 0, 0, 0, 0, 0, 0}, 1228 }, 1229 /* Interrupt assignment for 5 MSI combination */ 1230 { 1231 /* tx ring masks */ 1232 { WLAN_CFG_TX_RING_MASK_0, 1233 WLAN_CFG_TX_RING_MASK_1, 1234 WLAN_CFG_TX_RING_MASK_2, 1235 WLAN_CFG_TX_RING_MASK_3, 1236 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1237 /* rx ring masks */ 1238 { WLAN_CFG_RX_RING_MASK_0, 1239 WLAN_CFG_RX_RING_MASK_1, 1240 WLAN_CFG_RX_RING_MASK_2, 1241 WLAN_CFG_RX_RING_MASK_3, 1242 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1243 /* rx mon ring masks */ 1244 { 0, 0, 0, 0, 1245 WLAN_CFG_RX_MON_RING_MASK_0 | 1246 WLAN_CFG_RX_MON_RING_MASK_1 | 1247 WLAN_CFG_RX_MON_RING_MASK_2, 1248 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1249 /* host2rxdma ring masks */ 1250 { 0, 0, 0, 0, 1251 WLAN_CFG_HOST2RXDMA_RING_MASK_0 | 1252 WLAN_CFG_HOST2RXDMA_RING_MASK_1 | 1253 WLAN_CFG_HOST2RXDMA_RING_MASK_2 | 1254 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1255 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1256 /* rxdma2host ring masks */ 1257 { 0, 0, 0, 0, 1258 WLAN_CFG_RXDMA2HOST_RING_MASK_0 | 1259 WLAN_CFG_RXDMA2HOST_RING_MASK_1 | 1260 WLAN_CFG_RXDMA2HOST_RING_MASK_2 | 1261 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1262 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1263 /* host2rxdma mon ring masks */ 1264 { 0, 0, 0, 0, 1265 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0 | 1266 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1 | 1267 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1268 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1269 /* rxdma2host mon ring masks */ 1270 { 0, 0, 0, 0, 1271 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0 | 1272 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1 | 1273 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1274 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1275 /* rx err ring masks */ 1276 { 0, 0, 0, 0, 1277 WLAN_CFG_RX_ERR_RING_MASK_0 | 1278 WLAN_CFG_RX_ERR_RING_MASK_1 | 1279 WLAN_CFG_RX_ERR_RING_MASK_2 | 1280 WLAN_CFG_RX_ERR_RING_MASK_3, 1281 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1282 /* rx wbm rel ring masks */ 1283 { 0, 0, 0, 0, 1284 WLAN_CFG_RX_WBM_REL_RING_MASK_0 | 1285 WLAN_CFG_RX_WBM_REL_RING_MASK_1 | 1286 WLAN_CFG_RX_WBM_REL_RING_MASK_2 | 1287 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1288 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1289 /* reo status ring masks */ 1290 { 0, 0, 0, 0, 1291 WLAN_CFG_REO_STATUS_RING_MASK_0 | 1292 WLAN_CFG_REO_STATUS_RING_MASK_1 | 1293 WLAN_CFG_REO_STATUS_RING_MASK_2 | 1294 WLAN_CFG_REO_STATUS_RING_MASK_3, 1295 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1296 /* rx_ring_near_full_irq mask */ 1297 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1298 /* rx_ring_near_full_irq_2 mask */ 1299 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1300 /* tx_ring_near_full_irq mask */ 1301 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1302 /* host2txmon ring masks */ 1303 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1304 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1305 /* tx mon ring masks */ 1306 { WLAN_CFG_TX_MON_RING_MASK_0, 1307 WLAN_CFG_TX_MON_RING_MASK_1, 1308 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1309 /* ppe ds wbm release ring ring mask */ 1310 { 0, WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 1311 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1312 /* Reo2ppe ring mask */ 1313 {0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 0, 0, 1314 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1315 /* ppe2tcl ring mask */ 1316 {0, 0, 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 1317 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1318 /* umac reset mask */ 1319 {0, 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 1320 0, 0, 0, 0, 0, 0, 0, 0}, 1321 }, 1322 /* Interrupt assignment for 6 MSI combination */ 1323 { 1324 /* tx ring masks */ 1325 { WLAN_CFG_TX_RING_MASK_0, 1326 WLAN_CFG_TX_RING_MASK_1, 1327 WLAN_CFG_TX_RING_MASK_2, 1328 WLAN_CFG_TX_RING_MASK_3, 1329 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1330 /* rx ring masks */ 1331 { 0, 0, 1332 WLAN_CFG_RX_RING_MASK_0, 1333 WLAN_CFG_RX_RING_MASK_1, 1334 WLAN_CFG_RX_RING_MASK_2, 1335 WLAN_CFG_RX_RING_MASK_3, 1336 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1337 /* rx mon ring masks */ 1338 { WLAN_CFG_RX_MON_RING_MASK_0, 1339 WLAN_CFG_RX_MON_RING_MASK_1, 1340 WLAN_CFG_RX_MON_RING_MASK_2, 1341 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1342 /* host2rxdma ring masks */ 1343 { WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1344 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1345 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1346 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1347 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1348 /* rxdma2host ring masks */ 1349 { WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1350 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1351 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1352 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1353 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1354 /* host2rxdma mon ring masks */ 1355 { WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1356 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1357 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1358 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1359 /* rxdma2host mon ring masks */ 1360 { WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 1361 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1362 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1363 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1364 /* rx err ring masks */ 1365 { WLAN_CFG_RX_ERR_RING_MASK_0, 1366 WLAN_CFG_RX_ERR_RING_MASK_1, 1367 WLAN_CFG_RX_ERR_RING_MASK_2, 1368 WLAN_CFG_RX_ERR_RING_MASK_3, 1369 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1370 /* rx wbm rel ring masks */ 1371 { WLAN_CFG_RX_WBM_REL_RING_MASK_0, 1372 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 1373 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 1374 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1375 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1376 /* reo status ring masks */ 1377 { WLAN_CFG_REO_STATUS_RING_MASK_0, 1378 WLAN_CFG_REO_STATUS_RING_MASK_1, 1379 WLAN_CFG_REO_STATUS_RING_MASK_2, 1380 WLAN_CFG_REO_STATUS_RING_MASK_3, 1381 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1382 /* rx_ring_near_full_irq mask */ 1383 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1384 /* rx_ring_near_full_irq_2 mask */ 1385 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1386 /* tx_ring_near_full_irq mask */ 1387 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1388 /* host2txmon ring masks */ 1389 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1390 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1391 /* tx mon ring masks */ 1392 { WLAN_CFG_TX_MON_RING_MASK_0, 1393 WLAN_CFG_TX_MON_RING_MASK_1, 1394 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1395 /* ppe ds wbm release ring ring mask */ 1396 { 0, 0, WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 1397 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1398 /* Reo2ppe ring mask */ 1399 {0, 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 0, 1400 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1401 /* ppe2tcl ring mask */ 1402 {0, 0, 0, 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 1403 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1404 /* umac reset mask */ 1405 {0, 0, 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 1406 0, 0, 0, 0, 0, 0, 0, 0}, 1407 }, 1408 /* Interrupt assignment for 7 MSI combination */ 1409 { 1410 /* tx ring masks */ 1411 { WLAN_CFG_TX_RING_MASK_0, 1412 WLAN_CFG_TX_RING_MASK_1, 1413 WLAN_CFG_TX_RING_MASK_2, 1414 WLAN_CFG_TX_RING_MASK_3, 1415 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1416 /* rx ring masks */ 1417 { 0, 0, 0, 1418 WLAN_CFG_RX_RING_MASK_0, 1419 WLAN_CFG_RX_RING_MASK_1, 1420 WLAN_CFG_RX_RING_MASK_2, 1421 WLAN_CFG_RX_RING_MASK_3, 1422 0, 0, 0, 0, 0, 0, 0, 0}, 1423 /* rx mon ring masks */ 1424 { 0, 0, 0, 1425 WLAN_CFG_RX_MON_RING_MASK_0, 1426 WLAN_CFG_RX_MON_RING_MASK_1, 1427 WLAN_CFG_RX_MON_RING_MASK_2, 1428 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1429 /* host2rxdma ring masks */ 1430 { 0, 0, 0, 1431 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1432 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1433 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1434 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1435 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1436 /* rxdma2host ring masks */ 1437 { 0, 0, 0, 1438 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1439 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1440 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1441 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1442 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1443 /* host2rxdma mon ring masks */ 1444 { 0, 0, 0, 1445 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1446 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1447 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1448 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1449 /* rxdma2host mon ring masks */ 1450 { 0, 0, 0, 1451 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 1452 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1453 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1454 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1455 /* rx err ring masks */ 1456 { 0, 0, 0, 1457 WLAN_CFG_RX_ERR_RING_MASK_0, 1458 WLAN_CFG_RX_ERR_RING_MASK_1, 1459 WLAN_CFG_RX_ERR_RING_MASK_2, 1460 WLAN_CFG_RX_ERR_RING_MASK_3, 1461 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1462 /* rx wbm rel ring masks */ 1463 { 0, 0, 0, 1464 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 1465 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 1466 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 1467 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1468 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1469 /* reo status ring masks */ 1470 { 0, 0, 0, 1471 WLAN_CFG_REO_STATUS_RING_MASK_0, 1472 WLAN_CFG_REO_STATUS_RING_MASK_1, 1473 WLAN_CFG_REO_STATUS_RING_MASK_2, 1474 WLAN_CFG_REO_STATUS_RING_MASK_3, 1475 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1476 /* rx_ring_near_full_irq mask */ 1477 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1478 /* rx_ring_near_full_irq_2 mask */ 1479 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1480 /* tx_ring_near_full_irq mask */ 1481 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1482 /* host2txmon ring masks */ 1483 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1484 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1485 /* tx mon ring masks */ 1486 { WLAN_CFG_TX_MON_RING_MASK_0, 1487 WLAN_CFG_TX_MON_RING_MASK_1, 1488 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1489 /* ppe ds wbm release ring ring mask */ 1490 { 0, 0, 0, WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 1491 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1492 /* Reo2ppe ring mask */ 1493 {0, 0, 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 0, 1494 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1495 /* ppe2tcl ring mask */ 1496 {0, 0, 0, 0, 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 1497 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1498 /* umac reset mask */ 1499 {0, 0, 0, 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 1500 0, 0, 0, 0, 0, 0, 0, 0}, 1501 }, 1502 /* Interrupt assignment for 8 MSI combination */ 1503 { 1504 /* tx ring masks */ 1505 { WLAN_CFG_TX_RING_MASK_0, 1506 WLAN_CFG_TX_RING_MASK_1, 1507 WLAN_CFG_TX_RING_MASK_2, 1508 WLAN_CFG_TX_RING_MASK_3, 1509 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1510 /* rx ring masks */ 1511 { 0, 0, 0, 0, 1512 WLAN_CFG_RX_RING_MASK_0, 1513 WLAN_CFG_RX_RING_MASK_1, 1514 WLAN_CFG_RX_RING_MASK_2, 1515 WLAN_CFG_RX_RING_MASK_3, 1516 0, 0, 0, 0, 0, 0, 0, 0}, 1517 /* rx mon ring masks */ 1518 { 0, 0, 0, 1519 WLAN_CFG_RX_MON_RING_MASK_0, 1520 WLAN_CFG_RX_MON_RING_MASK_1, 1521 WLAN_CFG_RX_MON_RING_MASK_2, 1522 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1523 /* host2rxdma ring masks */ 1524 { 0, 0, 0, 1525 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1526 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1527 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1528 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1529 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1530 /* rxdma2host ring masks */ 1531 { 0, 0, 0, 1532 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1533 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1534 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1535 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1536 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1537 /* host2rxdma mon ring masks */ 1538 { 0, 0, 0, 1539 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1540 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1541 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1542 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1543 /* rxdma2host mon ring masks */ 1544 { 0, 0, 0, 1545 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 1546 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1547 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1548 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1549 /* rx err ring masks */ 1550 { 0, 0, 0, 1551 WLAN_CFG_RX_ERR_RING_MASK_0, 1552 WLAN_CFG_RX_ERR_RING_MASK_1, 1553 WLAN_CFG_RX_ERR_RING_MASK_2, 1554 WLAN_CFG_RX_ERR_RING_MASK_3, 1555 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1556 /* rx wbm rel ring masks */ 1557 { 0, 0, 0, 1558 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 1559 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 1560 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 1561 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1562 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1563 /* reo status ring masks */ 1564 { 0, 0, 0, 1565 WLAN_CFG_REO_STATUS_RING_MASK_0, 1566 WLAN_CFG_REO_STATUS_RING_MASK_1, 1567 WLAN_CFG_REO_STATUS_RING_MASK_2, 1568 WLAN_CFG_REO_STATUS_RING_MASK_3, 1569 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1570 /* rx_ring_near_full_irq mask */ 1571 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1572 /* rx_ring_near_full_irq_2 mask */ 1573 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1574 /* tx_ring_near_full_irq mask */ 1575 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1576 /* host2txmon ring masks */ 1577 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1578 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1579 /* tx mon ring masks */ 1580 { WLAN_CFG_TX_MON_RING_MASK_0, 1581 WLAN_CFG_TX_MON_RING_MASK_1, 1582 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1583 /* ppe ds wbm release ring ring mask */ 1584 { 0, 0, 0, 0, WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 1585 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1586 /* Reo2ppe ring mask */ 1587 {0, 0, 0, 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 0, 1588 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1589 /* ppe2tcl ring mask */ 1590 {0, 0, 0, 0, 0, 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 1591 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1592 /* umac reset mask */ 1593 {0, 0, 0, 0, 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 1594 0, 0, 0, 0, 0, 0, 0, 0}, 1595 }, 1596 /* Interrupt assignment for 9 MSI combination */ 1597 { 1598 /* tx ring masks */ 1599 { WLAN_CFG_TX_RING_MASK_0, 1600 WLAN_CFG_TX_RING_MASK_1, 1601 WLAN_CFG_TX_RING_MASK_2, 1602 WLAN_CFG_TX_RING_MASK_3, 1603 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1604 /* rx ring masks */ 1605 { 0, 0, 0, 0, 1606 WLAN_CFG_RX_RING_MASK_0, 1607 WLAN_CFG_RX_RING_MASK_1, 1608 WLAN_CFG_RX_RING_MASK_2, 1609 WLAN_CFG_RX_RING_MASK_3, 1610 0, 0, 0, 0, 0, 0, 0, 0}, 1611 /* rx mon ring masks */ 1612 { 0, 0, 0, 1613 WLAN_CFG_RX_MON_RING_MASK_0, 1614 WLAN_CFG_RX_MON_RING_MASK_1, 1615 WLAN_CFG_RX_MON_RING_MASK_2, 1616 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1617 /* host2rxdma ring masks */ 1618 { 0, 0, 0, 1619 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1620 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1621 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1622 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1623 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1624 /* rxdma2host ring masks */ 1625 { 0, 0, 0, 1626 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1627 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1628 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1629 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1630 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1631 /* host2rxdma mon ring masks */ 1632 { 0, 0, 0, 1633 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1634 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1635 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1636 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1637 /* rxdma2host mon ring masks */ 1638 { 0, 0, 0, 1639 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 1640 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1641 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1642 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1643 /* rx err ring masks */ 1644 { 0, 0, 0, 1645 WLAN_CFG_RX_ERR_RING_MASK_0, 1646 WLAN_CFG_RX_ERR_RING_MASK_1, 1647 WLAN_CFG_RX_ERR_RING_MASK_2, 1648 WLAN_CFG_RX_ERR_RING_MASK_3, 1649 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1650 /* rx wbm rel ring masks */ 1651 { 0, 0, 0, 1652 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 1653 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 1654 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 1655 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1656 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1657 /* reo status ring masks */ 1658 { 0, 0, 0, 1659 WLAN_CFG_REO_STATUS_RING_MASK_0, 1660 WLAN_CFG_REO_STATUS_RING_MASK_1, 1661 WLAN_CFG_REO_STATUS_RING_MASK_2, 1662 WLAN_CFG_REO_STATUS_RING_MASK_3, 1663 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1664 /* rx_ring_near_full_irq mask */ 1665 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1666 /* rx_ring_near_full_irq_2 mask */ 1667 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1668 /* tx_ring_near_full_irq mask */ 1669 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1670 /* host2txmon ring masks */ 1671 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1672 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1673 /* tx mon ring masks */ 1674 { WLAN_CFG_TX_MON_RING_MASK_0, 1675 WLAN_CFG_TX_MON_RING_MASK_1, 1676 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1677 /* ppe ds wbm release ring ring mask */ 1678 { 0, 0, 0, 0, 0, WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 1679 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1680 /* Reo2ppe ring mask */ 1681 {0, 0, 0, 0, 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 1682 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1683 /* ppe2tcl ring mask */ 1684 {0, 0, 0, 0, 0, 0, 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 1685 0, 0, 0, 0, 0, 0, 0, 0}, 1686 /* umac reset mask */ 1687 {0, 0, 0, 0, 0, 0, 0, 0, 1688 WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 0, 0, 0, 0}, 1689 }, 1690 /* Interrupt assignment for 10 MSI combination */ 1691 { 1692 /* tx ring masks */ 1693 { WLAN_CFG_TX_RING_MASK_0, 1694 WLAN_CFG_TX_RING_MASK_1, 1695 WLAN_CFG_TX_RING_MASK_2, 1696 WLAN_CFG_TX_RING_MASK_3, 1697 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1698 /* rx ring masks */ 1699 { 0, 0, 0, 0, 1700 WLAN_CFG_RX_RING_MASK_0, 1701 WLAN_CFG_RX_RING_MASK_1, 1702 WLAN_CFG_RX_RING_MASK_2, 1703 WLAN_CFG_RX_RING_MASK_3, 1704 0, 0, 0, 0, 0, 0, 0, 0}, 1705 /* rx mon ring masks */ 1706 { 0, 0, 0, 1707 WLAN_CFG_RX_MON_RING_MASK_0, 1708 WLAN_CFG_RX_MON_RING_MASK_1, 1709 WLAN_CFG_RX_MON_RING_MASK_2, 1710 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1711 /* host2rxdma ring masks */ 1712 { 0, 0, 0, 1713 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1714 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1715 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1716 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1717 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1718 /* rxdma2host ring masks */ 1719 { 0, 0, 0, 1720 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1721 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1722 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1723 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1724 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1725 /* host2rxdma mon ring masks */ 1726 { 0, 0, 0, 1727 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1728 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1729 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1730 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1731 /* rxdma2host mon ring masks */ 1732 { 0, 0, 0, 1733 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 1734 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1735 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1736 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1737 /* rx err ring masks */ 1738 { 0, 0, 0, 1739 WLAN_CFG_RX_ERR_RING_MASK_0, 1740 WLAN_CFG_RX_ERR_RING_MASK_1, 1741 WLAN_CFG_RX_ERR_RING_MASK_2, 1742 WLAN_CFG_RX_ERR_RING_MASK_3, 1743 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1744 /* rx wbm rel ring masks */ 1745 { 0, 0, 0, 1746 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 1747 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 1748 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 1749 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1750 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1751 /* reo status ring masks */ 1752 { 0, 0, 0, 1753 WLAN_CFG_REO_STATUS_RING_MASK_0, 1754 WLAN_CFG_REO_STATUS_RING_MASK_1, 1755 WLAN_CFG_REO_STATUS_RING_MASK_2, 1756 WLAN_CFG_REO_STATUS_RING_MASK_3, 1757 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1758 /* rx_ring_near_full_irq mask */ 1759 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1760 /* rx_ring_near_full_irq_2 mask */ 1761 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1762 /* tx_ring_near_full_irq mask */ 1763 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1764 /* host2txmon ring masks */ 1765 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1766 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1767 /* tx mon ring masks */ 1768 { WLAN_CFG_TX_MON_RING_MASK_0, 1769 WLAN_CFG_TX_MON_RING_MASK_1, 1770 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1771 /* ppe ds wbm release ring ring mask */ 1772 { 0, 0, 0, 0, 0, 0, WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 1773 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1774 /* Reo2ppe ring mask */ 1775 {0, 0, 0, 0, 0, 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 1776 0, 0, 0, 0, 0, 0, 0, 0}, 1777 /* ppe2tcl ring mask */ 1778 {0, 0, 0, 0, 0, 0, 0, 0, 1779 WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 0, 0, 0, 0, 0, 0}, 1780 /* umac reset mask */ 1781 {0, 0, 0, 0, 0, 0, 0, 0, 1782 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 0, 0, 0}, 1783 }, 1784 /* Interrupt assignment for 11 MSI combination */ 1785 { 1786 /* tx ring masks */ 1787 { WLAN_CFG_TX_RING_MASK_0, 1788 WLAN_CFG_TX_RING_MASK_1, 1789 WLAN_CFG_TX_RING_MASK_2, 1790 WLAN_CFG_TX_RING_MASK_3, 1791 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1792 /* rx ring masks */ 1793 { 0, 0, 0, 0, 1794 WLAN_CFG_RX_RING_MASK_0, 1795 WLAN_CFG_RX_RING_MASK_1, 1796 WLAN_CFG_RX_RING_MASK_2, 1797 WLAN_CFG_RX_RING_MASK_3, 1798 0, 0, 0, 0, 0, 0, 0, 0}, 1799 /* rx mon ring masks */ 1800 { 0, 0, 0, 1801 WLAN_CFG_RX_MON_RING_MASK_0, 1802 WLAN_CFG_RX_MON_RING_MASK_1, 1803 WLAN_CFG_RX_MON_RING_MASK_2, 1804 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1805 /* host2rxdma ring masks */ 1806 { 0, 0, 0, 1807 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1808 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1809 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1810 WLAN_CFG_HOST2RXDMA_RING_MASK_3, 1811 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1812 /* rxdma2host ring masks */ 1813 { 0, 0, 0, 1814 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1815 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1816 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1817 WLAN_CFG_RXDMA2HOST_RING_MASK_3, 1818 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1819 /* host2rxdma mon ring masks */ 1820 { 0, 0, 0, 1821 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1822 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1823 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1824 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1825 /* rxdma2host mon ring masks */ 1826 { 0, 0, 0, 1827 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 1828 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1829 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1830 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1831 /* rx err ring masks */ 1832 { 0, 0, 0, 1833 WLAN_CFG_RX_ERR_RING_MASK_0, 1834 WLAN_CFG_RX_ERR_RING_MASK_1, 1835 WLAN_CFG_RX_ERR_RING_MASK_2, 1836 WLAN_CFG_RX_ERR_RING_MASK_3, 1837 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1838 /* rx wbm rel ring masks */ 1839 { 0, 0, 0, 1840 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 1841 WLAN_CFG_RX_WBM_REL_RING_MASK_1, 1842 WLAN_CFG_RX_WBM_REL_RING_MASK_2, 1843 WLAN_CFG_RX_WBM_REL_RING_MASK_3, 1844 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1845 /* reo status ring masks */ 1846 { 0, 0, 0, 1847 WLAN_CFG_REO_STATUS_RING_MASK_0, 1848 WLAN_CFG_REO_STATUS_RING_MASK_1, 1849 WLAN_CFG_REO_STATUS_RING_MASK_2, 1850 WLAN_CFG_REO_STATUS_RING_MASK_3, 1851 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1852 /* rx_ring_near_full_irq mask */ 1853 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1854 /* rx_ring_near_full_irq_2 mask */ 1855 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1856 /* tx_ring_near_full_irq mask */ 1857 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1858 /* host2txmon ring masks */ 1859 { WLAN_CFG_HOST2TXMON_RING_MASK_0, 1860 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1861 /* tx mon ring masks */ 1862 { WLAN_CFG_TX_MON_RING_MASK_0, 1863 WLAN_CFG_TX_MON_RING_MASK_1, 1864 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1865 /* ppe wbm ds release ring ring mask */ 1866 { 0, 0, 0, 0, 0, 0, 0, WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 1867 0, 0, 0, 0, 0, 0, 0, 0}, 1868 /* Reo2ppe ring mask */ 1869 {0, 0, 0, 0, 0, 0, 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 1870 0, 0, 0, 0, 0, 0, 0}, 1871 /* ppe2tcl ring mask */ 1872 {0, 0, 0, 0, 0, 0, 0, 0, 0, 1873 WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 0, 0, 0, 0, 0}, 1874 /* umac reset mask */ 1875 {0, 0, 0, 0, 0, 0, 0, 0, 1876 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 0, 0}, 1877 }, 1878 /* Interrupt assignment for 12 MSI combination */ 1879 { 1880 /* tx ring masks */ 1881 { WLAN_CFG_TX_RING_MASK_0, 1882 WLAN_CFG_TX_RING_MASK_1, 1883 WLAN_CFG_TX_RING_MASK_2, 1884 WLAN_CFG_TX_RING_MASK_3, 1885 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1886 /* rx ring masks */ 1887 { 0, 0, 0, 0, 1888 WLAN_CFG_RX_RING_MASK_0, 1889 WLAN_CFG_RX_RING_MASK_1, 1890 WLAN_CFG_RX_RING_MASK_2, 1891 WLAN_CFG_RX_RING_MASK_3, 1892 0, 0, 0, 0, 0, 0, 0, 0}, 1893 /* rx mon ring masks */ 1894 { 0, 0, 0, 0, 0, 0, 0, 0, 1895 WLAN_CFG_RX_MON_RING_MASK_0, 1896 WLAN_CFG_RX_MON_RING_MASK_1, 1897 WLAN_CFG_RX_MON_RING_MASK_2, 1898 0, 0, 0, 0, 0}, 1899 /* host2rxdma ring masks */ 1900 { 0, 0, 0, 0, 0, 0, 0, 0, 1901 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1902 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1903 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1904 0, 0, 0, 0, 0}, 1905 /* rxdma2host ring masks */ 1906 { 0, 0, 0, 0, 0, 0, 0, 0, 1907 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1908 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1909 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1910 0, 0, 0, 0, 0}, 1911 /* host2rxdma mon ring masks */ 1912 { 0, 0, 0, 0, 0, 0, 0, 0, 1913 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1914 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 1915 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 1916 0, 0, 0, 0, 0}, 1917 /* rxdma2host mon ring masks */ 1918 { 0, 0, 0, 0, 0, 0, 0, 0, 1919 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 1920 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 1921 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 1922 0, 0, 0, 0, 0}, 1923 /* rx err ring masks */ 1924 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1925 WLAN_CFG_RX_ERR_RING_MASK_0, 1926 0, 0, 0, 0}, 1927 /* rx wbm rel ring masks */ 1928 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1929 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 1930 0, 0, 0, 0}, 1931 /* reo status ring masks */ 1932 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1933 WLAN_CFG_REO_STATUS_RING_MASK_0, 1934 0, 0, 0, 0}, 1935 /* rx_ring_near_full_irq mask */ 1936 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1937 /* rx_ring_near_full_irq_2 mask */ 1938 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1939 /* tx_ring_near_full_irq mask */ 1940 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1941 /* host2txmon ring masks */ 1942 { 0, 0, 0, 0, 0, 0, 0, 0, 1943 WLAN_CFG_HOST2TXMON_RING_MASK_0, 1944 0, 0, 0, 0, 0, 0, 0}, 1945 /* tx mon ring masks */ 1946 { 0, 0, 0, 0, 0, 0, 0, 0, 1947 WLAN_CFG_TX_MON_RING_MASK_0, 1948 WLAN_CFG_TX_MON_RING_MASK_1, 1949 0, 0, 0, 0, 0, 0}, 1950 /* ppe ds wbm release ring ring mask */ 1951 { 0, 0, 0, 0, 0, 0, 0, 0, 1952 WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 0, 0, 0, 0, 0, 0, 0}, 1953 /* Reo2ppe ring mask */ 1954 {0, 0, 0, 0, 0, 0, 0, 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 1955 0, 0, 0, 0, 0, 0}, 1956 /* ppe2tcl ring mask */ 1957 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1958 WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 0, 0, 0, 0}, 1959 /* umac reset mask */ 1960 {0, 0, 0, 0, 0, 0, 0, 0, 1961 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0, 0}, 1962 }, 1963 /* Interrupt assignment for 13 MSI combination */ 1964 { 1965 /* tx ring masks */ 1966 { WLAN_CFG_TX_RING_MASK_0, 1967 WLAN_CFG_TX_RING_MASK_1, 1968 WLAN_CFG_TX_RING_MASK_2, 1969 WLAN_CFG_TX_RING_MASK_3, 1970 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 1971 /* rx ring masks */ 1972 { 0, 0, 0, 0, 1973 WLAN_CFG_RX_RING_MASK_0, 1974 WLAN_CFG_RX_RING_MASK_1, 1975 WLAN_CFG_RX_RING_MASK_2, 1976 WLAN_CFG_RX_RING_MASK_3, 1977 0, 0, 0, 0, 0, 0, 0, 0}, 1978 /* rx mon ring masks */ 1979 { 0, 0, 0, 0, 0, 0, 0, 0, 1980 WLAN_CFG_RX_MON_RING_MASK_0, 1981 WLAN_CFG_RX_MON_RING_MASK_1, 1982 WLAN_CFG_RX_MON_RING_MASK_2, 1983 0, 0, 0, 0, 0}, 1984 /* host2rxdma ring masks */ 1985 { 0, 0, 0, 0, 0, 0, 0, 0, 1986 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 1987 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 1988 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 1989 0, 0, 0, 0, 0}, 1990 /* rxdma2host ring masks */ 1991 { 0, 0, 0, 0, 0, 0, 0, 0, 1992 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 1993 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 1994 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 1995 0, 0, 0, 0, 0}, 1996 /* host2rxdma mon ring masks */ 1997 { 0, 0, 0, 0, 0, 0, 0, 0, 1998 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 1999 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 2000 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 2001 0, 0, 0, 0, 0}, 2002 /* rxdma2host mon ring masks */ 2003 { 0, 0, 0, 0, 0, 0, 0, 0, 2004 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 2005 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 2006 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 2007 0, 0, 0, 0, 0}, 2008 /* rx err ring masks */ 2009 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2010 WLAN_CFG_RX_ERR_RING_MASK_0, 2011 0, 0, 0, 0}, 2012 /* rx wbm rel ring masks */ 2013 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2014 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 2015 0, 0, 0, 0}, 2016 /* reo status ring masks */ 2017 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2018 WLAN_CFG_REO_STATUS_RING_MASK_0, 2019 0, 0, 0, 0}, 2020 /* rx_ring_near_full_irq mask */ 2021 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2022 /* rx_ring_near_full_irq_2 mask */ 2023 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2024 /* tx_ring_near_full_irq mask */ 2025 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2026 /* host2txmon ring masks */ 2027 { 0, 0, 0, 0, 0, 0, 0, 0, 2028 WLAN_CFG_HOST2TXMON_RING_MASK_0, 2029 0, 0, 0, 0, 0, 0, 0}, 2030 /* tx mon ring masks */ 2031 { 0, 0, 0, 0, 0, 0, 0, 0, 2032 WLAN_CFG_TX_MON_RING_MASK_0, 2033 WLAN_CFG_TX_MON_RING_MASK_1, 2034 0, 0, 0, 0, 0, 0}, 2035 /* ppe ds wbm release ring ring mask */ 2036 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 2037 WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 0, 0, 0, 0, 0, 0}, 2038 /* Reo2ppe ring mask */ 2039 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 2040 0, 0, 0, 0, 0}, 2041 /* ppe2tcl ring mask */ 2042 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2043 WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 0, 0, 0}, 2044 /* umac reset mask */ 2045 {0, 0, 0, 0, 0, 0, 0, 0, 2046 0, 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0, 0}, 2047 }, 2048 /* Interrupt assignment for 14 MSI combination */ 2049 { 2050 /* tx ring masks */ 2051 { WLAN_CFG_TX_RING_MASK_0, 2052 WLAN_CFG_TX_RING_MASK_1, 2053 WLAN_CFG_TX_RING_MASK_2, 2054 WLAN_CFG_TX_RING_MASK_3, 2055 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2056 /* rx ring masks */ 2057 { 0, 0, 0, 0, 2058 WLAN_CFG_RX_RING_MASK_0, 2059 WLAN_CFG_RX_RING_MASK_1, 2060 WLAN_CFG_RX_RING_MASK_2, 2061 WLAN_CFG_RX_RING_MASK_3, 2062 0, 0, 0, 0, 0, 0, 0, 0}, 2063 /* rx mon ring masks */ 2064 { 0, 0, 0, 0, 0, 0, 0, 0, 2065 WLAN_CFG_RX_MON_RING_MASK_0, 2066 WLAN_CFG_RX_MON_RING_MASK_1, 2067 WLAN_CFG_RX_MON_RING_MASK_2, 2068 0, 0, 0, 0, 0}, 2069 /* host2rxdma ring masks */ 2070 { 0, 0, 0, 0, 0, 0, 0, 0, 2071 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 2072 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 2073 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 2074 0, 0, 0, 0, 0}, 2075 /* rxdma2host ring masks */ 2076 { 0, 0, 0, 0, 0, 0, 0, 0, 2077 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 2078 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 2079 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 2080 0, 0, 0, 0, 0}, 2081 /* host2rxdma mon ring masks */ 2082 { 0, 0, 0, 0, 0, 0, 0, 0, 2083 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 2084 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 2085 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 2086 0, 0, 0, 0, 0}, 2087 /* rxdma2host mon ring masks */ 2088 { 0, 0, 0, 0, 0, 0, 0, 0, 2089 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 2090 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 2091 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 2092 0, 0, 0, 0, 0}, 2093 /* rx err ring masks */ 2094 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2095 WLAN_CFG_RX_ERR_RING_MASK_0, 2096 0, 0, 0, 0}, 2097 /* rx wbm rel ring masks */ 2098 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2099 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 2100 0, 0, 0, 0}, 2101 /* reo status ring masks */ 2102 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2103 WLAN_CFG_REO_STATUS_RING_MASK_0, 2104 0, 0, 0, 0}, 2105 /* rx_ring_near_full_irq mask */ 2106 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2107 /* rx_ring_near_full_irq_2 mask */ 2108 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2109 /* tx_ring_near_full_irq mask */ 2110 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2111 /* host2txmon ring masks */ 2112 { 0, 0, 0, 0, 0, 0, 0, 0, 2113 WLAN_CFG_HOST2TXMON_RING_MASK_0, 2114 0, 0, 0, 0, 0, 0, 0}, 2115 /* tx mon ring masks */ 2116 { 0, 0, 0, 0, 0, 0, 0, 0, 2117 WLAN_CFG_TX_MON_RING_MASK_0, 2118 WLAN_CFG_TX_MON_RING_MASK_1, 2119 0, 0, 0, 0, 0, 0}, 2120 /* ppe ds wbm release ring ring mask */ 2121 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2122 WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 0, 0, 0, 0, 0}, 2123 /* Reo2ppe ring mask */ 2124 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2125 WLAN_CFG_REO2PPE_RING_MASK_0, 0, 0, 0, 0}, 2126 /* ppe2tcl ring mask */ 2127 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2128 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 0, 0}, 2129 /* umac reset mask */ 2130 {0, 0, 0, 0, 0, 0, 0, 0, 2131 0, 0, 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0, 0}, 2132 }, 2133 /* Interrupt assignment for 15 MSI combination */ 2134 { 2135 /* tx ring masks */ 2136 { WLAN_CFG_TX_RING_MASK_0, 2137 WLAN_CFG_TX_RING_MASK_1, 2138 WLAN_CFG_TX_RING_MASK_2, 2139 WLAN_CFG_TX_RING_MASK_3, 2140 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2141 /* rx ring masks */ 2142 { 0, 0, 0, 0, 2143 WLAN_CFG_RX_RING_MASK_0, 2144 WLAN_CFG_RX_RING_MASK_1, 2145 WLAN_CFG_RX_RING_MASK_2, 2146 WLAN_CFG_RX_RING_MASK_3, 2147 0, 0, 0, 0, 0, 0, 0, 0}, 2148 /* rx mon ring masks */ 2149 { 0, 0, 0, 0, 0, 0, 0, 0, 2150 WLAN_CFG_RX_MON_RING_MASK_0, 2151 WLAN_CFG_RX_MON_RING_MASK_1, 2152 WLAN_CFG_RX_MON_RING_MASK_2, 2153 0, 0, 0, 0, 0}, 2154 /* host2rxdma ring masks */ 2155 { 0, 0, 0, 0, 0, 0, 0, 0, 2156 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 2157 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 2158 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 2159 0, 0, 0, 0, 0}, 2160 /* rxdma2host ring masks */ 2161 { 0, 0, 0, 0, 0, 0, 0, 0, 2162 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 2163 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 2164 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 2165 0, 0, 0, 0, 0}, 2166 /* host2rxdma mon ring masks */ 2167 { 0, 0, 0, 0, 0, 0, 0, 0, 2168 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 2169 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 2170 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 2171 0, 0, 0, 0, 0}, 2172 /* rxdma2host mon ring masks */ 2173 { 0, 0, 0, 0, 0, 0, 0, 0, 2174 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 2175 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 2176 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 2177 0, 0, 0, 0, 0}, 2178 /* rx err ring masks */ 2179 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2180 WLAN_CFG_RX_ERR_RING_MASK_0, 2181 0, 0, 0, 0}, 2182 /* rx wbm rel ring masks */ 2183 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2184 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 2185 0, 0, 0, 0}, 2186 /* reo status ring masks */ 2187 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2188 WLAN_CFG_REO_STATUS_RING_MASK_0, 2189 0, 0, 0, 0}, 2190 /* rx_ring_near_full_irq mask */ 2191 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2192 /* rx_ring_near_full_irq_2 mask */ 2193 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2194 /* tx_ring_near_full_irq mask */ 2195 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2196 /* host2txmon ring masks */ 2197 { 0, 0, 0, 0, 0, 0, 0, 0, 2198 WLAN_CFG_HOST2TXMON_RING_MASK_0, 2199 0, 0, 0, 0, 0, 0, 0}, 2200 /* tx mon ring masks */ 2201 { 0, 0, 0, 0, 0, 0, 0, 0, 2202 WLAN_CFG_TX_MON_RING_MASK_0, 2203 WLAN_CFG_TX_MON_RING_MASK_1, 2204 0, 0, 0, 0, 0, 0}, 2205 /* ppe ds wbm release ring ring mask */ 2206 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2207 WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 0, 0, 0, 0}, 2208 /* Reo2ppe ring mask */ 2209 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2210 0, WLAN_CFG_REO2PPE_RING_MASK_0, 0, 0, 0}, 2211 /* ppe2tcl ring mask */ 2212 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2213 0, 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 0, 0}, 2214 /* umac reset mask */ 2215 {0, 0, 0, 0, 0, 0, 0, 0, 2216 0, 0, 0, 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0, 0}, 2217 }, 2218 /* Interrupt assignment for 16 MSI combination */ 2219 { 2220 /* tx ring masks */ 2221 { WLAN_CFG_TX_RING_MASK_0, 2222 WLAN_CFG_TX_RING_MASK_1, 2223 WLAN_CFG_TX_RING_MASK_2, 2224 WLAN_CFG_TX_RING_MASK_3, 2225 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2226 /* rx ring masks */ 2227 { 0, 0, 0, 0, 2228 WLAN_CFG_RX_RING_MASK_0, 2229 WLAN_CFG_RX_RING_MASK_1, 2230 WLAN_CFG_RX_RING_MASK_2, 2231 WLAN_CFG_RX_RING_MASK_3, 2232 0, 0, 0, 0, 0, 0, 0, 0}, 2233 /* rx mon ring masks */ 2234 { 0, 0, 0, 0, 0, 0, 0, 0, 2235 WLAN_CFG_RX_MON_RING_MASK_0, 2236 WLAN_CFG_RX_MON_RING_MASK_1, 2237 WLAN_CFG_RX_MON_RING_MASK_2, 2238 0, 0, 0, 0, 0}, 2239 /* host2rxdma ring masks */ 2240 { 0, 0, 0, 0, 0, 0, 0, 0, 2241 WLAN_CFG_HOST2RXDMA_RING_MASK_0, 2242 WLAN_CFG_HOST2RXDMA_RING_MASK_1, 2243 WLAN_CFG_HOST2RXDMA_RING_MASK_2, 2244 0, 0, 0, 0, 0}, 2245 /* rxdma2host ring masks */ 2246 { 0, 0, 0, 0, 0, 0, 0, 0, 2247 WLAN_CFG_RXDMA2HOST_RING_MASK_0, 2248 WLAN_CFG_RXDMA2HOST_RING_MASK_1, 2249 WLAN_CFG_RXDMA2HOST_RING_MASK_2, 2250 0, 0, 0, 0, 0}, 2251 /* host2rxdma mon ring masks */ 2252 { 0, 0, 0, 0, 0, 0, 0, 0, 2253 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_0, 2254 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_1, 2255 WLAN_CFG_HOST2RXDMA_MON_RING_MASK_2, 2256 0, 0, 0, 0, 0}, 2257 /* rxdma2host mon ring masks */ 2258 { 0, 0, 0, 0, 0, 0, 0, 0, 2259 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_0, 2260 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_1, 2261 WLAN_CFG_RXDMA2HOST_MON_RING_MASK_2, 2262 0, 0, 0, 0, 0}, 2263 /* rx err ring masks */ 2264 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2265 WLAN_CFG_RX_ERR_RING_MASK_0, 2266 0, 0, 0, 0}, 2267 /* rx wbm rel ring masks */ 2268 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2269 WLAN_CFG_RX_WBM_REL_RING_MASK_0, 2270 0, 0, 0, 0}, 2271 /* reo status ring masks */ 2272 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2273 WLAN_CFG_REO_STATUS_RING_MASK_0, 2274 0, 0, 0, 0}, 2275 /* rx_ring_near_full_irq mask */ 2276 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2277 /* rx_ring_near_full_irq_2 mask */ 2278 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2279 /* tx_ring_near_full_irq mask */ 2280 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 2281 /* host2txmon ring masks */ 2282 { 0, 0, 0, 0, 0, 0, 0, 0, 2283 WLAN_CFG_HOST2TXMON_RING_MASK_0, 2284 0, 0, 0, 0, 0, 0, 0}, 2285 /* tx mon ring masks */ 2286 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 2287 WLAN_CFG_TX_MON_RING_MASK_0, 2288 WLAN_CFG_TX_MON_RING_MASK_1, 2289 0, 0, 0, 0, 0}, 2290 /* ppe ds wbm release ring ring mask */ 2291 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2292 0, WLAN_CFG_PPEDS_WBM_RELEASE_RING_MASK_0, 0, 0, 0}, 2293 /* Reo2ppe ring mask */ 2294 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2295 0, 0, WLAN_CFG_REO2PPE_RING_MASK_0, 0, 0}, 2296 /* ppe2tcl ring mask */ 2297 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2298 0, 0, 0, WLAN_CFG_PPE2TCL_RING_MASK_0, 0}, 2299 /* umac reset mask */ 2300 {0, 0, 0, 0, 0, 0, 0, 0, 2301 0, 0, 0, 0, 0, 0, 0, WLAN_CFG_UMAC_RESET_INTR_MASK_0}, 2302 }, 2303 }; 2304 #endif 2305 #endif 2306 2307 /* g_wlan_srng_cfg[] - Per ring_type specific configuration */ 2308 struct wlan_srng_cfg g_wlan_srng_cfg[MAX_RING_TYPES]; 2309 2310 /* REO_DST ring configuration */ 2311 struct wlan_srng_cfg wlan_srng_reo_cfg = { 2312 .timer_threshold = WLAN_CFG_INT_TIMER_THRESHOLD_REO_RING, 2313 .batch_count_threshold = WLAN_CFG_INT_BATCH_THRESHOLD_REO_RING, 2314 .low_threshold = 0, 2315 }; 2316 2317 /* WBM2SW_RELEASE ring configuration */ 2318 struct wlan_srng_cfg wlan_srng_wbm_release_cfg = { 2319 .timer_threshold = WLAN_CFG_INT_TIMER_THRESHOLD_WBM_RELEASE_RING, 2320 .batch_count_threshold = 0, 2321 .low_threshold = 0, 2322 }; 2323 2324 /* RXDMA_BUF ring configuration */ 2325 struct wlan_srng_cfg wlan_srng_rxdma_buf_cfg = { 2326 .timer_threshold = WLAN_CFG_INT_TIMER_THRESHOLD_RX, 2327 .batch_count_threshold = 0, 2328 .low_threshold = WLAN_CFG_RXDMA_REFILL_RING_SIZE >> 3, 2329 }; 2330 2331 /* RXDMA_MONITOR_BUF ring configuration */ 2332 struct wlan_srng_cfg wlan_srng_rxdma_monitor_buf_cfg = { 2333 .timer_threshold = WLAN_CFG_INT_TIMER_THRESHOLD_RX, 2334 .batch_count_threshold = 0, 2335 .low_threshold = WLAN_CFG_RXDMA_MONITOR_BUF_RING_SIZE >> 3, 2336 }; 2337 2338 /* RXDMA_MONITOR_STATUS ring configuration */ 2339 #ifdef DP_CON_MON_MSI_ENABLED 2340 /* 2341 * Configure batch count threshold as 1 to enable interrupt 2342 * when HW updated TP (monitor status buffer DMA is done), 2343 * then host could reap monitor status srng. timer threshold 2344 * based interrupt is only used for low threshold interrupt which 2345 * can not be used for monitor status buffer reaping directly 2346 * unless configure low threshold value to a big value, perhaps 2347 * (number of entries - 2). 2348 */ 2349 struct wlan_srng_cfg wlan_srng_rxdma_monitor_status_cfg = { 2350 .timer_threshold = WLAN_CFG_INT_TIMER_THRESHOLD_RX, 2351 .batch_count_threshold = 1, 2352 .low_threshold = WLAN_CFG_RXDMA_MONITOR_STATUS_RING_SIZE >> 3, 2353 }; 2354 #else 2355 struct wlan_srng_cfg wlan_srng_rxdma_monitor_status_cfg = { 2356 .timer_threshold = WLAN_CFG_INT_TIMER_THRESHOLD_RX, 2357 .batch_count_threshold = 0, 2358 .low_threshold = WLAN_CFG_RXDMA_MONITOR_STATUS_RING_SIZE >> 3, 2359 }; 2360 #endif 2361 2362 /* TX_MONITOR_BUF ring configuration */ 2363 struct wlan_srng_cfg wlan_srng_tx_monitor_buf_cfg = { 2364 .timer_threshold = WLAN_CFG_INT_TIMER_THRESHOLD_TX, 2365 .batch_count_threshold = 0, 2366 .low_threshold = WLAN_CFG_TX_MONITOR_BUF_RING_SIZE_MAX >> 3, 2367 }; 2368 2369 /* DEFAULT_CONFIG ring configuration */ 2370 struct wlan_srng_cfg wlan_srng_default_cfg = { 2371 .timer_threshold = WLAN_CFG_INT_TIMER_THRESHOLD_OTHER, 2372 .batch_count_threshold = WLAN_CFG_INT_BATCH_THRESHOLD_OTHER, 2373 .low_threshold = 0, 2374 }; 2375 2376 /* DEFAULT_CONFIG source ring configuration */ 2377 struct wlan_srng_cfg wlan_src_srng_default_cfg = { 2378 .timer_threshold = 0, 2379 .batch_count_threshold = 0, 2380 .low_threshold = 0, 2381 }; 2382 2383 void wlan_set_srng_cfg(struct wlan_srng_cfg **wlan_cfg) 2384 { 2385 g_wlan_srng_cfg[REO_DST] = wlan_srng_reo_cfg; 2386 g_wlan_srng_cfg[WBM2SW_RELEASE] = wlan_srng_wbm_release_cfg; 2387 g_wlan_srng_cfg[REO_EXCEPTION] = wlan_srng_default_cfg; 2388 g_wlan_srng_cfg[REO_REINJECT] = wlan_src_srng_default_cfg; 2389 g_wlan_srng_cfg[REO_CMD] = wlan_src_srng_default_cfg; 2390 g_wlan_srng_cfg[REO_STATUS] = wlan_srng_default_cfg; 2391 g_wlan_srng_cfg[TCL_DATA] = wlan_src_srng_default_cfg; 2392 g_wlan_srng_cfg[TCL_CMD_CREDIT] = wlan_src_srng_default_cfg; 2393 g_wlan_srng_cfg[TCL_STATUS] = wlan_srng_default_cfg; 2394 g_wlan_srng_cfg[WBM_IDLE_LINK] = wlan_src_srng_default_cfg; 2395 g_wlan_srng_cfg[SW2WBM_RELEASE] = wlan_src_srng_default_cfg; 2396 g_wlan_srng_cfg[RXDMA_BUF] = wlan_srng_rxdma_buf_cfg; 2397 g_wlan_srng_cfg[RXDMA_DST] = wlan_srng_default_cfg; 2398 g_wlan_srng_cfg[RXDMA_MONITOR_BUF] = 2399 wlan_srng_rxdma_monitor_buf_cfg; 2400 g_wlan_srng_cfg[RXDMA_MONITOR_STATUS] = 2401 wlan_srng_rxdma_monitor_status_cfg; 2402 g_wlan_srng_cfg[RXDMA_MONITOR_DST] = wlan_srng_default_cfg; 2403 g_wlan_srng_cfg[REO2PPE] = wlan_srng_default_cfg; 2404 g_wlan_srng_cfg[PPE2TCL] = wlan_srng_default_cfg; 2405 g_wlan_srng_cfg[RXDMA_MONITOR_DESC] = wlan_srng_default_cfg; 2406 g_wlan_srng_cfg[DIR_BUF_RX_DMA_SRC] = wlan_srng_default_cfg; 2407 #ifdef WLAN_FEATURE_CIF_CFR 2408 g_wlan_srng_cfg[WIFI_POS_SRC] = wlan_srng_default_cfg; 2409 #endif 2410 g_wlan_srng_cfg[TX_MONITOR_BUF] = wlan_srng_tx_monitor_buf_cfg; 2411 *wlan_cfg = g_wlan_srng_cfg; 2412 } 2413 2414 static const uint8_t rx_fst_toeplitz_key[WLAN_CFG_RX_FST_TOEPLITZ_KEYLEN] = { 2415 0x6d, 0x5a, 0x56, 0xda, 0x25, 0x5b, 0x0e, 0xc2, 2416 0x41, 0x67, 0x25, 0x3d, 0x43, 0xa3, 0x8f, 0xb0, 2417 0xd0, 0xca, 0x2b, 0xcb, 0xae, 0x7b, 0x30, 0xb4, 2418 0x77, 0xcb, 0x2d, 0xa3, 0x80, 0x30, 0xf2, 0x0c, 2419 0x6a, 0x42, 0xb7, 0x3b, 0xbe, 0xac, 0x01, 0xfa 2420 }; 2421 2422 #if defined(WLAN_MAX_PDEVS) && (WLAN_MAX_PDEVS == 1) 2423 void wlan_cfg_fill_interrupt_mask(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx, 2424 int num_dp_msi, 2425 int interrupt_mode, 2426 bool is_monitor_mode) 2427 { int i = 0; 2428 const uint8_t *tx_ring_intr_mask = 2429 wlan_cfg_get_tx_ring_int_mask(wlan_cfg_ctx); 2430 2431 for (i = 0; i < WLAN_CFG_INT_NUM_CONTEXTS; i++) { 2432 wlan_cfg_ctx->int_tx_ring_mask[i] = tx_ring_intr_mask[i]; 2433 if (wlan_cfg_ctx->int_tx_ring_mask[i]) 2434 wlan_cfg_ctx->tx_rings_grp_bitmap |= BIT(i); 2435 2436 wlan_cfg_ctx->int_rx_mon_ring_mask[i] = 2437 rx_mon_ring_mask_msi[i]; 2438 wlan_cfg_ctx->int_tx_mon_ring_mask[i] = 0; 2439 wlan_cfg_ctx->int_rx_err_ring_mask[i] = 2440 rx_err_ring_mask_msi[i]; 2441 wlan_cfg_ctx->int_rx_wbm_rel_ring_mask[i] = 2442 rx_wbm_rel_ring_mask_msi[i]; 2443 wlan_cfg_ctx->int_reo_status_ring_mask[i] = 2444 reo_status_ring_mask_msi[i]; 2445 if (is_monitor_mode) { 2446 wlan_cfg_ctx->int_rx_ring_mask[i] = 0; 2447 if (interrupt_mode == DP_INTR_POLL) 2448 wlan_cfg_ctx->int_rxdma2host_ring_mask[i] = 0; 2449 else 2450 wlan_cfg_ctx->int_rxdma2host_ring_mask[i] = 2451 rxdma2host_ring_mask_msi[i]; 2452 } else { 2453 wlan_cfg_ctx->int_rx_ring_mask[i] = 2454 rx_ring_mask_msi[i]; 2455 wlan_cfg_ctx->int_rxdma2host_ring_mask[i] = 2456 rxdma2host_ring_mask_msi[i]; 2457 } 2458 wlan_cfg_ctx->int_host2rxdma_ring_mask[i] = 2459 host2rxdma_ring_mask_msi[i]; 2460 wlan_cfg_ctx->int_host2rxdma_mon_ring_mask[i] = 2461 host2rxdma_mon_ring_mask_msi[i]; 2462 wlan_cfg_ctx->int_rxdma2host_mon_ring_mask[i] = 2463 rxdma2host_mon_ring_mask_msi[i]; 2464 wlan_cfg_ctx->int_rx_ring_near_full_irq_1_mask[i] = 2465 rx_ring_near_full_irq_1_mask_msi[i]; 2466 wlan_cfg_ctx->int_rx_ring_near_full_irq_2_mask[i] = 2467 rx_ring_near_full_irq_2_mask_msi[i]; 2468 wlan_cfg_ctx->int_tx_ring_near_full_irq_mask[i] = 2469 tx_ring_near_full_irq_mask_msi[i]; 2470 } 2471 } 2472 2473 #else 2474 2475 void wlan_cfg_fill_interrupt_mask(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx, 2476 int num_dp_msi, 2477 int interrupt_mode, 2478 bool is_monitor_mode) 2479 { 2480 int i = 0; 2481 int interrupt_index = 0; 2482 int int_host2rxdma_mon_ring_mask; 2483 bool host2rxmon_mask_set = false; 2484 bool txmon_hw_support = false; 2485 2486 if(interrupt_mode == DP_INTR_INTEGRATED) { 2487 interrupt_index = 0; 2488 } else if (interrupt_mode == DP_INTR_MSI || interrupt_mode == 2489 DP_INTR_POLL) { 2490 interrupt_index = num_dp_msi; 2491 } else { 2492 qdf_err("Interrupt mode %d", interrupt_mode); 2493 } 2494 2495 for (i = 0; i < WLAN_CFG_INT_NUM_CONTEXTS; i++) { 2496 wlan_cfg_ctx->int_tx_ring_mask[i] = 2497 dp_mask_assignment[interrupt_index].tx_ring_mask[i]; 2498 wlan_cfg_ctx->int_rx_mon_ring_mask[i] = 2499 dp_mask_assignment[interrupt_index].rx_mon_ring_mask[i]; 2500 wlan_cfg_ctx->int_rx_err_ring_mask[i] = 2501 dp_mask_assignment[interrupt_index].rx_err_ring_mask[i]; 2502 wlan_cfg_ctx->int_rx_wbm_rel_ring_mask[i] = 2503 dp_mask_assignment[interrupt_index].rx_wbm_rel_ring_mask[i]; 2504 wlan_cfg_ctx->int_reo_status_ring_mask[i] = 2505 dp_mask_assignment[interrupt_index].reo_status_ring_mask[i]; 2506 wlan_cfg_ctx->int_ppeds_wbm_release_ring_mask[i] = 2507 dp_mask_assignment[interrupt_index].ppeds_wbm_release_ring_mask[i]; 2508 wlan_cfg_ctx->int_ppe2tcl_ring_mask[i] = 2509 dp_mask_assignment[interrupt_index].ppe2tcl_ring_mask[i]; 2510 wlan_cfg_ctx->int_reo2ppe_ring_mask[i] = 2511 dp_mask_assignment[interrupt_index].reo2ppe_ring_mask[i]; 2512 if (is_monitor_mode) { 2513 wlan_cfg_ctx->int_rx_ring_mask[i] = 0; 2514 wlan_cfg_ctx->int_rxdma2host_ring_mask[i] = 0; 2515 } else { 2516 wlan_cfg_ctx->int_rx_ring_mask[i] = 2517 dp_mask_assignment[interrupt_index].rx_ring_mask[i]; 2518 wlan_cfg_ctx->int_rxdma2host_ring_mask[i] = 2519 dp_mask_assignment[interrupt_index].rxdma2host_ring_mask[i]; 2520 } 2521 wlan_cfg_ctx->int_host2rxdma_ring_mask[i] = 2522 dp_mask_assignment[interrupt_index].host2rxdma_ring_mask[i]; 2523 wlan_cfg_ctx->int_host2rxdma_mon_ring_mask[i] = 2524 dp_mask_assignment[interrupt_index].host2rxdma_mon_ring_mask[i]; 2525 wlan_cfg_ctx->int_rxdma2host_mon_ring_mask[i] = 2526 dp_mask_assignment[interrupt_index].rxdma2host_mon_ring_mask[i]; 2527 wlan_cfg_ctx->int_rx_ring_near_full_irq_1_mask[i] = 2528 dp_mask_assignment[interrupt_index].rx_ring_near_full_irq_1_mask[i]; 2529 wlan_cfg_ctx->int_rx_ring_near_full_irq_2_mask[i] = 2530 dp_mask_assignment[interrupt_index].rx_ring_near_full_irq_2_mask[i]; 2531 wlan_cfg_ctx->int_tx_ring_near_full_irq_mask[i] = 2532 dp_mask_assignment[interrupt_index].tx_ring_near_full_irq_mask[i]; 2533 2534 txmon_hw_support = wlan_cfg_get_txmon_hw_support(wlan_cfg_ctx); 2535 if (txmon_hw_support) { 2536 wlan_cfg_ctx->int_tx_mon_ring_mask[i] = 2537 dp_mask_assignment[interrupt_index].tx_mon_ring_mask[i]; 2538 wlan_cfg_ctx->int_host2txmon_ring_mask[i] = 2539 dp_mask_assignment[interrupt_index].host2txmon_ring_mask[i]; 2540 int_host2rxdma_mon_ring_mask = 2541 dp_mask_assignment[interrupt_index].host2rxdma_mon_ring_mask[i]; 2542 if (int_host2rxdma_mon_ring_mask && !host2rxmon_mask_set) { 2543 wlan_cfg_ctx->int_host2rxdma_mon_ring_mask[interrupt_index] = 2544 dp_mask_assignment[interrupt_index].host2rxdma_mon_ring_mask[i]; 2545 host2rxmon_mask_set = true; 2546 } 2547 } else { 2548 wlan_cfg_ctx->int_tx_mon_ring_mask[i] = 0; 2549 wlan_cfg_ctx->int_host2txmon_ring_mask[i] = 0; 2550 wlan_cfg_ctx->int_host2rxdma_mon_ring_mask[i] = 2551 dp_mask_assignment[interrupt_index].host2rxdma_mon_ring_mask[i]; 2552 } 2553 wlan_cfg_ctx->int_umac_reset_intr_mask[i] = 2554 dp_mask_assignment[interrupt_index].umac_reset_intr_mask[i]; 2555 } 2556 } 2557 #endif 2558 2559 #ifdef IPA_OFFLOAD 2560 2561 #define WLAN_CFG_IPA_ENABLE_MASK BIT(0) 2562 #ifdef IPA_WDI3_TX_TWO_PIPES 2563 /** 2564 * wlan_soc_ipa_cfg_attach() - Update ipa tx and tx alt config 2565 * in dp soc cfg context 2566 * @psoc: Object manager psoc 2567 * @wlan_cfg_ctx: dp soc cfg ctx 2568 * 2569 * Return: None 2570 */ 2571 static void 2572 wlan_soc_ipa_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2573 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2574 { 2575 if (ucfg_ipa_get_pld_enable()) { 2576 wlan_cfg_ctx->ipa_enabled = 2577 (cfg_get(psoc, CFG_DP_IPA_OFFLOAD_CONFIG) & 2578 WLAN_CFG_IPA_ENABLE_MASK); 2579 dp_info("is IPA enabled from ini: %d", 2580 wlan_cfg_ctx->ipa_enabled); 2581 } else { 2582 wlan_cfg_ctx->ipa_enabled = false; 2583 dp_info("IPA disabled from platform driver"); 2584 } 2585 wlan_cfg_ctx->ipa_tx_ring_size = 2586 cfg_get(psoc, CFG_DP_IPA_TX_RING_SIZE); 2587 wlan_cfg_ctx->ipa_tx_comp_ring_size = 2588 cfg_get(psoc, CFG_DP_IPA_TX_COMP_RING_SIZE); 2589 wlan_cfg_ctx->ipa_tx_alt_ring_size = 2590 cfg_get(psoc, CFG_DP_IPA_TX_ALT_RING_SIZE); 2591 wlan_cfg_ctx->ipa_tx_alt_comp_ring_size = 2592 cfg_get(psoc, CFG_DP_IPA_TX_ALT_COMP_RING_SIZE); 2593 } 2594 #else /* !IPA_WDI3_TX_TWO_PIPES */ 2595 /** 2596 * wlan_soc_ipa_cfg_attach() - Update ipa config in dp soc 2597 * cfg context 2598 * @psoc: Object manager psoc 2599 * @wlan_cfg_ctx: dp soc cfg ctx 2600 * 2601 * Return: None 2602 */ 2603 static void 2604 wlan_soc_ipa_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2605 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2606 { 2607 if (ucfg_ipa_get_pld_enable()) { 2608 wlan_cfg_ctx->ipa_enabled = 2609 (cfg_get(psoc, CFG_DP_IPA_OFFLOAD_CONFIG) & 2610 WLAN_CFG_IPA_ENABLE_MASK); 2611 dp_info("is IPA enabled from ini: %d", 2612 wlan_cfg_ctx->ipa_enabled); 2613 } else { 2614 wlan_cfg_ctx->ipa_enabled = false; 2615 dp_info("IPA disabled from platform driver"); 2616 } 2617 wlan_cfg_ctx->ipa_tx_ring_size = 2618 cfg_get(psoc, CFG_DP_IPA_TX_RING_SIZE); 2619 wlan_cfg_ctx->ipa_tx_comp_ring_size = 2620 cfg_get(psoc, CFG_DP_IPA_TX_COMP_RING_SIZE); 2621 } 2622 #endif /* IPA_WDI3_TX_TWO_PIPES */ 2623 #else /* !IPA_OFFLOAD */ 2624 static inline void 2625 wlan_soc_ipa_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2626 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2627 { 2628 } 2629 #endif 2630 2631 #ifdef DP_HW_COOKIE_CONVERT_EXCEPTION 2632 static void 2633 wlan_soc_hw_cc_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2634 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2635 { 2636 wlan_cfg_ctx->hw_cc_enabled = 2637 cfg_get(psoc, CFG_DP_HW_CC_ENABLE); 2638 } 2639 #else 2640 static void 2641 wlan_soc_hw_cc_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2642 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2643 { 2644 wlan_cfg_ctx->hw_cc_enabled = true; 2645 } 2646 #endif 2647 2648 #ifdef WLAN_SUPPORT_PPEDS 2649 /** 2650 * wlan_soc_ppe_cfg_attach() - Update ppe config in dp soc 2651 * cfg context 2652 * @psoc: Object manager psoc 2653 * @wlan_cfg_ctx: dp soc cfg ctx 2654 * 2655 * Return: None 2656 */ 2657 static void 2658 wlan_soc_ppe_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2659 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2660 { 2661 wlan_cfg_ctx->ppeds_enable = cfg_get(psoc, CFG_DP_PPEDS_ENABLE); 2662 wlan_cfg_ctx->reo2ppe_ring = cfg_get(psoc, CFG_DP_REO2PPE_RING); 2663 wlan_cfg_ctx->ppe2tcl_ring = cfg_get(psoc, CFG_DP_PPE2TCL_RING); 2664 wlan_cfg_ctx->ppeds_num_tx_desc = cfg_get(psoc, CFG_DP_PPEDS_TX_DESC); 2665 wlan_cfg_ctx->ppeds_tx_comp_napi_budget = 2666 cfg_get(psoc, CFG_DP_PPEDS_TX_CMP_NAPI_BUDGET); 2667 } 2668 #else 2669 static inline void 2670 wlan_soc_ppe_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2671 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2672 { 2673 } 2674 #endif 2675 2676 #if defined(WLAN_FEATURE_11BE_MLO) && defined(WLAN_MLO_MULTI_CHIP) 2677 /** 2678 * wlan_cfg_get_lsb_set_pos() - returns position of LSB which is set 2679 * @val: value to test 2680 * 2681 * Return: position of LSB which is set 2682 */ 2683 static uint8_t wlan_cfg_get_lsb_set_pos(uint8_t val) 2684 { 2685 uint8_t pos = 0; 2686 2687 while (pos < 8) { 2688 if (val & (1 << pos)) 2689 return pos; 2690 2691 pos++; 2692 } 2693 2694 return 0; 2695 } 2696 2697 /** 2698 * wlan_multi_soc_mlo_cfg_attach() - Update multi soc mlo config in dp soc 2699 * cfg context 2700 * @psoc: Object manager psoc 2701 * @wlan_cfg_ctx: dp soc cfg ctx 2702 * 2703 * Return: None 2704 */ 2705 static void 2706 wlan_multi_soc_mlo_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2707 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2708 { 2709 uint8_t rx_ring_map; 2710 2711 rx_ring_map = 2712 cfg_get(psoc, CFG_DP_MLO_RX_RING_MAP); 2713 wlan_cfg_ctx->mlo_chip_rx_ring_map = rx_ring_map; 2714 } 2715 #else 2716 static inline void 2717 wlan_multi_soc_mlo_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2718 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2719 { 2720 } 2721 #endif 2722 2723 #ifdef WLAN_FEATURE_11BE_MLO 2724 /** 2725 * wlan_soc_mlo_cfg_attach() - Update mlo config in dp soc 2726 * cfg context 2727 * @psoc: Object manager psoc 2728 * @wlan_cfg_ctx: dp soc cfg ctx 2729 * 2730 * Return: None 2731 */ 2732 static void 2733 wlan_soc_mlo_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2734 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2735 { 2736 wlan_multi_soc_mlo_cfg_attach(psoc, wlan_cfg_ctx); 2737 } 2738 #else 2739 static inline void 2740 wlan_soc_mlo_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2741 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2742 { 2743 } 2744 #endif 2745 2746 #ifdef QCA_VDEV_STATS_HW_OFFLOAD_SUPPORT 2747 /** 2748 * wlan_soc_vdev_hw_stats_cfg_attach() - Update hw vdev stats config in dp soc 2749 * cfg context 2750 * @psoc: Object manager psoc 2751 * @wlan_cfg_ctx: dp soc cfg ctx 2752 * 2753 * Return: None 2754 */ 2755 static void 2756 wlan_soc_vdev_hw_stats_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2757 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2758 { 2759 wlan_cfg_ctx->vdev_stats_hw_offload_config = cfg_get(psoc, 2760 CFG_DP_VDEV_STATS_HW_OFFLOAD_CONFIG); 2761 wlan_cfg_ctx->vdev_stats_hw_offload_timer = cfg_get(psoc, 2762 CFG_DP_VDEV_STATS_HW_OFFLOAD_TIMER); 2763 } 2764 #else 2765 static void 2766 wlan_soc_vdev_hw_stats_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2767 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2768 { 2769 } 2770 #endif 2771 2772 #ifdef WLAN_TX_PKT_CAPTURE_ENH 2773 static void wlan_soc_tx_capt_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2774 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2775 { 2776 wlan_cfg_ctx->tx_capt_max_mem_allowed = 2777 cfg_get(psoc, CFG_DP_TX_CAPT_MAX_MEM_MB) * 1024 * 1024; 2778 } 2779 #else 2780 static void wlan_soc_tx_capt_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2781 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2782 { 2783 } 2784 #endif 2785 2786 void 2787 wlan_cfg_soc_update_tgt_params(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx, 2788 struct cdp_ctrl_objmgr_psoc *psoc) 2789 { 2790 wlan_cfg_ctx->reo_rings_mapping = cfg_get(psoc, 2791 CFG_DP_REO_RINGS_MAP); 2792 } 2793 2794 #ifdef CONFIG_SAWF_STATS 2795 /** 2796 * wlan_soc_sawf_stats_cfg_attach() - Update sawf stats config in dp soc 2797 * cfg context 2798 * @psoc: Object manager psoc 2799 * @wlan_cfg_ctx: dp soc cfg ctx 2800 * 2801 * Return: None 2802 */ 2803 static void 2804 wlan_soc_sawf_stats_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2805 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2806 { 2807 wlan_cfg_ctx->sawf_stats = cfg_get(psoc, CFG_DP_SAWF_STATS); 2808 } 2809 2810 uint8_t wlan_cfg_get_sawf_stats_config(struct wlan_cfg_dp_soc_ctxt *cfg) 2811 { 2812 return cfg->sawf_stats; 2813 } 2814 2815 void wlan_cfg_set_sawf_stats_config(struct wlan_cfg_dp_soc_ctxt *cfg, 2816 uint8_t val) 2817 { 2818 cfg->sawf_stats = val; 2819 } 2820 #else 2821 static void 2822 wlan_soc_sawf_stats_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2823 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2824 { 2825 } 2826 2827 uint8_t wlan_cfg_get_sawf_stats_config(struct wlan_cfg_dp_soc_ctxt *cfg) 2828 { 2829 return 0; 2830 } 2831 2832 void wlan_cfg_set_sawf_stats_config(struct wlan_cfg_dp_soc_ctxt *cfg, 2833 uint8_t val) 2834 { 2835 } 2836 #endif /* CONFIG_SAWF_STATS */ 2837 2838 #ifdef DP_TX_PACKET_INSPECT_FOR_ILP 2839 /** 2840 * wlan_soc_tx_packet_inspect_attach() - Update TX packet inspection config 2841 * @psoc: object manager psoc 2842 * @wlan_cfg_ctx: dp soc cfg ctx 2843 * 2844 * Return: None 2845 */ 2846 static void 2847 wlan_soc_tx_packet_inspect_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2848 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2849 { 2850 wlan_cfg_ctx->tx_pkt_inspect_for_ilp = 2851 cfg_get(psoc, CFG_TX_PKT_INSPECT_FOR_ILP); 2852 } 2853 #else 2854 static void 2855 wlan_soc_tx_packet_inspect_attach(struct cdp_ctrl_objmgr_psoc *psoc, 2856 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 2857 { 2858 } 2859 #endif 2860 2861 struct wlan_cfg_dp_soc_ctxt * 2862 wlan_cfg_soc_attach(struct cdp_ctrl_objmgr_psoc *psoc) 2863 { 2864 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx = 2865 qdf_mem_malloc(sizeof(struct wlan_cfg_dp_soc_ctxt)); 2866 uint32_t gro_bit_set; 2867 2868 if (!wlan_cfg_ctx) 2869 return NULL; 2870 2871 wlan_cfg_ctx->rxdma1_enable = WLAN_CFG_RXDMA1_ENABLE; 2872 wlan_cfg_ctx->num_int_ctxts = WLAN_CFG_INT_NUM_CONTEXTS; 2873 wlan_cfg_ctx->max_clients = cfg_get(psoc, CFG_DP_MAX_CLIENTS); 2874 wlan_cfg_ctx->max_alloc_size = cfg_get(psoc, CFG_DP_MAX_ALLOC_SIZE); 2875 wlan_cfg_ctx->per_pdev_tx_ring = cfg_get(psoc, CFG_DP_PDEV_TX_RING); 2876 wlan_cfg_ctx->num_reo_dest_rings = cfg_get(psoc, CFG_DP_REO_DEST_RINGS); 2877 wlan_cfg_ctx->num_tcl_data_rings = cfg_get(psoc, CFG_DP_TCL_DATA_RINGS); 2878 wlan_cfg_ctx->num_tx_comp_rings = cfg_get(psoc, CFG_DP_TX_COMP_RINGS); 2879 wlan_cfg_ctx->num_nss_reo_dest_rings = 2880 cfg_get(psoc, CFG_DP_NSS_REO_DEST_RINGS); 2881 wlan_cfg_ctx->num_nss_tcl_data_rings = 2882 cfg_get(psoc, CFG_DP_NSS_TCL_DATA_RINGS); 2883 wlan_cfg_ctx->per_pdev_rx_ring = cfg_get(psoc, CFG_DP_PDEV_RX_RING); 2884 wlan_cfg_ctx->per_pdev_lmac_ring = cfg_get(psoc, CFG_DP_PDEV_LMAC_RING); 2885 wlan_cfg_ctx->num_tx_desc_pool = MAX_TXDESC_POOLS; 2886 wlan_cfg_ctx->num_tx_ext_desc_pool = cfg_get(psoc, 2887 CFG_DP_TX_EXT_DESC_POOLS); 2888 wlan_cfg_ctx->num_tx_desc = cfg_get(psoc, CFG_DP_TX_DESC); 2889 wlan_cfg_ctx->num_tx_spl_desc = cfg_get(psoc, CFG_DP_TX_SPL_DESC); 2890 wlan_cfg_ctx->min_tx_desc = WLAN_CFG_NUM_TX_DESC_MIN; 2891 wlan_cfg_ctx->num_tx_ext_desc = cfg_get(psoc, CFG_DP_TX_EXT_DESC); 2892 wlan_cfg_ctx->htt_packet_type = cfg_get(psoc, CFG_DP_HTT_PACKET_TYPE); 2893 wlan_cfg_ctx->max_peer_id = cfg_get(psoc, CFG_DP_MAX_PEER_ID); 2894 2895 wlan_cfg_ctx->tx_ring_size = cfg_get(psoc, CFG_DP_TX_RING_SIZE); 2896 wlan_cfg_ctx->time_control_bp = cfg_get(psoc, CFG_DP_TIME_CONTROL_BP); 2897 wlan_cfg_ctx->tx_comp_ring_size = cfg_get(psoc, 2898 CFG_DP_TX_COMPL_RING_SIZE); 2899 2900 wlan_cfg_ctx->tx_comp_ring_size_nss = 2901 cfg_get(psoc, CFG_DP_NSS_COMP_RING_SIZE); 2902 2903 wlan_cfg_ctx->int_batch_threshold_tx = 2904 cfg_get(psoc, CFG_DP_INT_BATCH_THRESHOLD_TX); 2905 wlan_cfg_ctx->int_timer_threshold_tx = 2906 cfg_get(psoc, CFG_DP_INT_TIMER_THRESHOLD_TX); 2907 wlan_cfg_ctx->int_batch_threshold_rx = 2908 cfg_get(psoc, CFG_DP_INT_BATCH_THRESHOLD_RX); 2909 wlan_cfg_ctx->int_timer_threshold_rx = 2910 cfg_get(psoc, CFG_DP_INT_TIMER_THRESHOLD_RX); 2911 wlan_cfg_ctx->int_batch_threshold_other = 2912 cfg_get(psoc, CFG_DP_INT_BATCH_THRESHOLD_OTHER); 2913 wlan_cfg_ctx->int_timer_threshold_other = 2914 cfg_get(psoc, CFG_DP_INT_TIMER_THRESHOLD_OTHER); 2915 wlan_cfg_ctx->int_batch_threshold_ppe2tcl = 2916 cfg_get(psoc, CFG_DP_INT_BATCH_THRESHOLD_PPE2TCL); 2917 wlan_cfg_ctx->int_timer_threshold_ppe2tcl = 2918 cfg_get(psoc, CFG_DP_INT_TIMER_THRESHOLD_PPE2TCL); 2919 2920 wlan_cfg_ctx->pktlog_buffer_size = 2921 cfg_get(psoc, CFG_DP_PKTLOG_BUFFER_SIZE); 2922 2923 /* This is default mapping and can be overridden by HW config 2924 * received from FW */ 2925 wlan_cfg_set_hw_mac_idx(wlan_cfg_ctx, 0, 0); 2926 if (MAX_PDEV_CNT > 1) 2927 wlan_cfg_set_hw_mac_idx(wlan_cfg_ctx, 1, 2); 2928 if (MAX_PDEV_CNT > 2) 2929 wlan_cfg_set_hw_mac_idx(wlan_cfg_ctx, 2, 1); 2930 2931 wlan_cfg_ctx->base_hw_macid = cfg_get(psoc, CFG_DP_BASE_HW_MAC_ID); 2932 2933 wlan_cfg_ctx->rx_hash = cfg_get(psoc, CFG_DP_RX_HASH); 2934 wlan_cfg_ctx->tso_enabled = cfg_get(psoc, CFG_DP_TSO); 2935 wlan_cfg_ctx->lro_enabled = cfg_get(psoc, CFG_DP_LRO); 2936 wlan_cfg_ctx->sg_enabled = cfg_get(psoc, CFG_DP_SG); 2937 gro_bit_set = cfg_get(psoc, CFG_DP_GRO); 2938 if (gro_bit_set & DP_GRO_ENABLE_BIT_SET) { 2939 wlan_cfg_ctx->gro_enabled = true; 2940 if (gro_bit_set & DP_TC_BASED_DYNAMIC_GRO) 2941 wlan_cfg_ctx->tc_based_dynamic_gro = true; 2942 } 2943 wlan_cfg_ctx->tc_ingress_prio = cfg_get(psoc, CFG_DP_TC_INGRESS_PRIO); 2944 wlan_cfg_ctx->ol_tx_csum_enabled = cfg_get(psoc, CFG_DP_OL_TX_CSUM); 2945 wlan_cfg_ctx->ol_rx_csum_enabled = cfg_get(psoc, CFG_DP_OL_RX_CSUM); 2946 wlan_cfg_ctx->rawmode_enabled = cfg_get(psoc, CFG_DP_RAWMODE); 2947 wlan_cfg_ctx->peer_flow_ctrl_enabled = 2948 cfg_get(psoc, CFG_DP_PEER_FLOW_CTRL); 2949 wlan_cfg_ctx->napi_enabled = cfg_get(psoc, CFG_DP_NAPI); 2950 wlan_cfg_ctx->p2p_tcp_udp_checksumoffload = 2951 cfg_get(psoc, CFG_DP_P2P_TCP_UDP_CKSUM_OFFLOAD); 2952 wlan_cfg_ctx->nan_tcp_udp_checksumoffload = 2953 cfg_get(psoc, CFG_DP_NAN_TCP_UDP_CKSUM_OFFLOAD); 2954 wlan_cfg_ctx->tcp_udp_checksumoffload = 2955 cfg_get(psoc, CFG_DP_TCP_UDP_CKSUM_OFFLOAD); 2956 wlan_cfg_ctx->legacy_mode_checksumoffload_disable = 2957 cfg_get(psoc, CFG_DP_LEGACY_MODE_CSUM_DISABLE); 2958 wlan_cfg_ctx->per_pkt_trace = cfg_get(psoc, CFG_DP_PER_PKT_LOGGING); 2959 wlan_cfg_ctx->defrag_timeout_check = 2960 cfg_get(psoc, CFG_DP_DEFRAG_TIMEOUT_CHECK); 2961 wlan_cfg_ctx->rx_defrag_min_timeout = 2962 cfg_get(psoc, CFG_DP_RX_DEFRAG_TIMEOUT); 2963 2964 wlan_cfg_ctx->wbm_release_ring = cfg_get(psoc, 2965 CFG_DP_WBM_RELEASE_RING); 2966 wlan_cfg_ctx->tcl_cmd_credit_ring = cfg_get(psoc, 2967 CFG_DP_TCL_CMD_CREDIT_RING); 2968 wlan_cfg_ctx->tcl_status_ring = cfg_get(psoc, 2969 CFG_DP_TCL_STATUS_RING); 2970 wlan_cfg_ctx->reo_dst_ring_size = cfg_get(psoc, 2971 CFG_DP_RX_DESTINATION_RING); 2972 wlan_cfg_ctx->reo_reinject_ring = cfg_get(psoc, 2973 CFG_DP_REO_REINJECT_RING); 2974 wlan_cfg_ctx->rx_release_ring = cfg_get(psoc, 2975 CFG_DP_RX_RELEASE_RING); 2976 wlan_cfg_ctx->reo_exception_ring = cfg_get(psoc, 2977 CFG_DP_REO_EXCEPTION_RING); 2978 wlan_cfg_ctx->reo_cmd_ring = cfg_get(psoc, 2979 CFG_DP_REO_CMD_RING); 2980 wlan_cfg_ctx->reo_status_ring = cfg_get(psoc, 2981 CFG_DP_REO_STATUS_RING); 2982 wlan_cfg_ctx->rxdma_refill_ring = cfg_get(psoc, 2983 CFG_DP_RXDMA_REFILL_RING); 2984 wlan_cfg_ctx->rxdma_refill_lt_disable = 2985 cfg_get(psoc, 2986 CFG_DP_RXDMA_REFILL_LT_DISABLE); 2987 wlan_cfg_ctx->tx_desc_limit_0 = cfg_get(psoc, 2988 CFG_DP_TX_DESC_LIMIT_0); 2989 wlan_cfg_ctx->tx_desc_limit_1 = cfg_get(psoc, 2990 CFG_DP_TX_DESC_LIMIT_1); 2991 wlan_cfg_ctx->tx_desc_limit_2 = cfg_get(psoc, 2992 CFG_DP_TX_DESC_LIMIT_2); 2993 wlan_cfg_ctx->tx_device_limit = cfg_get(psoc, 2994 CFG_DP_TX_DEVICE_LIMIT); 2995 wlan_cfg_ctx->tx_spl_device_limit = cfg_get(psoc, 2996 CFG_DP_TX_SPL_DEVICE_LIMIT); 2997 wlan_cfg_ctx->tx_sw_internode_queue = cfg_get(psoc, 2998 CFG_DP_TX_SW_INTERNODE_QUEUE); 2999 wlan_cfg_ctx->rxdma_err_dst_ring = cfg_get(psoc, 3000 CFG_DP_RXDMA_ERR_DST_RING); 3001 wlan_cfg_ctx->enable_data_stall_detection = 3002 cfg_get(psoc, CFG_DP_ENABLE_DATA_STALL_DETECTION); 3003 wlan_cfg_ctx->tx_flow_start_queue_offset = 3004 cfg_get(psoc, CFG_DP_TX_FLOW_START_QUEUE_OFFSET); 3005 wlan_cfg_ctx->tx_flow_stop_queue_threshold = 3006 cfg_get(psoc, CFG_DP_TX_FLOW_STOP_QUEUE_TH); 3007 wlan_cfg_ctx->disable_intra_bss_fwd = 3008 cfg_get(psoc, CFG_DP_AP_STA_SECURITY_SEPERATION); 3009 wlan_cfg_ctx->rx_sw_desc_weight = cfg_get(psoc, 3010 CFG_DP_RX_SW_DESC_WEIGHT); 3011 wlan_cfg_ctx->rx_sw_desc_num = cfg_get(psoc, 3012 CFG_DP_RX_SW_DESC_NUM); 3013 wlan_cfg_ctx->rx_toeplitz_hash_key = (uint8_t *)rx_fst_toeplitz_key; 3014 wlan_cfg_ctx->rx_flow_max_search = WLAN_CFG_RX_FST_MAX_SEARCH; 3015 wlan_cfg_ctx->is_rx_flow_tag_enabled = 3016 cfg_get(psoc, CFG_DP_RX_FLOW_TAG_ENABLE); 3017 wlan_cfg_ctx->is_rx_flow_search_table_per_pdev = 3018 cfg_get(psoc, CFG_DP_RX_FLOW_SEARCH_TABLE_PER_PDEV); 3019 wlan_cfg_ctx->rx_flow_search_table_size = 3020 cfg_get(psoc, CFG_DP_RX_FLOW_SEARCH_TABLE_SIZE); 3021 wlan_cfg_ctx->is_rx_mon_protocol_flow_tag_enabled = 3022 cfg_get(psoc, CFG_DP_RX_MON_PROTOCOL_FLOW_TAG_ENABLE); 3023 wlan_cfg_ctx->mon_drop_thresh = 3024 cfg_get(psoc, CFG_DP_RXDMA_MONITOR_RX_DROP_THRESHOLD); 3025 wlan_cfg_ctx->is_rx_fisa_enabled = cfg_get(psoc, CFG_DP_RX_FISA_ENABLE); 3026 wlan_cfg_ctx->is_rx_fisa_lru_del_enabled = 3027 cfg_get(psoc, CFG_DP_RX_FISA_LRU_DEL_ENABLE); 3028 wlan_cfg_ctx->reo_rings_mapping = cfg_get(psoc, CFG_DP_REO_RINGS_MAP); 3029 wlan_cfg_ctx->pext_stats_enabled = cfg_get(psoc, CFG_DP_PEER_EXT_STATS); 3030 wlan_cfg_ctx->jitter_stats_enabled = 3031 cfg_get(psoc, CFG_DP_PEER_JITTER_STATS); 3032 wlan_cfg_ctx->is_rx_buff_pool_enabled = 3033 cfg_get(psoc, CFG_DP_RX_BUFF_POOL_ENABLE); 3034 wlan_cfg_ctx->is_rx_refill_buff_pool_enabled = 3035 cfg_get(psoc, CFG_DP_RX_REFILL_BUFF_POOL_ENABLE); 3036 wlan_cfg_ctx->rx_pending_high_threshold = 3037 cfg_get(psoc, CFG_DP_RX_PENDING_HL_THRESHOLD); 3038 wlan_cfg_ctx->rx_pending_low_threshold = 3039 cfg_get(psoc, CFG_DP_RX_PENDING_LO_THRESHOLD); 3040 wlan_cfg_ctx->is_poll_mode_enabled = 3041 cfg_get(psoc, CFG_DP_POLL_MODE_ENABLE); 3042 wlan_cfg_ctx->is_swlm_enabled = cfg_get(psoc, CFG_DP_SWLM_ENABLE); 3043 wlan_cfg_ctx->fst_in_cmem = cfg_get(psoc, CFG_DP_RX_FST_IN_CMEM); 3044 wlan_cfg_ctx->tx_per_pkt_vdev_id_check = 3045 cfg_get(psoc, CFG_DP_TX_PER_PKT_VDEV_ID_CHECK); 3046 wlan_cfg_ctx->radio0_rx_default_reo = 3047 cfg_get(psoc, CFG_DP_RX_RADIO_0_DEFAULT_REO); 3048 wlan_cfg_ctx->radio1_rx_default_reo = 3049 cfg_get(psoc, CFG_DP_RX_RADIO_1_DEFAULT_REO); 3050 wlan_cfg_ctx->radio2_rx_default_reo = 3051 cfg_get(psoc, CFG_DP_RX_RADIO_2_DEFAULT_REO); 3052 wlan_cfg_ctx->wow_check_rx_pending_enable = 3053 cfg_get(psoc, CFG_DP_WOW_CHECK_RX_PENDING); 3054 wlan_cfg_ctx->delay_mon_replenish = cfg_get(psoc, 3055 CFG_DP_DELAY_MON_REPLENISH); 3056 wlan_cfg_ctx->num_global_tx_desc = cfg_get(psoc, 3057 CFG_DP_TX_DESC_GLOBAL_COUNT); 3058 wlan_cfg_ctx->num_global_spcl_tx_desc = cfg_get(psoc, 3059 CFG_DP_SPCL_TX_DESC_GLOBAL_COUNT); 3060 wlan_cfg_ctx->rx_mon_buf_ring_size = cfg_get(psoc, 3061 CFG_DP_RXDMA_MONITOR_BUF_RING); 3062 wlan_cfg_ctx->tx_mon_buf_ring_size = cfg_get(psoc, 3063 CFG_DP_TX_MONITOR_BUF_RING); 3064 wlan_soc_ipa_cfg_attach(psoc, wlan_cfg_ctx); 3065 wlan_soc_hw_cc_cfg_attach(psoc, wlan_cfg_ctx); 3066 wlan_soc_ppe_cfg_attach(psoc, wlan_cfg_ctx); 3067 wlan_soc_mlo_cfg_attach(psoc, wlan_cfg_ctx); 3068 wlan_soc_vdev_hw_stats_cfg_attach(psoc, wlan_cfg_ctx); 3069 #ifdef WLAN_FEATURE_PKT_CAPTURE_V2 3070 wlan_cfg_ctx->pkt_capture_mode = cfg_get(psoc, CFG_PKT_CAPTURE_MODE) & 3071 PKT_CAPTURE_MODE_DATA_ONLY; 3072 #endif 3073 wlan_cfg_ctx->num_rxdma_dst_rings_per_pdev = NUM_RXDMA_RINGS_PER_PDEV; 3074 wlan_cfg_ctx->num_rxdma_status_rings_per_pdev = 3075 NUM_RXDMA_RINGS_PER_PDEV; 3076 wlan_soc_tx_capt_cfg_attach(psoc, wlan_cfg_ctx); 3077 wlan_cfg_ctx->mpdu_retry_threshold_1 = 3078 cfg_get(psoc, CFG_DP_MPDU_RETRY_THRESHOLD_1); 3079 wlan_cfg_ctx->mpdu_retry_threshold_2 = 3080 cfg_get(psoc, CFG_DP_MPDU_RETRY_THRESHOLD_2); 3081 3082 wlan_cfg_ctx->napi_scale_factor = cfg_get(psoc, 3083 CFG_DP_NAPI_SCALE_FACTOR); 3084 wlan_soc_sawf_stats_cfg_attach(psoc, wlan_cfg_ctx); 3085 wlan_cfg_ctx->is_handle_invalid_decap_type_disabled = 3086 cfg_get(psoc, CFG_DP_HANDLE_INVALID_DECAP_TYPE_DISABLE); 3087 wlan_cfg_ctx->txmon_sw_peer_filtering = 3088 cfg_get(psoc, CFG_DP_TXMON_SW_PEER_FILTERING); 3089 wlan_soc_tx_packet_inspect_attach(psoc, wlan_cfg_ctx); 3090 3091 return wlan_cfg_ctx; 3092 } 3093 3094 void wlan_cfg_soc_detach(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 3095 { 3096 qdf_mem_free(wlan_cfg_ctx); 3097 } 3098 3099 struct wlan_cfg_dp_pdev_ctxt * 3100 wlan_cfg_pdev_attach(struct cdp_ctrl_objmgr_psoc *psoc) 3101 { 3102 struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_ctx = 3103 qdf_mem_malloc(sizeof(struct wlan_cfg_dp_pdev_ctxt)); 3104 3105 if (!wlan_cfg_ctx) 3106 return NULL; 3107 3108 wlan_cfg_ctx->rx_dma_buf_ring_size = cfg_get(psoc, 3109 CFG_DP_RXDMA_BUF_RING); 3110 wlan_cfg_ctx->dma_mon_buf_ring_size = cfg_get(psoc, 3111 CFG_DP_RXDMA_MONITOR_BUF_RING); 3112 wlan_cfg_ctx->dma_rx_mon_dest_ring_size = cfg_get(psoc, 3113 CFG_DP_RXDMA_MONITOR_DST_RING); 3114 wlan_cfg_ctx->dma_tx_mon_dest_ring_size = cfg_get(psoc, 3115 CFG_DP_TX_MONITOR_DST_RING); 3116 wlan_cfg_ctx->dma_mon_status_ring_size = cfg_get(psoc, 3117 CFG_DP_RXDMA_MONITOR_STATUS_RING); 3118 wlan_cfg_ctx->rxdma_monitor_desc_ring = cfg_get(psoc, 3119 CFG_DP_RXDMA_MONITOR_DESC_RING); 3120 wlan_cfg_ctx->num_mac_rings = NUM_RXDMA_RINGS_PER_PDEV; 3121 3122 return wlan_cfg_ctx; 3123 } 3124 3125 void wlan_cfg_set_mon_delayed_replenish_entries( 3126 struct wlan_cfg_dp_soc_ctxt *cfg, 3127 uint32_t val) 3128 { 3129 cfg->delayed_replenish_entries = val; 3130 } 3131 3132 qdf_export_symbol(wlan_cfg_set_mon_delayed_replenish_entries); 3133 3134 int wlan_cfg_get_mon_delayed_replenish_entries(struct wlan_cfg_dp_soc_ctxt *cfg) 3135 { 3136 return cfg->delayed_replenish_entries; 3137 } 3138 3139 void wlan_cfg_pdev_detach(struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_ctx) 3140 { 3141 if (wlan_cfg_ctx) 3142 qdf_mem_free(wlan_cfg_ctx); 3143 } 3144 3145 int wlan_cfg_get_mon_drop_thresh(struct wlan_cfg_dp_soc_ctxt *cfg) 3146 { 3147 return cfg->mon_drop_thresh; 3148 } 3149 3150 void wlan_cfg_set_num_contexts(struct wlan_cfg_dp_soc_ctxt *cfg, int num) 3151 { 3152 cfg->num_int_ctxts = num; 3153 } 3154 3155 void wlan_cfg_set_max_peer_id(struct wlan_cfg_dp_soc_ctxt *cfg, uint32_t val) 3156 { 3157 cfg->max_peer_id = val; 3158 } 3159 3160 void wlan_cfg_set_max_ast_idx(struct wlan_cfg_dp_soc_ctxt *cfg, uint32_t val) 3161 { 3162 cfg->max_ast_idx = val; 3163 } 3164 3165 int wlan_cfg_get_max_ast_idx(struct wlan_cfg_dp_soc_ctxt *cfg) 3166 { 3167 return cfg->max_ast_idx; 3168 } 3169 3170 qdf_export_symbol(wlan_cfg_get_max_ast_idx); 3171 3172 void wlan_cfg_set_tx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3173 int context, int mask) 3174 { 3175 cfg->int_tx_ring_mask[context] = mask; 3176 } 3177 3178 void wlan_cfg_set_rx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3179 int context, int mask) 3180 { 3181 cfg->int_rx_ring_mask[context] = mask; 3182 } 3183 3184 void wlan_cfg_set_rx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3185 int context, int mask) 3186 { 3187 cfg->int_rx_mon_ring_mask[context] = mask; 3188 } 3189 3190 void wlan_cfg_set_tx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3191 int context, int mask) 3192 { 3193 cfg->int_tx_mon_ring_mask[context] = mask; 3194 } 3195 3196 int wlan_cfg_get_host2rxdma_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3197 int context) 3198 { 3199 return cfg->int_host2rxdma_mon_ring_mask[context]; 3200 } 3201 3202 void wlan_cfg_set_host2rxdma_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3203 int context, int mask) 3204 { 3205 cfg->int_host2rxdma_mon_ring_mask[context] = mask; 3206 } 3207 3208 int wlan_cfg_get_rxdma2host_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3209 int context) 3210 { 3211 return cfg->int_rxdma2host_mon_ring_mask[context]; 3212 } 3213 3214 void wlan_cfg_set_rxdma2host_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3215 int context, int mask) 3216 { 3217 cfg->int_rxdma2host_mon_ring_mask[context] = mask; 3218 } 3219 3220 void wlan_cfg_set_rxdma2host_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3221 int context, int mask) 3222 { 3223 cfg->int_rxdma2host_ring_mask[context] = mask; 3224 } 3225 3226 int wlan_cfg_get_rxdma2host_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3227 int context) 3228 { 3229 return cfg->int_rxdma2host_ring_mask[context]; 3230 } 3231 3232 void wlan_cfg_set_host2rxdma_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3233 int context, int mask) 3234 { 3235 cfg->int_host2rxdma_ring_mask[context] = mask; 3236 } 3237 3238 int wlan_cfg_get_host2rxdma_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3239 int context) 3240 { 3241 return cfg->int_host2rxdma_ring_mask[context]; 3242 } 3243 3244 int wlan_cfg_get_rx_near_full_grp_1_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3245 int context) 3246 { 3247 return cfg->int_rx_ring_near_full_irq_1_mask[context]; 3248 } 3249 3250 int wlan_cfg_get_rx_near_full_grp_2_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3251 int context) 3252 { 3253 return cfg->int_rx_ring_near_full_irq_2_mask[context]; 3254 } 3255 3256 int wlan_cfg_get_tx_ring_near_full_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3257 int context) 3258 { 3259 return cfg->int_tx_ring_near_full_irq_mask[context]; 3260 } 3261 3262 void wlan_cfg_set_hw_mac_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx, 3263 int hw_macid) 3264 { 3265 qdf_assert_always(pdev_idx < MAX_PDEV_CNT); 3266 cfg->hw_macid[pdev_idx] = hw_macid; 3267 } 3268 3269 int wlan_cfg_get_hw_mac_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx) 3270 { 3271 qdf_assert_always(pdev_idx < MAX_PDEV_CNT); 3272 return cfg->hw_macid[pdev_idx]; 3273 } 3274 3275 qdf_export_symbol(wlan_cfg_get_hw_mac_idx); 3276 3277 int wlan_cfg_get_target_pdev_id(struct wlan_cfg_dp_soc_ctxt *cfg, 3278 int hw_macid) 3279 { 3280 int idx; 3281 3282 for (idx = 0; idx < MAX_PDEV_CNT; idx++) { 3283 if (cfg->hw_macid[idx] == hw_macid) 3284 return (idx + 1); 3285 } 3286 qdf_assert_always(idx < MAX_PDEV_CNT); 3287 return WLAN_INVALID_PDEV_ID; 3288 } 3289 3290 void wlan_cfg_set_pdev_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx, 3291 int hw_macid) 3292 { 3293 qdf_assert_always((pdev_idx < MAX_PDEV_CNT) || 3294 (pdev_idx == INVALID_PDEV_ID)); 3295 qdf_assert_always(hw_macid < MAX_NUM_LMAC_HW); 3296 cfg->hw_macid_pdev_id_map[hw_macid] = pdev_idx; 3297 } 3298 3299 int wlan_cfg_get_pdev_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int hw_macid) 3300 { 3301 qdf_assert_always(hw_macid < MAX_NUM_LMAC_HW); 3302 return cfg->hw_macid_pdev_id_map[hw_macid]; 3303 } 3304 3305 qdf_export_symbol(wlan_cfg_get_pdev_idx); 3306 3307 void wlan_cfg_set_ce_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3308 int context, int mask) 3309 { 3310 cfg->int_ce_ring_mask[context] = mask; 3311 } 3312 3313 void wlan_cfg_set_rxbuf_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context, 3314 int mask) 3315 { 3316 cfg->int_rx_ring_mask[context] = mask; 3317 } 3318 3319 int wlan_cfg_set_rx_err_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3320 int context, int mask) 3321 { 3322 return cfg->int_rx_err_ring_mask[context] = mask; 3323 } 3324 3325 int wlan_cfg_set_rx_wbm_rel_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3326 int context, int mask) 3327 { 3328 return cfg->int_rx_wbm_rel_ring_mask[context] = mask; 3329 } 3330 3331 int wlan_cfg_set_reo_status_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3332 int context, int mask) 3333 { 3334 return cfg->int_reo_status_ring_mask[context] = mask; 3335 } 3336 3337 int wlan_cfg_get_num_contexts(struct wlan_cfg_dp_soc_ctxt *cfg) 3338 { 3339 return cfg->num_int_ctxts; 3340 } 3341 3342 int wlan_cfg_get_tx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3343 { 3344 return cfg->int_tx_ring_mask[context]; 3345 } 3346 3347 int wlan_cfg_get_rx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3348 { 3349 return cfg->int_rx_ring_mask[context]; 3350 } 3351 3352 int wlan_cfg_get_rx_err_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3353 int context) 3354 { 3355 return cfg->int_rx_err_ring_mask[context]; 3356 } 3357 3358 int wlan_cfg_get_rx_wbm_rel_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3359 int context) 3360 { 3361 return cfg->int_rx_wbm_rel_ring_mask[context]; 3362 } 3363 3364 int wlan_cfg_get_reo_status_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3365 int context) 3366 { 3367 return cfg->int_reo_status_ring_mask[context]; 3368 } 3369 3370 int wlan_cfg_get_rx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3371 { 3372 return cfg->int_rx_mon_ring_mask[context]; 3373 } 3374 3375 #ifdef CONFIG_BERYLLIUM 3376 int wlan_cfg_get_tx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3377 { 3378 return cfg->int_tx_mon_ring_mask[context]; 3379 } 3380 #else 3381 int wlan_cfg_get_tx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3382 { 3383 return 0; 3384 } 3385 #endif 3386 3387 int wlan_cfg_get_ce_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3388 { 3389 return cfg->int_ce_ring_mask[context]; 3390 } 3391 3392 uint32_t wlan_cfg_get_max_clients(struct wlan_cfg_dp_soc_ctxt *cfg) 3393 { 3394 return cfg->max_clients; 3395 } 3396 3397 uint32_t wlan_cfg_max_alloc_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3398 { 3399 return cfg->max_alloc_size; 3400 } 3401 3402 int wlan_cfg_per_pdev_tx_ring(struct wlan_cfg_dp_soc_ctxt *cfg) 3403 { 3404 return cfg->per_pdev_tx_ring; 3405 } 3406 3407 int wlan_cfg_get_umac_reset_intr_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3408 int context) 3409 { 3410 return cfg->int_umac_reset_intr_mask[context]; 3411 } 3412 3413 uint32_t 3414 wlan_cfg_rx_pending_hl_threshold(struct wlan_cfg_dp_soc_ctxt *cfg) 3415 { 3416 return cfg->rx_pending_high_threshold; 3417 } 3418 3419 uint32_t 3420 wlan_cfg_rx_pending_lo_threshold(struct wlan_cfg_dp_soc_ctxt *cfg) 3421 { 3422 return cfg->rx_pending_low_threshold; 3423 } 3424 3425 int wlan_cfg_per_pdev_lmac_ring(struct wlan_cfg_dp_soc_ctxt *cfg) 3426 { 3427 return cfg->per_pdev_lmac_ring; 3428 } 3429 3430 qdf_export_symbol(wlan_cfg_per_pdev_lmac_ring); 3431 3432 #if defined(DP_USE_SINGLE_TCL) && !defined(TX_MULTI_TCL) 3433 int wlan_cfg_num_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3434 { 3435 return 1; 3436 } 3437 3438 int wlan_cfg_num_nss_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3439 { 3440 return 1; 3441 } 3442 3443 #else 3444 3445 #if defined(IPA_OFFLOAD) && defined(TX_MULTI_TCL) 3446 int wlan_cfg_num_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3447 { 3448 if (!cfg->ipa_enabled) 3449 return cfg->num_tcl_data_rings; 3450 3451 return 1; 3452 } 3453 3454 int wlan_cfg_num_nss_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3455 { 3456 if (!cfg->ipa_enabled) 3457 return cfg->num_nss_tcl_data_rings; 3458 3459 return 1; 3460 } 3461 #else 3462 int wlan_cfg_num_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3463 { 3464 return cfg->num_tcl_data_rings; 3465 } 3466 3467 int wlan_cfg_num_nss_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3468 { 3469 return cfg->num_nss_tcl_data_rings; 3470 } 3471 #endif 3472 #endif 3473 3474 int wlan_cfg_num_tx_comp_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3475 { 3476 return cfg->num_tx_comp_rings; 3477 } 3478 3479 int wlan_cfg_tx_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3480 { 3481 return cfg->tx_ring_size; 3482 } 3483 3484 int wlan_cfg_time_control_bp(struct wlan_cfg_dp_soc_ctxt *cfg) 3485 { 3486 return cfg->time_control_bp; 3487 } 3488 3489 int wlan_cfg_tx_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3490 { 3491 return cfg->tx_comp_ring_size; 3492 } 3493 3494 int wlan_cfg_per_pdev_rx_ring(struct wlan_cfg_dp_soc_ctxt *cfg) 3495 { 3496 return cfg->per_pdev_rx_ring; 3497 } 3498 3499 int wlan_cfg_num_reo_dest_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3500 { 3501 return cfg->num_reo_dest_rings; 3502 } 3503 3504 int wlan_cfg_num_nss_reo_dest_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3505 { 3506 return cfg->num_nss_reo_dest_rings; 3507 } 3508 3509 int wlan_cfg_pkt_type(struct wlan_cfg_dp_soc_ctxt *cfg) 3510 { 3511 return cfg->htt_packet_type; /*htt_pkt_type_ethernet*/ 3512 } 3513 3514 int wlan_cfg_get_num_tx_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg) 3515 { 3516 return cfg->num_tx_desc_pool; 3517 } 3518 3519 void wlan_cfg_set_num_tx_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg, int num_pool) 3520 { 3521 cfg->num_tx_desc_pool = num_pool; 3522 } 3523 3524 int wlan_cfg_get_num_tx_ext_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg) 3525 { 3526 return cfg->num_tx_ext_desc_pool; 3527 } 3528 3529 void wlan_cfg_set_num_tx_ext_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg, int num_pool) 3530 { 3531 cfg->num_tx_ext_desc_pool = num_pool; 3532 } 3533 3534 int wlan_cfg_get_reo_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3535 { 3536 return cfg->reo_dst_ring_size; 3537 } 3538 3539 void wlan_cfg_set_reo_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg, 3540 int reo_dst_ring_size) 3541 { 3542 cfg->reo_dst_ring_size = reo_dst_ring_size; 3543 } 3544 3545 void wlan_cfg_set_raw_mode_war(struct wlan_cfg_dp_soc_ctxt *cfg, 3546 bool raw_mode_war) 3547 { 3548 cfg->raw_mode_war = raw_mode_war; 3549 } 3550 3551 bool wlan_cfg_get_raw_mode_war(struct wlan_cfg_dp_soc_ctxt *cfg) 3552 { 3553 return cfg->raw_mode_war; 3554 } 3555 3556 int wlan_cfg_get_num_global_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3557 { 3558 return cfg->num_global_tx_desc; 3559 } 3560 3561 int wlan_cfg_get_num_global_spcl_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3562 { 3563 return cfg->num_global_spcl_tx_desc; 3564 } 3565 3566 int wlan_cfg_get_num_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3567 { 3568 return cfg->num_tx_desc; 3569 } 3570 3571 int wlan_cfg_get_num_tx_spl_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3572 { 3573 return cfg->num_tx_spl_desc; 3574 } 3575 3576 void wlan_cfg_set_num_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg, int num_desc) 3577 { 3578 cfg->num_tx_desc = num_desc; 3579 } 3580 3581 int wlan_cfg_get_min_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3582 { 3583 return cfg->min_tx_desc; 3584 } 3585 3586 int wlan_cfg_get_num_tx_ext_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3587 { 3588 return cfg->num_tx_ext_desc; 3589 } 3590 3591 void wlan_cfg_set_num_tx_ext_desc(struct wlan_cfg_dp_soc_ctxt *cfg, int num_ext_desc) 3592 { 3593 cfg->num_tx_ext_desc = num_ext_desc; 3594 } 3595 3596 uint32_t wlan_cfg_max_peer_id(struct wlan_cfg_dp_soc_ctxt *cfg) 3597 { 3598 /* TODO: This should be calculated based on target capabilities */ 3599 return cfg->max_peer_id; 3600 } 3601 3602 int wlan_cfg_get_dma_mon_buf_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3603 { 3604 return cfg->dma_mon_buf_ring_size; 3605 } 3606 3607 qdf_export_symbol(wlan_cfg_get_dma_mon_buf_ring_size); 3608 3609 int wlan_cfg_get_dma_rx_mon_dest_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3610 { 3611 return cfg->dma_rx_mon_dest_ring_size; 3612 } 3613 3614 qdf_export_symbol(wlan_cfg_get_dma_rx_mon_dest_ring_size); 3615 3616 int wlan_cfg_get_dma_tx_mon_dest_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3617 { 3618 return cfg->dma_tx_mon_dest_ring_size; 3619 } 3620 3621 qdf_export_symbol(wlan_cfg_get_dma_tx_mon_dest_ring_size); 3622 3623 int wlan_cfg_get_dma_mon_stat_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3624 { 3625 return cfg->dma_mon_status_ring_size; 3626 } 3627 3628 qdf_export_symbol(wlan_cfg_get_dma_mon_stat_ring_size); 3629 3630 int 3631 wlan_cfg_get_dma_mon_desc_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3632 { 3633 return cfg->rxdma_monitor_desc_ring; 3634 } 3635 3636 qdf_export_symbol(wlan_cfg_get_dma_mon_desc_ring_size); 3637 3638 int wlan_cfg_get_rx_dma_buf_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3639 { 3640 return cfg->rx_dma_buf_ring_size; 3641 } 3642 3643 int wlan_cfg_get_num_mac_rings(struct wlan_cfg_dp_pdev_ctxt *cfg) 3644 { 3645 return cfg->num_mac_rings; 3646 } 3647 3648 qdf_export_symbol(wlan_cfg_get_num_mac_rings); 3649 3650 bool wlan_cfg_is_gro_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3651 { 3652 return cfg->gro_enabled; 3653 } 3654 3655 bool wlan_cfg_is_lro_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3656 { 3657 return cfg->lro_enabled; 3658 } 3659 3660 bool wlan_cfg_is_ipa_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3661 { 3662 return cfg->ipa_enabled; 3663 } 3664 3665 void wlan_cfg_set_rx_hash(struct wlan_cfg_dp_soc_ctxt *cfg, bool val) 3666 { 3667 cfg->rx_hash = val; 3668 } 3669 3670 bool wlan_cfg_is_rx_hash_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3671 { 3672 return cfg->rx_hash; 3673 } 3674 3675 int wlan_cfg_get_dp_pdev_nss_enabled(struct wlan_cfg_dp_pdev_ctxt *cfg) 3676 { 3677 return cfg->nss_enabled; 3678 } 3679 3680 void wlan_cfg_set_dp_pdev_nss_enabled(struct wlan_cfg_dp_pdev_ctxt *cfg, int nss_enabled) 3681 { 3682 cfg->nss_enabled = nss_enabled; 3683 } 3684 3685 int wlan_cfg_get_dp_soc_nss_cfg(struct wlan_cfg_dp_soc_ctxt *cfg) 3686 { 3687 return cfg->nss_cfg; 3688 } 3689 3690 void wlan_cfg_set_dp_soc_nss_cfg(struct wlan_cfg_dp_soc_ctxt *cfg, int nss_cfg) 3691 { 3692 cfg->nss_cfg = nss_cfg; 3693 if (cfg->nss_cfg) 3694 cfg->tx_comp_ring_size = cfg->tx_comp_ring_size_nss; 3695 } 3696 3697 int wlan_cfg_get_int_batch_threshold_ppe2tcl(struct wlan_cfg_dp_soc_ctxt *cfg) 3698 { 3699 return cfg->int_batch_threshold_ppe2tcl; 3700 } 3701 3702 int wlan_cfg_get_int_timer_threshold_ppe2tcl(struct wlan_cfg_dp_soc_ctxt *cfg) 3703 { 3704 return cfg->int_timer_threshold_ppe2tcl; 3705 } 3706 3707 int wlan_cfg_get_int_batch_threshold_tx(struct wlan_cfg_dp_soc_ctxt *cfg) 3708 { 3709 return cfg->int_batch_threshold_tx; 3710 } 3711 3712 int wlan_cfg_get_int_timer_threshold_tx(struct wlan_cfg_dp_soc_ctxt *cfg) 3713 { 3714 return cfg->int_timer_threshold_tx; 3715 } 3716 3717 int wlan_cfg_get_int_batch_threshold_rx(struct wlan_cfg_dp_soc_ctxt *cfg) 3718 { 3719 return cfg->int_batch_threshold_rx; 3720 } 3721 3722 int wlan_cfg_get_int_timer_threshold_rx(struct wlan_cfg_dp_soc_ctxt *cfg) 3723 { 3724 return cfg->int_timer_threshold_rx; 3725 } 3726 3727 int wlan_cfg_get_int_batch_threshold_other(struct wlan_cfg_dp_soc_ctxt *cfg) 3728 { 3729 return cfg->int_batch_threshold_other; 3730 } 3731 3732 int wlan_cfg_get_int_timer_threshold_other(struct wlan_cfg_dp_soc_ctxt *cfg) 3733 { 3734 return cfg->int_timer_threshold_other; 3735 } 3736 3737 int wlan_cfg_get_int_timer_threshold_mon(struct wlan_cfg_dp_soc_ctxt *cfg) 3738 { 3739 return cfg->int_timer_threshold_mon; 3740 } 3741 3742 int wlan_cfg_get_p2p_checksum_offload(struct wlan_cfg_dp_soc_ctxt *cfg) 3743 { 3744 return cfg->p2p_tcp_udp_checksumoffload; 3745 } 3746 3747 int wlan_cfg_get_nan_checksum_offload(struct wlan_cfg_dp_soc_ctxt *cfg) 3748 { 3749 return cfg->nan_tcp_udp_checksumoffload; 3750 } 3751 3752 int wlan_cfg_get_checksum_offload(struct wlan_cfg_dp_soc_ctxt *cfg) 3753 { 3754 return cfg->tcp_udp_checksumoffload; 3755 } 3756 3757 int wlan_cfg_get_rx_defrag_min_timeout(struct wlan_cfg_dp_soc_ctxt *cfg) 3758 { 3759 return cfg->rx_defrag_min_timeout; 3760 } 3761 3762 int wlan_cfg_get_defrag_timeout_check(struct wlan_cfg_dp_soc_ctxt *cfg) 3763 { 3764 return cfg->defrag_timeout_check; 3765 } 3766 3767 int 3768 wlan_cfg_get_dp_soc_wbm_release_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3769 { 3770 return cfg->wbm_release_ring; 3771 } 3772 3773 int 3774 wlan_cfg_get_dp_soc_tcl_cmd_credit_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3775 { 3776 return cfg->tcl_cmd_credit_ring; 3777 } 3778 3779 int 3780 wlan_cfg_get_dp_soc_tcl_status_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3781 { 3782 return cfg->tcl_status_ring; 3783 } 3784 3785 int 3786 wlan_cfg_get_dp_soc_reo_reinject_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3787 { 3788 return cfg->reo_reinject_ring; 3789 } 3790 3791 int 3792 wlan_cfg_get_dp_soc_rx_release_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3793 { 3794 return cfg->rx_release_ring; 3795 } 3796 3797 int 3798 wlan_cfg_get_dp_soc_reo_exception_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3799 { 3800 return cfg->reo_exception_ring; 3801 } 3802 3803 int 3804 wlan_cfg_get_dp_soc_reo_cmd_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3805 { 3806 return cfg->reo_cmd_ring; 3807 } 3808 3809 int 3810 wlan_cfg_get_dp_soc_reo_status_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3811 { 3812 return cfg->reo_status_ring; 3813 } 3814 3815 int 3816 wlan_cfg_get_dp_soc_rxdma_refill_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3817 { 3818 return cfg->rxdma_refill_ring; 3819 } 3820 3821 bool 3822 wlan_cfg_get_dp_soc_rxdma_refill_lt_disable(struct wlan_cfg_dp_soc_ctxt *cfg) 3823 { 3824 return cfg->rxdma_refill_lt_disable; 3825 } 3826 3827 int 3828 wlan_cfg_get_dp_soc_tx_desc_limit_0(struct wlan_cfg_dp_soc_ctxt *cfg) 3829 { 3830 return cfg->tx_desc_limit_0; 3831 } 3832 3833 int 3834 wlan_cfg_get_dp_soc_tx_desc_limit_1(struct wlan_cfg_dp_soc_ctxt *cfg) 3835 { 3836 return cfg->tx_desc_limit_1; 3837 } 3838 3839 int 3840 wlan_cfg_get_dp_soc_tx_desc_limit_2(struct wlan_cfg_dp_soc_ctxt *cfg) 3841 { 3842 return cfg->tx_desc_limit_2; 3843 } 3844 3845 int 3846 wlan_cfg_get_dp_soc_tx_device_limit(struct wlan_cfg_dp_soc_ctxt *cfg) 3847 { 3848 return cfg->tx_device_limit; 3849 } 3850 3851 int 3852 wlan_cfg_get_dp_soc_tx_spl_device_limit(struct wlan_cfg_dp_soc_ctxt *cfg) 3853 { 3854 return cfg->tx_spl_device_limit; 3855 } 3856 3857 int 3858 wlan_cfg_get_dp_soc_tx_sw_internode_queue(struct wlan_cfg_dp_soc_ctxt *cfg) 3859 { 3860 return cfg->tx_sw_internode_queue; 3861 } 3862 3863 int 3864 wlan_cfg_get_dp_soc_rxdma_err_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3865 { 3866 return cfg->rxdma_err_dst_ring; 3867 } 3868 3869 int 3870 wlan_cfg_get_dp_soc_rx_sw_desc_weight(struct wlan_cfg_dp_soc_ctxt *cfg) 3871 { 3872 return cfg->rx_sw_desc_weight; 3873 } 3874 3875 qdf_export_symbol(wlan_cfg_get_dp_soc_rx_sw_desc_weight); 3876 3877 int 3878 wlan_cfg_get_dp_soc_rx_sw_desc_num(struct wlan_cfg_dp_soc_ctxt *cfg) 3879 { 3880 return cfg->rx_sw_desc_num; 3881 } 3882 3883 uint32_t 3884 wlan_cfg_get_reo_rings_mapping(struct wlan_cfg_dp_soc_ctxt *cfg) 3885 { 3886 return cfg->reo_rings_mapping; 3887 } 3888 3889 bool 3890 wlan_cfg_get_dp_caps(struct wlan_cfg_dp_soc_ctxt *cfg, 3891 enum cdp_capabilities dp_caps) 3892 { 3893 switch (dp_caps) { 3894 case CDP_CFG_DP_TSO: 3895 return cfg->tso_enabled; 3896 case CDP_CFG_DP_LRO: 3897 return cfg->lro_enabled; 3898 case CDP_CFG_DP_SG: 3899 return cfg->sg_enabled; 3900 case CDP_CFG_DP_GRO: 3901 return cfg->gro_enabled; 3902 case CDP_CFG_DP_OL_TX_CSUM: 3903 return cfg->ol_tx_csum_enabled; 3904 case CDP_CFG_DP_OL_RX_CSUM: 3905 return cfg->ol_rx_csum_enabled; 3906 case CDP_CFG_DP_RAWMODE: 3907 return cfg->rawmode_enabled; 3908 case CDP_CFG_DP_PEER_FLOW_CTRL: 3909 return cfg->peer_flow_ctrl_enabled; 3910 case CDP_CFG_DP_MARK_NOTIFY_FRAME_SUPPORT: 3911 return cfg->notify_frame_support; 3912 default: 3913 return false; 3914 } 3915 } 3916 3917 void wlan_cfg_set_tso_desc_attach_defer(struct wlan_cfg_dp_soc_ctxt *cfg, 3918 bool val) 3919 { 3920 cfg->is_tso_desc_attach_defer = val; 3921 } 3922 3923 bool wlan_cfg_is_tso_desc_attach_defer(struct wlan_cfg_dp_soc_ctxt *cfg) 3924 { 3925 return cfg->is_tso_desc_attach_defer; 3926 } 3927 3928 #ifdef QCA_LL_TX_FLOW_CONTROL_V2 3929 /** 3930 * wlan_cfg_get_tx_flow_stop_queue_th() - Get flow control stop threshold 3931 * @cfg: config context 3932 * 3933 * Return: stop threshold 3934 */ 3935 int wlan_cfg_get_tx_flow_stop_queue_th(struct wlan_cfg_dp_soc_ctxt *cfg) 3936 { 3937 return cfg->tx_flow_stop_queue_threshold; 3938 } 3939 3940 /** 3941 * wlan_cfg_get_tx_flow_start_queue_offset() - Get flow control start offset 3942 * for TX to resume 3943 * @cfg: config context 3944 * 3945 * Return: stop threshold 3946 */ 3947 int wlan_cfg_get_tx_flow_start_queue_offset(struct wlan_cfg_dp_soc_ctxt *cfg) 3948 { 3949 return cfg->tx_flow_start_queue_offset; 3950 } 3951 #endif /* QCA_LL_TX_FLOW_CONTROL_V2 */ 3952 3953 void wlan_cfg_set_rx_flow_tag_enabled(struct wlan_cfg_dp_soc_ctxt *cfg, 3954 bool val) 3955 { 3956 cfg->is_rx_flow_tag_enabled = val; 3957 } 3958 3959 uint8_t *wlan_cfg_rx_fst_get_hash_key(struct wlan_cfg_dp_soc_ctxt *cfg) 3960 { 3961 return cfg->rx_toeplitz_hash_key; 3962 } 3963 3964 uint8_t wlan_cfg_rx_fst_get_max_search(struct wlan_cfg_dp_soc_ctxt *cfg) 3965 { 3966 return cfg->rx_flow_max_search; 3967 } 3968 3969 bool wlan_cfg_is_rx_flow_tag_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3970 { 3971 return cfg->is_rx_flow_tag_enabled; 3972 } 3973 3974 qdf_export_symbol(wlan_cfg_is_rx_flow_tag_enabled); 3975 3976 #ifdef WLAN_SUPPORT_RX_FISA 3977 bool wlan_cfg_is_rx_fisa_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3978 { 3979 return (bool)(cfg->is_rx_fisa_enabled); 3980 } 3981 3982 bool wlan_cfg_is_rx_fisa_lru_del_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3983 { 3984 return cfg->is_rx_fisa_lru_del_enabled; 3985 } 3986 #else 3987 bool wlan_cfg_is_rx_fisa_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3988 { 3989 return false; 3990 } 3991 3992 bool wlan_cfg_is_rx_fisa_lru_del_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3993 { 3994 return false; 3995 } 3996 #endif 3997 3998 bool wlan_cfg_is_poll_mode_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3999 { 4000 return (bool)(cfg->is_poll_mode_enabled); 4001 } 4002 4003 void 4004 wlan_cfg_set_rx_flow_search_table_per_pdev(struct wlan_cfg_dp_soc_ctxt *cfg, 4005 bool val) 4006 { 4007 cfg->is_rx_flow_search_table_per_pdev = val; 4008 } 4009 4010 bool wlan_cfg_is_rx_flow_search_table_per_pdev(struct wlan_cfg_dp_soc_ctxt *cfg) 4011 { 4012 return cfg->is_rx_flow_search_table_per_pdev; 4013 } 4014 4015 void wlan_cfg_set_rx_flow_search_table_size(struct wlan_cfg_dp_soc_ctxt *cfg, 4016 uint16_t val) 4017 { 4018 cfg->rx_flow_search_table_size = val; 4019 } 4020 4021 uint16_t 4022 wlan_cfg_get_rx_flow_search_table_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4023 { 4024 return cfg->rx_flow_search_table_size; 4025 } 4026 4027 void 4028 wlan_cfg_set_rx_mon_protocol_flow_tag_enabled(struct wlan_cfg_dp_soc_ctxt *cfg, 4029 bool val) 4030 { 4031 cfg->is_rx_mon_protocol_flow_tag_enabled = val; 4032 } 4033 4034 bool 4035 wlan_cfg_is_rx_mon_protocol_flow_tag_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4036 { 4037 return cfg->is_rx_mon_protocol_flow_tag_enabled; 4038 } 4039 4040 qdf_export_symbol(wlan_cfg_is_rx_mon_protocol_flow_tag_enabled); 4041 4042 void 4043 wlan_cfg_set_tx_per_pkt_vdev_id_check(struct wlan_cfg_dp_soc_ctxt *cfg, 4044 bool val) 4045 { 4046 cfg->tx_per_pkt_vdev_id_check = val; 4047 } 4048 4049 bool 4050 wlan_cfg_is_tx_per_pkt_vdev_id_check_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4051 { 4052 return cfg->tx_per_pkt_vdev_id_check; 4053 } 4054 4055 void 4056 wlan_cfg_set_peer_ext_stats(struct wlan_cfg_dp_soc_ctxt *cfg, 4057 bool val) 4058 { 4059 cfg->pext_stats_enabled = val; 4060 } 4061 4062 void 4063 wlan_cfg_set_peer_jitter_stats(struct wlan_cfg_dp_soc_ctxt *cfg, 4064 bool val) 4065 { 4066 cfg->jitter_stats_enabled = val; 4067 } 4068 4069 bool 4070 wlan_cfg_is_peer_ext_stats_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4071 { 4072 return cfg->pext_stats_enabled; 4073 } 4074 4075 bool wlan_cfg_is_fst_in_cmem_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4076 { 4077 return cfg->fst_in_cmem; 4078 } 4079 4080 bool wlan_cfg_is_peer_jitter_stats_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4081 { 4082 return cfg->jitter_stats_enabled; 4083 } 4084 4085 #ifdef WLAN_FEATURE_RX_PREALLOC_BUFFER_POOL 4086 bool wlan_cfg_is_rx_buffer_pool_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4087 { 4088 return cfg->is_rx_buff_pool_enabled; 4089 } 4090 4091 bool wlan_cfg_is_rx_refill_buffer_pool_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4092 { 4093 return cfg->is_rx_refill_buff_pool_enabled; 4094 } 4095 #else 4096 bool wlan_cfg_is_rx_buffer_pool_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4097 { 4098 return false; 4099 } 4100 4101 bool wlan_cfg_is_rx_refill_buffer_pool_enabled( 4102 struct wlan_cfg_dp_soc_ctxt *cfg) 4103 { 4104 return false; 4105 } 4106 #endif /* WLAN_FEATURE_RX_PREALLOC_BUFFER_POOL */ 4107 4108 #ifdef WLAN_DP_FEATURE_SW_LATENCY_MGR 4109 bool wlan_cfg_is_swlm_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4110 { 4111 return (bool)(cfg->is_swlm_enabled); 4112 } 4113 #else 4114 bool wlan_cfg_is_swlm_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4115 { 4116 return false; 4117 } 4118 #endif 4119 uint8_t wlan_cfg_radio0_default_reo_get(struct wlan_cfg_dp_soc_ctxt *cfg) 4120 { 4121 return cfg->radio0_rx_default_reo; 4122 } 4123 4124 uint8_t wlan_cfg_radio1_default_reo_get(struct wlan_cfg_dp_soc_ctxt *cfg) 4125 { 4126 return cfg->radio1_rx_default_reo; 4127 } 4128 4129 uint8_t wlan_cfg_radio2_default_reo_get(struct wlan_cfg_dp_soc_ctxt *cfg) 4130 { 4131 return cfg->radio2_rx_default_reo; 4132 } 4133 4134 void wlan_cfg_set_rxdma1_enable(struct wlan_cfg_dp_soc_ctxt *cfg) 4135 { 4136 cfg->rxdma1_enable = true; 4137 } 4138 4139 void 4140 wlan_cfg_set_delay_mon_replenish(struct wlan_cfg_dp_soc_ctxt *cfg, 4141 bool val) 4142 { 4143 cfg->delay_mon_replenish = val; 4144 } 4145 4146 bool 4147 wlan_cfg_is_delay_mon_replenish(struct wlan_cfg_dp_soc_ctxt *cfg) 4148 { 4149 return cfg->delay_mon_replenish; 4150 } 4151 4152 qdf_export_symbol(wlan_cfg_is_delay_mon_replenish); 4153 4154 void wlan_cfg_dp_soc_ctx_dump(struct wlan_cfg_dp_soc_ctxt *cfg) 4155 { 4156 dp_info("DP CFG SoC ctx: delay_mon_replenish = %d,", 4157 cfg->delay_mon_replenish); 4158 dp_info("reo_dst_ring_size = %d, delayed_replenish_entries = %d", 4159 cfg->reo_dst_ring_size, cfg->delayed_replenish_entries); 4160 } 4161 4162 #ifdef IPA_OFFLOAD 4163 uint32_t wlan_cfg_ipa_tx_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4164 { 4165 return cfg->ipa_tx_ring_size; 4166 } 4167 4168 uint32_t wlan_cfg_ipa_tx_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4169 { 4170 return cfg->ipa_tx_comp_ring_size; 4171 } 4172 4173 #ifdef IPA_WDI3_TX_TWO_PIPES 4174 int wlan_cfg_ipa_tx_alt_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4175 { 4176 return cfg->ipa_tx_alt_ring_size; 4177 } 4178 4179 int wlan_cfg_ipa_tx_alt_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4180 { 4181 return cfg->ipa_tx_alt_comp_ring_size; 4182 } 4183 4184 #else 4185 int wlan_cfg_ipa_tx_alt_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4186 { 4187 return cfg->ipa_tx_ring_size; 4188 } 4189 4190 int wlan_cfg_ipa_tx_alt_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4191 { 4192 return cfg->ipa_tx_comp_ring_size; 4193 } 4194 #endif 4195 #endif 4196 4197 #ifdef WLAN_SUPPORT_PPEDS 4198 bool 4199 wlan_cfg_get_dp_soc_is_ppeds_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4200 { 4201 return cfg->ppeds_enable; 4202 } 4203 4204 int 4205 wlan_cfg_get_dp_soc_reo2ppe_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4206 { 4207 return cfg->reo2ppe_ring; 4208 } 4209 4210 int 4211 wlan_cfg_get_dp_soc_ppe2tcl_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4212 { 4213 return cfg->ppe2tcl_ring; 4214 } 4215 4216 int 4217 wlan_cfg_get_dp_soc_ppeds_num_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 4218 { 4219 return cfg->ppeds_num_tx_desc; 4220 } 4221 4222 int 4223 wlan_cfg_get_dp_soc_ppeds_tx_comp_napi_budget(struct wlan_cfg_dp_soc_ctxt *cfg) 4224 { 4225 return cfg->ppeds_tx_comp_napi_budget; 4226 } 4227 #endif 4228 4229 void 4230 wlan_cfg_get_prealloc_cfg(struct cdp_ctrl_objmgr_psoc *ctrl_psoc, 4231 struct wlan_dp_prealloc_cfg *cfg) 4232 { 4233 if (!ctrl_psoc || !cfg) 4234 return; 4235 4236 cfg->num_reo_dst_ring_entries = cfg_get(ctrl_psoc, 4237 CFG_DP_RX_DESTINATION_RING); 4238 cfg->num_tx_ring_entries = cfg_get(ctrl_psoc, CFG_DP_TX_RING_SIZE); 4239 cfg->num_tx_comp_ring_entries = cfg_get(ctrl_psoc, 4240 CFG_DP_TX_COMPL_RING_SIZE); 4241 cfg->num_wbm_rel_ring_entries = cfg_get(ctrl_psoc, 4242 CFG_DP_WBM_RELEASE_RING); 4243 cfg->num_rxdma_err_dst_ring_entries = cfg_get(ctrl_psoc, 4244 CFG_DP_RXDMA_ERR_DST_RING); 4245 cfg->num_reo_exception_ring_entries = cfg_get(ctrl_psoc, 4246 CFG_DP_REO_EXCEPTION_RING); 4247 cfg->num_tx_desc = cfg_get(ctrl_psoc, CFG_DP_TX_DESC); 4248 cfg->num_tx_ext_desc = cfg_get(ctrl_psoc, CFG_DP_TX_EXT_DESC); 4249 cfg->num_rxdma_buf_ring_entries = cfg_get(ctrl_psoc, 4250 CFG_DP_RXDMA_BUF_RING); 4251 cfg->num_rxdma_refill_ring_entries = cfg_get(ctrl_psoc, 4252 CFG_DP_RXDMA_REFILL_RING); 4253 cfg->num_reo_status_ring_entries = cfg_get(ctrl_psoc, 4254 CFG_DP_REO_STATUS_RING); 4255 cfg->num_mon_status_ring_entries = cfg_get(ctrl_psoc, 4256 CFG_DP_RXDMA_MONITOR_STATUS_RING); 4257 } 4258 4259 #ifdef WLAN_FEATURE_PKT_CAPTURE_V2 4260 uint32_t wlan_cfg_get_pkt_capture_mode(struct wlan_cfg_dp_soc_ctxt *cfg) 4261 { 4262 return cfg->pkt_capture_mode; 4263 } 4264 #endif 4265 4266 uint32_t 4267 wlan_cfg_get_dp_soc_rx_mon_buf_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4268 { 4269 return cfg->rx_mon_buf_ring_size; 4270 } 4271 4272 qdf_export_symbol(wlan_cfg_get_dp_soc_rx_mon_buf_ring_size); 4273 4274 uint32_t 4275 wlan_cfg_get_dp_soc_tx_mon_buf_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4276 { 4277 return cfg->tx_mon_buf_ring_size; 4278 } 4279 4280 qdf_export_symbol(wlan_cfg_get_dp_soc_tx_mon_buf_ring_size); 4281 4282 uint8_t 4283 wlan_cfg_get_rx_rel_ring_id(struct wlan_cfg_dp_soc_ctxt *cfg) 4284 { 4285 return cfg->rx_rel_wbm2sw_ring_id; 4286 } 4287 4288 void 4289 wlan_cfg_set_rx_rel_ring_id(struct wlan_cfg_dp_soc_ctxt *cfg, 4290 uint8_t wbm2sw_ring_id) 4291 { 4292 cfg->rx_rel_wbm2sw_ring_id = wbm2sw_ring_id; 4293 } 4294 4295 #if defined(WLAN_FEATURE_11BE_MLO) && defined(WLAN_MLO_MULTI_CHIP) 4296 uint8_t 4297 wlan_cfg_mlo_rx_ring_map_get(struct wlan_cfg_dp_soc_ctxt *cfg) 4298 { 4299 return cfg->mlo_chip_rx_ring_map; 4300 } 4301 #endif 4302 4303 #ifdef QCA_VDEV_STATS_HW_OFFLOAD_SUPPORT 4304 bool 4305 wlan_cfg_get_vdev_stats_hw_offload_config(struct wlan_cfg_dp_soc_ctxt *cfg) 4306 { 4307 return cfg->vdev_stats_hw_offload_config; 4308 } 4309 4310 int wlan_cfg_get_vdev_stats_hw_offload_timer(struct wlan_cfg_dp_soc_ctxt *cfg) 4311 { 4312 return cfg->vdev_stats_hw_offload_timer; 4313 } 4314 4315 void 4316 wlan_cfg_set_vdev_stats_hw_offload_config(struct wlan_cfg_dp_soc_ctxt *cfg, 4317 bool val) 4318 { 4319 cfg->vdev_stats_hw_offload_config = val; 4320 } 4321 #else 4322 bool 4323 wlan_cfg_get_vdev_stats_hw_offload_config(struct wlan_cfg_dp_soc_ctxt *cfg) 4324 { 4325 return false; 4326 } 4327 4328 int wlan_cfg_get_vdev_stats_hw_offload_timer(struct wlan_cfg_dp_soc_ctxt *cfg) 4329 { 4330 return 0; 4331 } 4332 4333 void 4334 wlan_cfg_set_vdev_stats_hw_offload_config(struct wlan_cfg_dp_soc_ctxt *cfg, 4335 bool val) 4336 {} 4337 #endif 4338 4339 #ifdef CONFIG_SAWF 4340 bool wlan_cfg_get_sawf_config(struct wlan_cfg_dp_soc_ctxt *cfg) 4341 { 4342 return cfg->sawf_enabled; 4343 } 4344 4345 void wlan_cfg_set_sawf_config(struct wlan_cfg_dp_soc_ctxt *cfg, bool val) 4346 { 4347 cfg->sawf_enabled = val; 4348 } 4349 #else 4350 bool wlan_cfg_get_sawf_config(struct wlan_cfg_dp_soc_ctxt *cfg) 4351 { 4352 return false; 4353 } 4354 4355 void wlan_cfg_set_sawf_config(struct wlan_cfg_dp_soc_ctxt *cfg, bool val) 4356 { 4357 } 4358 #endif 4359 4360 #ifdef CONFIG_BERYLLIUM 4361 int wlan_cfg_get_host2txmon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 4362 int context) 4363 { 4364 return cfg->int_host2txmon_ring_mask[context]; 4365 } 4366 4367 qdf_export_symbol(wlan_cfg_get_host2txmon_ring_mask); 4368 4369 void wlan_cfg_set_host2txmon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 4370 int context, int mask) 4371 { 4372 cfg->int_host2txmon_ring_mask[context] = mask; 4373 } 4374 #else 4375 int wlan_cfg_get_host2txmon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 4376 int context) 4377 { 4378 return 0; 4379 } 4380 4381 void wlan_cfg_set_host2txmon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 4382 int context, int mask) 4383 { 4384 } 4385 #endif 4386 4387 qdf_export_symbol(wlan_cfg_set_host2txmon_ring_mask); 4388 4389 void wlan_cfg_set_txmon_hw_support(struct wlan_cfg_dp_soc_ctxt *cfg, 4390 bool txmon_hw_support) 4391 { 4392 cfg->txmon_hw_support = txmon_hw_support; 4393 } 4394 4395 bool wlan_cfg_get_txmon_hw_support(struct wlan_cfg_dp_soc_ctxt *cfg) 4396 { 4397 return cfg->txmon_hw_support; 4398 } 4399 4400 qdf_export_symbol(wlan_cfg_get_txmon_hw_support); 4401 4402 uint8_t wlan_cfg_get_napi_scale_factor(struct wlan_cfg_dp_soc_ctxt *cfg) 4403 { 4404 return cfg->napi_scale_factor; 4405 } 4406 4407 bool wlan_cfg_get_txmon_sw_peer_filtering(struct wlan_cfg_dp_soc_ctxt *cfg) 4408 { 4409 return cfg->txmon_sw_peer_filtering; 4410 } 4411 4412 qdf_export_symbol(wlan_cfg_get_txmon_sw_peer_filtering); 4413