1 /* 2 * Copyright (c) 2016-2021 The Linux Foundation. All rights reserved. 3 * Copyright (c) 2021-2022 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 struct wlan_cfg_dp_soc_ctxt * 2839 wlan_cfg_soc_attach(struct cdp_ctrl_objmgr_psoc *psoc) 2840 { 2841 struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx = 2842 qdf_mem_malloc(sizeof(struct wlan_cfg_dp_soc_ctxt)); 2843 uint32_t gro_bit_set; 2844 2845 if (!wlan_cfg_ctx) 2846 return NULL; 2847 2848 wlan_cfg_ctx->rxdma1_enable = WLAN_CFG_RXDMA1_ENABLE; 2849 wlan_cfg_ctx->num_int_ctxts = WLAN_CFG_INT_NUM_CONTEXTS; 2850 wlan_cfg_ctx->max_clients = cfg_get(psoc, CFG_DP_MAX_CLIENTS); 2851 wlan_cfg_ctx->max_alloc_size = cfg_get(psoc, CFG_DP_MAX_ALLOC_SIZE); 2852 wlan_cfg_ctx->per_pdev_tx_ring = cfg_get(psoc, CFG_DP_PDEV_TX_RING); 2853 wlan_cfg_ctx->num_reo_dest_rings = cfg_get(psoc, CFG_DP_REO_DEST_RINGS); 2854 wlan_cfg_ctx->num_tcl_data_rings = cfg_get(psoc, CFG_DP_TCL_DATA_RINGS); 2855 wlan_cfg_ctx->num_tx_comp_rings = cfg_get(psoc, CFG_DP_TX_COMP_RINGS); 2856 wlan_cfg_ctx->num_nss_reo_dest_rings = 2857 cfg_get(psoc, CFG_DP_NSS_REO_DEST_RINGS); 2858 wlan_cfg_ctx->num_nss_tcl_data_rings = 2859 cfg_get(psoc, CFG_DP_NSS_TCL_DATA_RINGS); 2860 wlan_cfg_ctx->per_pdev_rx_ring = cfg_get(psoc, CFG_DP_PDEV_RX_RING); 2861 wlan_cfg_ctx->per_pdev_lmac_ring = cfg_get(psoc, CFG_DP_PDEV_LMAC_RING); 2862 wlan_cfg_ctx->num_tx_desc_pool = MAX_TXDESC_POOLS; 2863 wlan_cfg_ctx->num_tx_ext_desc_pool = cfg_get(psoc, 2864 CFG_DP_TX_EXT_DESC_POOLS); 2865 wlan_cfg_ctx->num_tx_desc = cfg_get(psoc, CFG_DP_TX_DESC); 2866 wlan_cfg_ctx->num_tx_spl_desc = cfg_get(psoc, CFG_DP_TX_SPL_DESC); 2867 wlan_cfg_ctx->min_tx_desc = WLAN_CFG_NUM_TX_DESC_MIN; 2868 wlan_cfg_ctx->num_tx_ext_desc = cfg_get(psoc, CFG_DP_TX_EXT_DESC); 2869 wlan_cfg_ctx->htt_packet_type = cfg_get(psoc, CFG_DP_HTT_PACKET_TYPE); 2870 wlan_cfg_ctx->max_peer_id = cfg_get(psoc, CFG_DP_MAX_PEER_ID); 2871 2872 wlan_cfg_ctx->tx_ring_size = cfg_get(psoc, CFG_DP_TX_RING_SIZE); 2873 wlan_cfg_ctx->time_control_bp = cfg_get(psoc, CFG_DP_TIME_CONTROL_BP); 2874 wlan_cfg_ctx->tx_comp_ring_size = cfg_get(psoc, 2875 CFG_DP_TX_COMPL_RING_SIZE); 2876 2877 wlan_cfg_ctx->tx_comp_ring_size_nss = 2878 cfg_get(psoc, CFG_DP_NSS_COMP_RING_SIZE); 2879 2880 wlan_cfg_ctx->int_batch_threshold_tx = 2881 cfg_get(psoc, CFG_DP_INT_BATCH_THRESHOLD_TX); 2882 wlan_cfg_ctx->int_timer_threshold_tx = 2883 cfg_get(psoc, CFG_DP_INT_TIMER_THRESHOLD_TX); 2884 wlan_cfg_ctx->int_batch_threshold_rx = 2885 cfg_get(psoc, CFG_DP_INT_BATCH_THRESHOLD_RX); 2886 wlan_cfg_ctx->int_timer_threshold_rx = 2887 cfg_get(psoc, CFG_DP_INT_TIMER_THRESHOLD_RX); 2888 wlan_cfg_ctx->int_batch_threshold_other = 2889 cfg_get(psoc, CFG_DP_INT_BATCH_THRESHOLD_OTHER); 2890 wlan_cfg_ctx->int_timer_threshold_other = 2891 cfg_get(psoc, CFG_DP_INT_TIMER_THRESHOLD_OTHER); 2892 wlan_cfg_ctx->int_batch_threshold_ppe2tcl = 2893 cfg_get(psoc, CFG_DP_INT_BATCH_THRESHOLD_PPE2TCL); 2894 wlan_cfg_ctx->int_timer_threshold_ppe2tcl = 2895 cfg_get(psoc, CFG_DP_INT_TIMER_THRESHOLD_PPE2TCL); 2896 2897 wlan_cfg_ctx->pktlog_buffer_size = 2898 cfg_get(psoc, CFG_DP_PKTLOG_BUFFER_SIZE); 2899 2900 /* This is default mapping and can be overridden by HW config 2901 * received from FW */ 2902 wlan_cfg_set_hw_mac_idx(wlan_cfg_ctx, 0, 0); 2903 if (MAX_PDEV_CNT > 1) 2904 wlan_cfg_set_hw_mac_idx(wlan_cfg_ctx, 1, 2); 2905 if (MAX_PDEV_CNT > 2) 2906 wlan_cfg_set_hw_mac_idx(wlan_cfg_ctx, 2, 1); 2907 2908 wlan_cfg_ctx->base_hw_macid = cfg_get(psoc, CFG_DP_BASE_HW_MAC_ID); 2909 2910 wlan_cfg_ctx->rx_hash = cfg_get(psoc, CFG_DP_RX_HASH); 2911 wlan_cfg_ctx->tso_enabled = cfg_get(psoc, CFG_DP_TSO); 2912 wlan_cfg_ctx->lro_enabled = cfg_get(psoc, CFG_DP_LRO); 2913 wlan_cfg_ctx->sg_enabled = cfg_get(psoc, CFG_DP_SG); 2914 gro_bit_set = cfg_get(psoc, CFG_DP_GRO); 2915 if (gro_bit_set & DP_GRO_ENABLE_BIT_SET) { 2916 wlan_cfg_ctx->gro_enabled = true; 2917 if (gro_bit_set & DP_TC_BASED_DYNAMIC_GRO) 2918 wlan_cfg_ctx->tc_based_dynamic_gro = true; 2919 } 2920 wlan_cfg_ctx->tc_ingress_prio = cfg_get(psoc, CFG_DP_TC_INGRESS_PRIO); 2921 wlan_cfg_ctx->ol_tx_csum_enabled = cfg_get(psoc, CFG_DP_OL_TX_CSUM); 2922 wlan_cfg_ctx->ol_rx_csum_enabled = cfg_get(psoc, CFG_DP_OL_RX_CSUM); 2923 wlan_cfg_ctx->rawmode_enabled = cfg_get(psoc, CFG_DP_RAWMODE); 2924 wlan_cfg_ctx->peer_flow_ctrl_enabled = 2925 cfg_get(psoc, CFG_DP_PEER_FLOW_CTRL); 2926 wlan_cfg_ctx->napi_enabled = cfg_get(psoc, CFG_DP_NAPI); 2927 wlan_cfg_ctx->p2p_tcp_udp_checksumoffload = 2928 cfg_get(psoc, CFG_DP_P2P_TCP_UDP_CKSUM_OFFLOAD); 2929 wlan_cfg_ctx->nan_tcp_udp_checksumoffload = 2930 cfg_get(psoc, CFG_DP_NAN_TCP_UDP_CKSUM_OFFLOAD); 2931 wlan_cfg_ctx->tcp_udp_checksumoffload = 2932 cfg_get(psoc, CFG_DP_TCP_UDP_CKSUM_OFFLOAD); 2933 wlan_cfg_ctx->legacy_mode_checksumoffload_disable = 2934 cfg_get(psoc, CFG_DP_LEGACY_MODE_CSUM_DISABLE); 2935 wlan_cfg_ctx->per_pkt_trace = cfg_get(psoc, CFG_DP_PER_PKT_LOGGING); 2936 wlan_cfg_ctx->defrag_timeout_check = 2937 cfg_get(psoc, CFG_DP_DEFRAG_TIMEOUT_CHECK); 2938 wlan_cfg_ctx->rx_defrag_min_timeout = 2939 cfg_get(psoc, CFG_DP_RX_DEFRAG_TIMEOUT); 2940 2941 wlan_cfg_ctx->wbm_release_ring = cfg_get(psoc, 2942 CFG_DP_WBM_RELEASE_RING); 2943 wlan_cfg_ctx->tcl_cmd_credit_ring = cfg_get(psoc, 2944 CFG_DP_TCL_CMD_CREDIT_RING); 2945 wlan_cfg_ctx->tcl_status_ring = cfg_get(psoc, 2946 CFG_DP_TCL_STATUS_RING); 2947 wlan_cfg_ctx->reo_dst_ring_size = cfg_get(psoc, 2948 CFG_DP_RX_DESTINATION_RING); 2949 wlan_cfg_ctx->reo_reinject_ring = cfg_get(psoc, 2950 CFG_DP_REO_REINJECT_RING); 2951 wlan_cfg_ctx->rx_release_ring = cfg_get(psoc, 2952 CFG_DP_RX_RELEASE_RING); 2953 wlan_cfg_ctx->reo_exception_ring = cfg_get(psoc, 2954 CFG_DP_REO_EXCEPTION_RING); 2955 wlan_cfg_ctx->reo_cmd_ring = cfg_get(psoc, 2956 CFG_DP_REO_CMD_RING); 2957 wlan_cfg_ctx->reo_status_ring = cfg_get(psoc, 2958 CFG_DP_REO_STATUS_RING); 2959 wlan_cfg_ctx->rxdma_refill_ring = cfg_get(psoc, 2960 CFG_DP_RXDMA_REFILL_RING); 2961 wlan_cfg_ctx->rxdma_refill_lt_disable = 2962 cfg_get(psoc, 2963 CFG_DP_RXDMA_REFILL_LT_DISABLE); 2964 wlan_cfg_ctx->tx_desc_limit_0 = cfg_get(psoc, 2965 CFG_DP_TX_DESC_LIMIT_0); 2966 wlan_cfg_ctx->tx_desc_limit_1 = cfg_get(psoc, 2967 CFG_DP_TX_DESC_LIMIT_1); 2968 wlan_cfg_ctx->tx_desc_limit_2 = cfg_get(psoc, 2969 CFG_DP_TX_DESC_LIMIT_2); 2970 wlan_cfg_ctx->tx_device_limit = cfg_get(psoc, 2971 CFG_DP_TX_DEVICE_LIMIT); 2972 wlan_cfg_ctx->tx_spl_device_limit = cfg_get(psoc, 2973 CFG_DP_TX_SPL_DEVICE_LIMIT); 2974 wlan_cfg_ctx->tx_sw_internode_queue = cfg_get(psoc, 2975 CFG_DP_TX_SW_INTERNODE_QUEUE); 2976 wlan_cfg_ctx->rxdma_err_dst_ring = cfg_get(psoc, 2977 CFG_DP_RXDMA_ERR_DST_RING); 2978 wlan_cfg_ctx->enable_data_stall_detection = 2979 cfg_get(psoc, CFG_DP_ENABLE_DATA_STALL_DETECTION); 2980 wlan_cfg_ctx->tx_flow_start_queue_offset = 2981 cfg_get(psoc, CFG_DP_TX_FLOW_START_QUEUE_OFFSET); 2982 wlan_cfg_ctx->tx_flow_stop_queue_threshold = 2983 cfg_get(psoc, CFG_DP_TX_FLOW_STOP_QUEUE_TH); 2984 wlan_cfg_ctx->disable_intra_bss_fwd = 2985 cfg_get(psoc, CFG_DP_AP_STA_SECURITY_SEPERATION); 2986 wlan_cfg_ctx->rx_sw_desc_weight = cfg_get(psoc, 2987 CFG_DP_RX_SW_DESC_WEIGHT); 2988 wlan_cfg_ctx->rx_sw_desc_num = cfg_get(psoc, 2989 CFG_DP_RX_SW_DESC_NUM); 2990 wlan_cfg_ctx->rx_toeplitz_hash_key = (uint8_t *)rx_fst_toeplitz_key; 2991 wlan_cfg_ctx->rx_flow_max_search = WLAN_CFG_RX_FST_MAX_SEARCH; 2992 wlan_cfg_ctx->is_rx_flow_tag_enabled = 2993 cfg_get(psoc, CFG_DP_RX_FLOW_TAG_ENABLE); 2994 wlan_cfg_ctx->is_rx_flow_search_table_per_pdev = 2995 cfg_get(psoc, CFG_DP_RX_FLOW_SEARCH_TABLE_PER_PDEV); 2996 wlan_cfg_ctx->rx_flow_search_table_size = 2997 cfg_get(psoc, CFG_DP_RX_FLOW_SEARCH_TABLE_SIZE); 2998 wlan_cfg_ctx->is_rx_mon_protocol_flow_tag_enabled = 2999 cfg_get(psoc, CFG_DP_RX_MON_PROTOCOL_FLOW_TAG_ENABLE); 3000 wlan_cfg_ctx->mon_drop_thresh = 3001 cfg_get(psoc, CFG_DP_RXDMA_MONITOR_RX_DROP_THRESHOLD); 3002 wlan_cfg_ctx->is_rx_fisa_enabled = cfg_get(psoc, CFG_DP_RX_FISA_ENABLE); 3003 wlan_cfg_ctx->is_rx_fisa_lru_del_enabled = 3004 cfg_get(psoc, CFG_DP_RX_FISA_LRU_DEL_ENABLE); 3005 wlan_cfg_ctx->reo_rings_mapping = cfg_get(psoc, CFG_DP_REO_RINGS_MAP); 3006 wlan_cfg_ctx->pext_stats_enabled = cfg_get(psoc, CFG_DP_PEER_EXT_STATS); 3007 wlan_cfg_ctx->jitter_stats_enabled = 3008 cfg_get(psoc, CFG_DP_PEER_JITTER_STATS); 3009 wlan_cfg_ctx->is_rx_buff_pool_enabled = 3010 cfg_get(psoc, CFG_DP_RX_BUFF_POOL_ENABLE); 3011 wlan_cfg_ctx->is_rx_refill_buff_pool_enabled = 3012 cfg_get(psoc, CFG_DP_RX_REFILL_BUFF_POOL_ENABLE); 3013 wlan_cfg_ctx->rx_pending_high_threshold = 3014 cfg_get(psoc, CFG_DP_RX_PENDING_HL_THRESHOLD); 3015 wlan_cfg_ctx->rx_pending_low_threshold = 3016 cfg_get(psoc, CFG_DP_RX_PENDING_LO_THRESHOLD); 3017 wlan_cfg_ctx->is_poll_mode_enabled = 3018 cfg_get(psoc, CFG_DP_POLL_MODE_ENABLE); 3019 wlan_cfg_ctx->is_swlm_enabled = cfg_get(psoc, CFG_DP_SWLM_ENABLE); 3020 wlan_cfg_ctx->fst_in_cmem = cfg_get(psoc, CFG_DP_RX_FST_IN_CMEM); 3021 wlan_cfg_ctx->tx_per_pkt_vdev_id_check = 3022 cfg_get(psoc, CFG_DP_TX_PER_PKT_VDEV_ID_CHECK); 3023 wlan_cfg_ctx->radio0_rx_default_reo = 3024 cfg_get(psoc, CFG_DP_RX_RADIO_0_DEFAULT_REO); 3025 wlan_cfg_ctx->radio1_rx_default_reo = 3026 cfg_get(psoc, CFG_DP_RX_RADIO_1_DEFAULT_REO); 3027 wlan_cfg_ctx->radio2_rx_default_reo = 3028 cfg_get(psoc, CFG_DP_RX_RADIO_2_DEFAULT_REO); 3029 wlan_cfg_ctx->wow_check_rx_pending_enable = 3030 cfg_get(psoc, CFG_DP_WOW_CHECK_RX_PENDING); 3031 wlan_cfg_ctx->delay_mon_replenish = cfg_get(psoc, 3032 CFG_DP_DELAY_MON_REPLENISH); 3033 wlan_cfg_ctx->rx_mon_buf_ring_size = cfg_get(psoc, 3034 CFG_DP_RXDMA_MONITOR_BUF_RING); 3035 wlan_cfg_ctx->tx_mon_buf_ring_size = cfg_get(psoc, 3036 CFG_DP_TX_MONITOR_BUF_RING); 3037 wlan_soc_ipa_cfg_attach(psoc, wlan_cfg_ctx); 3038 wlan_soc_hw_cc_cfg_attach(psoc, wlan_cfg_ctx); 3039 wlan_soc_ppe_cfg_attach(psoc, wlan_cfg_ctx); 3040 wlan_soc_mlo_cfg_attach(psoc, wlan_cfg_ctx); 3041 wlan_soc_vdev_hw_stats_cfg_attach(psoc, wlan_cfg_ctx); 3042 #ifdef WLAN_FEATURE_PKT_CAPTURE_V2 3043 wlan_cfg_ctx->pkt_capture_mode = cfg_get(psoc, CFG_PKT_CAPTURE_MODE) & 3044 PKT_CAPTURE_MODE_DATA_ONLY; 3045 #endif 3046 wlan_cfg_ctx->num_rxdma_dst_rings_per_pdev = NUM_RXDMA_RINGS_PER_PDEV; 3047 wlan_cfg_ctx->num_rxdma_status_rings_per_pdev = 3048 NUM_RXDMA_RINGS_PER_PDEV; 3049 wlan_soc_tx_capt_cfg_attach(psoc, wlan_cfg_ctx); 3050 wlan_cfg_ctx->mpdu_retry_threshold_1 = 3051 cfg_get(psoc, CFG_DP_MPDU_RETRY_THRESHOLD_1); 3052 wlan_cfg_ctx->mpdu_retry_threshold_2 = 3053 cfg_get(psoc, CFG_DP_MPDU_RETRY_THRESHOLD_2); 3054 3055 wlan_cfg_ctx->napi_scale_factor = cfg_get(psoc, 3056 CFG_DP_NAPI_SCALE_FACTOR); 3057 wlan_soc_sawf_stats_cfg_attach(psoc, wlan_cfg_ctx); 3058 wlan_cfg_ctx->is_handle_invalid_decap_type_disabled = 3059 cfg_get(psoc, CFG_DP_HANDLE_INVALID_DECAP_TYPE_DISABLE); 3060 wlan_cfg_ctx->txmon_sw_peer_filtering = 3061 cfg_get(psoc, CFG_DP_TXMON_SW_PEER_FILTERING); 3062 return wlan_cfg_ctx; 3063 } 3064 3065 void wlan_cfg_soc_detach(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx) 3066 { 3067 qdf_mem_free(wlan_cfg_ctx); 3068 } 3069 3070 struct wlan_cfg_dp_pdev_ctxt * 3071 wlan_cfg_pdev_attach(struct cdp_ctrl_objmgr_psoc *psoc) 3072 { 3073 struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_ctx = 3074 qdf_mem_malloc(sizeof(struct wlan_cfg_dp_pdev_ctxt)); 3075 3076 if (!wlan_cfg_ctx) 3077 return NULL; 3078 3079 wlan_cfg_ctx->rx_dma_buf_ring_size = cfg_get(psoc, 3080 CFG_DP_RXDMA_BUF_RING); 3081 wlan_cfg_ctx->dma_mon_buf_ring_size = cfg_get(psoc, 3082 CFG_DP_RXDMA_MONITOR_BUF_RING); 3083 wlan_cfg_ctx->dma_rx_mon_dest_ring_size = cfg_get(psoc, 3084 CFG_DP_RXDMA_MONITOR_DST_RING); 3085 wlan_cfg_ctx->dma_tx_mon_dest_ring_size = cfg_get(psoc, 3086 CFG_DP_TX_MONITOR_DST_RING); 3087 wlan_cfg_ctx->dma_mon_status_ring_size = cfg_get(psoc, 3088 CFG_DP_RXDMA_MONITOR_STATUS_RING); 3089 wlan_cfg_ctx->rxdma_monitor_desc_ring = cfg_get(psoc, 3090 CFG_DP_RXDMA_MONITOR_DESC_RING); 3091 wlan_cfg_ctx->num_mac_rings = NUM_RXDMA_RINGS_PER_PDEV; 3092 3093 return wlan_cfg_ctx; 3094 } 3095 3096 void wlan_cfg_set_mon_delayed_replenish_entries( 3097 struct wlan_cfg_dp_soc_ctxt *cfg, 3098 uint32_t val) 3099 { 3100 cfg->delayed_replenish_entries = val; 3101 } 3102 3103 qdf_export_symbol(wlan_cfg_set_mon_delayed_replenish_entries); 3104 3105 int wlan_cfg_get_mon_delayed_replenish_entries(struct wlan_cfg_dp_soc_ctxt *cfg) 3106 { 3107 return cfg->delayed_replenish_entries; 3108 } 3109 3110 void wlan_cfg_pdev_detach(struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_ctx) 3111 { 3112 if (wlan_cfg_ctx) 3113 qdf_mem_free(wlan_cfg_ctx); 3114 } 3115 3116 int wlan_cfg_get_mon_drop_thresh(struct wlan_cfg_dp_soc_ctxt *cfg) 3117 { 3118 return cfg->mon_drop_thresh; 3119 } 3120 3121 void wlan_cfg_set_num_contexts(struct wlan_cfg_dp_soc_ctxt *cfg, int num) 3122 { 3123 cfg->num_int_ctxts = num; 3124 } 3125 3126 void wlan_cfg_set_max_peer_id(struct wlan_cfg_dp_soc_ctxt *cfg, uint32_t val) 3127 { 3128 cfg->max_peer_id = val; 3129 } 3130 3131 void wlan_cfg_set_max_ast_idx(struct wlan_cfg_dp_soc_ctxt *cfg, uint32_t val) 3132 { 3133 cfg->max_ast_idx = val; 3134 } 3135 3136 int wlan_cfg_get_max_ast_idx(struct wlan_cfg_dp_soc_ctxt *cfg) 3137 { 3138 return cfg->max_ast_idx; 3139 } 3140 3141 qdf_export_symbol(wlan_cfg_get_max_ast_idx); 3142 3143 void wlan_cfg_set_tx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3144 int context, int mask) 3145 { 3146 cfg->int_tx_ring_mask[context] = mask; 3147 } 3148 3149 void wlan_cfg_set_rx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3150 int context, int mask) 3151 { 3152 cfg->int_rx_ring_mask[context] = mask; 3153 } 3154 3155 void wlan_cfg_set_rx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3156 int context, int mask) 3157 { 3158 cfg->int_rx_mon_ring_mask[context] = mask; 3159 } 3160 3161 void wlan_cfg_set_tx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3162 int context, int mask) 3163 { 3164 cfg->int_tx_mon_ring_mask[context] = mask; 3165 } 3166 3167 int wlan_cfg_get_host2rxdma_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3168 int context) 3169 { 3170 return cfg->int_host2rxdma_mon_ring_mask[context]; 3171 } 3172 3173 void wlan_cfg_set_host2rxdma_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3174 int context, int mask) 3175 { 3176 cfg->int_host2rxdma_mon_ring_mask[context] = mask; 3177 } 3178 3179 int wlan_cfg_get_rxdma2host_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3180 int context) 3181 { 3182 return cfg->int_rxdma2host_mon_ring_mask[context]; 3183 } 3184 3185 void wlan_cfg_set_rxdma2host_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3186 int context, int mask) 3187 { 3188 cfg->int_rxdma2host_mon_ring_mask[context] = mask; 3189 } 3190 3191 void wlan_cfg_set_rxdma2host_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3192 int context, int mask) 3193 { 3194 cfg->int_rxdma2host_ring_mask[context] = mask; 3195 } 3196 3197 int wlan_cfg_get_rxdma2host_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3198 int context) 3199 { 3200 return cfg->int_rxdma2host_ring_mask[context]; 3201 } 3202 3203 void wlan_cfg_set_host2rxdma_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3204 int context, int mask) 3205 { 3206 cfg->int_host2rxdma_ring_mask[context] = mask; 3207 } 3208 3209 int wlan_cfg_get_host2rxdma_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3210 int context) 3211 { 3212 return cfg->int_host2rxdma_ring_mask[context]; 3213 } 3214 3215 int wlan_cfg_get_rx_near_full_grp_1_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3216 int context) 3217 { 3218 return cfg->int_rx_ring_near_full_irq_1_mask[context]; 3219 } 3220 3221 int wlan_cfg_get_rx_near_full_grp_2_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3222 int context) 3223 { 3224 return cfg->int_rx_ring_near_full_irq_2_mask[context]; 3225 } 3226 3227 int wlan_cfg_get_tx_ring_near_full_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3228 int context) 3229 { 3230 return cfg->int_tx_ring_near_full_irq_mask[context]; 3231 } 3232 3233 void wlan_cfg_set_hw_mac_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx, 3234 int hw_macid) 3235 { 3236 qdf_assert_always(pdev_idx < MAX_PDEV_CNT); 3237 cfg->hw_macid[pdev_idx] = hw_macid; 3238 } 3239 3240 int wlan_cfg_get_hw_mac_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx) 3241 { 3242 qdf_assert_always(pdev_idx < MAX_PDEV_CNT); 3243 return cfg->hw_macid[pdev_idx]; 3244 } 3245 3246 qdf_export_symbol(wlan_cfg_get_hw_mac_idx); 3247 3248 int wlan_cfg_get_target_pdev_id(struct wlan_cfg_dp_soc_ctxt *cfg, 3249 int hw_macid) 3250 { 3251 int idx; 3252 3253 for (idx = 0; idx < MAX_PDEV_CNT; idx++) { 3254 if (cfg->hw_macid[idx] == hw_macid) 3255 return (idx + 1); 3256 } 3257 qdf_assert_always(idx < MAX_PDEV_CNT); 3258 return WLAN_INVALID_PDEV_ID; 3259 } 3260 3261 void wlan_cfg_set_pdev_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx, 3262 int hw_macid) 3263 { 3264 qdf_assert_always((pdev_idx < MAX_PDEV_CNT) || 3265 (pdev_idx == INVALID_PDEV_ID)); 3266 qdf_assert_always(hw_macid < MAX_NUM_LMAC_HW); 3267 cfg->hw_macid_pdev_id_map[hw_macid] = pdev_idx; 3268 } 3269 3270 int wlan_cfg_get_pdev_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int hw_macid) 3271 { 3272 qdf_assert_always(hw_macid < MAX_NUM_LMAC_HW); 3273 return cfg->hw_macid_pdev_id_map[hw_macid]; 3274 } 3275 3276 qdf_export_symbol(wlan_cfg_get_pdev_idx); 3277 3278 void wlan_cfg_set_ce_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3279 int context, int mask) 3280 { 3281 cfg->int_ce_ring_mask[context] = mask; 3282 } 3283 3284 void wlan_cfg_set_rxbuf_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context, 3285 int mask) 3286 { 3287 cfg->int_rx_ring_mask[context] = mask; 3288 } 3289 3290 int wlan_cfg_set_rx_err_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3291 int context, int mask) 3292 { 3293 return cfg->int_rx_err_ring_mask[context] = mask; 3294 } 3295 3296 int wlan_cfg_set_rx_wbm_rel_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3297 int context, int mask) 3298 { 3299 return cfg->int_rx_wbm_rel_ring_mask[context] = mask; 3300 } 3301 3302 int wlan_cfg_set_reo_status_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3303 int context, int mask) 3304 { 3305 return cfg->int_reo_status_ring_mask[context] = mask; 3306 } 3307 3308 int wlan_cfg_get_num_contexts(struct wlan_cfg_dp_soc_ctxt *cfg) 3309 { 3310 return cfg->num_int_ctxts; 3311 } 3312 3313 int wlan_cfg_get_tx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3314 { 3315 return cfg->int_tx_ring_mask[context]; 3316 } 3317 3318 int wlan_cfg_get_rx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3319 { 3320 return cfg->int_rx_ring_mask[context]; 3321 } 3322 3323 int wlan_cfg_get_rx_err_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3324 int context) 3325 { 3326 return cfg->int_rx_err_ring_mask[context]; 3327 } 3328 3329 int wlan_cfg_get_rx_wbm_rel_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3330 int context) 3331 { 3332 return cfg->int_rx_wbm_rel_ring_mask[context]; 3333 } 3334 3335 int wlan_cfg_get_reo_status_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3336 int context) 3337 { 3338 return cfg->int_reo_status_ring_mask[context]; 3339 } 3340 3341 int wlan_cfg_get_rx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3342 { 3343 return cfg->int_rx_mon_ring_mask[context]; 3344 } 3345 3346 #ifdef CONFIG_BERYLLIUM 3347 int wlan_cfg_get_tx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3348 { 3349 return cfg->int_tx_mon_ring_mask[context]; 3350 } 3351 #else 3352 int wlan_cfg_get_tx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3353 { 3354 return 0; 3355 } 3356 #endif 3357 3358 int wlan_cfg_get_ce_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context) 3359 { 3360 return cfg->int_ce_ring_mask[context]; 3361 } 3362 3363 uint32_t wlan_cfg_get_max_clients(struct wlan_cfg_dp_soc_ctxt *cfg) 3364 { 3365 return cfg->max_clients; 3366 } 3367 3368 uint32_t wlan_cfg_max_alloc_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3369 { 3370 return cfg->max_alloc_size; 3371 } 3372 3373 int wlan_cfg_per_pdev_tx_ring(struct wlan_cfg_dp_soc_ctxt *cfg) 3374 { 3375 return cfg->per_pdev_tx_ring; 3376 } 3377 3378 int wlan_cfg_get_umac_reset_intr_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 3379 int context) 3380 { 3381 return cfg->int_umac_reset_intr_mask[context]; 3382 } 3383 3384 uint32_t 3385 wlan_cfg_rx_pending_hl_threshold(struct wlan_cfg_dp_soc_ctxt *cfg) 3386 { 3387 return cfg->rx_pending_high_threshold; 3388 } 3389 3390 uint32_t 3391 wlan_cfg_rx_pending_lo_threshold(struct wlan_cfg_dp_soc_ctxt *cfg) 3392 { 3393 return cfg->rx_pending_low_threshold; 3394 } 3395 3396 int wlan_cfg_per_pdev_lmac_ring(struct wlan_cfg_dp_soc_ctxt *cfg) 3397 { 3398 return cfg->per_pdev_lmac_ring; 3399 } 3400 3401 qdf_export_symbol(wlan_cfg_per_pdev_lmac_ring); 3402 3403 #if defined(DP_USE_SINGLE_TCL) && !defined(TX_MULTI_TCL) 3404 int wlan_cfg_num_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3405 { 3406 return 1; 3407 } 3408 3409 int wlan_cfg_num_nss_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3410 { 3411 return 1; 3412 } 3413 3414 #else 3415 3416 #if defined(IPA_OFFLOAD) && defined(TX_MULTI_TCL) 3417 int wlan_cfg_num_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3418 { 3419 if (!cfg->ipa_enabled) 3420 return cfg->num_tcl_data_rings; 3421 3422 return 1; 3423 } 3424 3425 int wlan_cfg_num_nss_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3426 { 3427 if (!cfg->ipa_enabled) 3428 return cfg->num_nss_tcl_data_rings; 3429 3430 return 1; 3431 } 3432 #else 3433 int wlan_cfg_num_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3434 { 3435 return cfg->num_tcl_data_rings; 3436 } 3437 3438 int wlan_cfg_num_nss_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3439 { 3440 return cfg->num_nss_tcl_data_rings; 3441 } 3442 #endif 3443 #endif 3444 3445 int wlan_cfg_num_tx_comp_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3446 { 3447 return cfg->num_tx_comp_rings; 3448 } 3449 3450 int wlan_cfg_tx_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3451 { 3452 return cfg->tx_ring_size; 3453 } 3454 3455 int wlan_cfg_time_control_bp(struct wlan_cfg_dp_soc_ctxt *cfg) 3456 { 3457 return cfg->time_control_bp; 3458 } 3459 3460 int wlan_cfg_tx_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3461 { 3462 return cfg->tx_comp_ring_size; 3463 } 3464 3465 int wlan_cfg_per_pdev_rx_ring(struct wlan_cfg_dp_soc_ctxt *cfg) 3466 { 3467 return cfg->per_pdev_rx_ring; 3468 } 3469 3470 int wlan_cfg_num_reo_dest_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3471 { 3472 return cfg->num_reo_dest_rings; 3473 } 3474 3475 int wlan_cfg_num_nss_reo_dest_rings(struct wlan_cfg_dp_soc_ctxt *cfg) 3476 { 3477 return cfg->num_nss_reo_dest_rings; 3478 } 3479 3480 int wlan_cfg_pkt_type(struct wlan_cfg_dp_soc_ctxt *cfg) 3481 { 3482 return cfg->htt_packet_type; /*htt_pkt_type_ethernet*/ 3483 } 3484 3485 int wlan_cfg_get_num_tx_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg) 3486 { 3487 return cfg->num_tx_desc_pool; 3488 } 3489 3490 void wlan_cfg_set_num_tx_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg, int num_pool) 3491 { 3492 cfg->num_tx_desc_pool = num_pool; 3493 } 3494 3495 int wlan_cfg_get_num_tx_ext_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg) 3496 { 3497 return cfg->num_tx_ext_desc_pool; 3498 } 3499 3500 void wlan_cfg_set_num_tx_ext_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg, int num_pool) 3501 { 3502 cfg->num_tx_ext_desc_pool = num_pool; 3503 } 3504 3505 int wlan_cfg_get_reo_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3506 { 3507 return cfg->reo_dst_ring_size; 3508 } 3509 3510 void wlan_cfg_set_reo_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg, 3511 int reo_dst_ring_size) 3512 { 3513 cfg->reo_dst_ring_size = reo_dst_ring_size; 3514 } 3515 3516 void wlan_cfg_set_raw_mode_war(struct wlan_cfg_dp_soc_ctxt *cfg, 3517 bool raw_mode_war) 3518 { 3519 cfg->raw_mode_war = raw_mode_war; 3520 } 3521 3522 bool wlan_cfg_get_raw_mode_war(struct wlan_cfg_dp_soc_ctxt *cfg) 3523 { 3524 return cfg->raw_mode_war; 3525 } 3526 3527 int wlan_cfg_get_num_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3528 { 3529 return cfg->num_tx_desc; 3530 } 3531 3532 int wlan_cfg_get_num_tx_spl_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3533 { 3534 return cfg->num_tx_spl_desc; 3535 } 3536 3537 void wlan_cfg_set_num_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg, int num_desc) 3538 { 3539 cfg->num_tx_desc = num_desc; 3540 } 3541 3542 int wlan_cfg_get_min_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3543 { 3544 return cfg->min_tx_desc; 3545 } 3546 3547 int wlan_cfg_get_num_tx_ext_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 3548 { 3549 return cfg->num_tx_ext_desc; 3550 } 3551 3552 void wlan_cfg_set_num_tx_ext_desc(struct wlan_cfg_dp_soc_ctxt *cfg, int num_ext_desc) 3553 { 3554 cfg->num_tx_ext_desc = num_ext_desc; 3555 } 3556 3557 uint32_t wlan_cfg_max_peer_id(struct wlan_cfg_dp_soc_ctxt *cfg) 3558 { 3559 /* TODO: This should be calculated based on target capabilities */ 3560 return cfg->max_peer_id; 3561 } 3562 3563 int wlan_cfg_get_dma_mon_buf_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3564 { 3565 return cfg->dma_mon_buf_ring_size; 3566 } 3567 3568 qdf_export_symbol(wlan_cfg_get_dma_mon_buf_ring_size); 3569 3570 int wlan_cfg_get_dma_rx_mon_dest_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3571 { 3572 return cfg->dma_rx_mon_dest_ring_size; 3573 } 3574 3575 qdf_export_symbol(wlan_cfg_get_dma_rx_mon_dest_ring_size); 3576 3577 int wlan_cfg_get_dma_tx_mon_dest_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3578 { 3579 return cfg->dma_tx_mon_dest_ring_size; 3580 } 3581 3582 qdf_export_symbol(wlan_cfg_get_dma_tx_mon_dest_ring_size); 3583 3584 int wlan_cfg_get_dma_mon_stat_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3585 { 3586 return cfg->dma_mon_status_ring_size; 3587 } 3588 3589 qdf_export_symbol(wlan_cfg_get_dma_mon_stat_ring_size); 3590 3591 int 3592 wlan_cfg_get_dma_mon_desc_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3593 { 3594 return cfg->rxdma_monitor_desc_ring; 3595 } 3596 3597 qdf_export_symbol(wlan_cfg_get_dma_mon_desc_ring_size); 3598 3599 int wlan_cfg_get_rx_dma_buf_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg) 3600 { 3601 return cfg->rx_dma_buf_ring_size; 3602 } 3603 3604 int wlan_cfg_get_num_mac_rings(struct wlan_cfg_dp_pdev_ctxt *cfg) 3605 { 3606 return cfg->num_mac_rings; 3607 } 3608 3609 qdf_export_symbol(wlan_cfg_get_num_mac_rings); 3610 3611 bool wlan_cfg_is_gro_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3612 { 3613 return cfg->gro_enabled; 3614 } 3615 3616 bool wlan_cfg_is_lro_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3617 { 3618 return cfg->lro_enabled; 3619 } 3620 3621 bool wlan_cfg_is_ipa_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3622 { 3623 return cfg->ipa_enabled; 3624 } 3625 3626 void wlan_cfg_set_rx_hash(struct wlan_cfg_dp_soc_ctxt *cfg, bool val) 3627 { 3628 cfg->rx_hash = val; 3629 } 3630 3631 bool wlan_cfg_is_rx_hash_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3632 { 3633 return cfg->rx_hash; 3634 } 3635 3636 int wlan_cfg_get_dp_pdev_nss_enabled(struct wlan_cfg_dp_pdev_ctxt *cfg) 3637 { 3638 return cfg->nss_enabled; 3639 } 3640 3641 void wlan_cfg_set_dp_pdev_nss_enabled(struct wlan_cfg_dp_pdev_ctxt *cfg, int nss_enabled) 3642 { 3643 cfg->nss_enabled = nss_enabled; 3644 } 3645 3646 int wlan_cfg_get_dp_soc_nss_cfg(struct wlan_cfg_dp_soc_ctxt *cfg) 3647 { 3648 return cfg->nss_cfg; 3649 } 3650 3651 void wlan_cfg_set_dp_soc_nss_cfg(struct wlan_cfg_dp_soc_ctxt *cfg, int nss_cfg) 3652 { 3653 cfg->nss_cfg = nss_cfg; 3654 if (cfg->nss_cfg) 3655 cfg->tx_comp_ring_size = cfg->tx_comp_ring_size_nss; 3656 } 3657 3658 int wlan_cfg_get_int_batch_threshold_ppe2tcl(struct wlan_cfg_dp_soc_ctxt *cfg) 3659 { 3660 return cfg->int_batch_threshold_ppe2tcl; 3661 } 3662 3663 int wlan_cfg_get_int_timer_threshold_ppe2tcl(struct wlan_cfg_dp_soc_ctxt *cfg) 3664 { 3665 return cfg->int_timer_threshold_ppe2tcl; 3666 } 3667 3668 int wlan_cfg_get_int_batch_threshold_tx(struct wlan_cfg_dp_soc_ctxt *cfg) 3669 { 3670 return cfg->int_batch_threshold_tx; 3671 } 3672 3673 int wlan_cfg_get_int_timer_threshold_tx(struct wlan_cfg_dp_soc_ctxt *cfg) 3674 { 3675 return cfg->int_timer_threshold_tx; 3676 } 3677 3678 int wlan_cfg_get_int_batch_threshold_rx(struct wlan_cfg_dp_soc_ctxt *cfg) 3679 { 3680 return cfg->int_batch_threshold_rx; 3681 } 3682 3683 int wlan_cfg_get_int_timer_threshold_rx(struct wlan_cfg_dp_soc_ctxt *cfg) 3684 { 3685 return cfg->int_timer_threshold_rx; 3686 } 3687 3688 int wlan_cfg_get_int_batch_threshold_other(struct wlan_cfg_dp_soc_ctxt *cfg) 3689 { 3690 return cfg->int_batch_threshold_other; 3691 } 3692 3693 int wlan_cfg_get_int_timer_threshold_other(struct wlan_cfg_dp_soc_ctxt *cfg) 3694 { 3695 return cfg->int_timer_threshold_other; 3696 } 3697 3698 int wlan_cfg_get_int_timer_threshold_mon(struct wlan_cfg_dp_soc_ctxt *cfg) 3699 { 3700 return cfg->int_timer_threshold_mon; 3701 } 3702 3703 int wlan_cfg_get_p2p_checksum_offload(struct wlan_cfg_dp_soc_ctxt *cfg) 3704 { 3705 return cfg->p2p_tcp_udp_checksumoffload; 3706 } 3707 3708 int wlan_cfg_get_nan_checksum_offload(struct wlan_cfg_dp_soc_ctxt *cfg) 3709 { 3710 return cfg->nan_tcp_udp_checksumoffload; 3711 } 3712 3713 int wlan_cfg_get_checksum_offload(struct wlan_cfg_dp_soc_ctxt *cfg) 3714 { 3715 return cfg->tcp_udp_checksumoffload; 3716 } 3717 3718 int wlan_cfg_get_rx_defrag_min_timeout(struct wlan_cfg_dp_soc_ctxt *cfg) 3719 { 3720 return cfg->rx_defrag_min_timeout; 3721 } 3722 3723 int wlan_cfg_get_defrag_timeout_check(struct wlan_cfg_dp_soc_ctxt *cfg) 3724 { 3725 return cfg->defrag_timeout_check; 3726 } 3727 3728 int 3729 wlan_cfg_get_dp_soc_wbm_release_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3730 { 3731 return cfg->wbm_release_ring; 3732 } 3733 3734 int 3735 wlan_cfg_get_dp_soc_tcl_cmd_credit_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3736 { 3737 return cfg->tcl_cmd_credit_ring; 3738 } 3739 3740 int 3741 wlan_cfg_get_dp_soc_tcl_status_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3742 { 3743 return cfg->tcl_status_ring; 3744 } 3745 3746 int 3747 wlan_cfg_get_dp_soc_reo_reinject_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3748 { 3749 return cfg->reo_reinject_ring; 3750 } 3751 3752 int 3753 wlan_cfg_get_dp_soc_rx_release_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3754 { 3755 return cfg->rx_release_ring; 3756 } 3757 3758 int 3759 wlan_cfg_get_dp_soc_reo_exception_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3760 { 3761 return cfg->reo_exception_ring; 3762 } 3763 3764 int 3765 wlan_cfg_get_dp_soc_reo_cmd_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3766 { 3767 return cfg->reo_cmd_ring; 3768 } 3769 3770 int 3771 wlan_cfg_get_dp_soc_reo_status_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3772 { 3773 return cfg->reo_status_ring; 3774 } 3775 3776 int 3777 wlan_cfg_get_dp_soc_rxdma_refill_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3778 { 3779 return cfg->rxdma_refill_ring; 3780 } 3781 3782 bool 3783 wlan_cfg_get_dp_soc_rxdma_refill_lt_disable(struct wlan_cfg_dp_soc_ctxt *cfg) 3784 { 3785 return cfg->rxdma_refill_lt_disable; 3786 } 3787 3788 int 3789 wlan_cfg_get_dp_soc_tx_desc_limit_0(struct wlan_cfg_dp_soc_ctxt *cfg) 3790 { 3791 return cfg->tx_desc_limit_0; 3792 } 3793 3794 int 3795 wlan_cfg_get_dp_soc_tx_desc_limit_1(struct wlan_cfg_dp_soc_ctxt *cfg) 3796 { 3797 return cfg->tx_desc_limit_1; 3798 } 3799 3800 int 3801 wlan_cfg_get_dp_soc_tx_desc_limit_2(struct wlan_cfg_dp_soc_ctxt *cfg) 3802 { 3803 return cfg->tx_desc_limit_2; 3804 } 3805 3806 int 3807 wlan_cfg_get_dp_soc_tx_device_limit(struct wlan_cfg_dp_soc_ctxt *cfg) 3808 { 3809 return cfg->tx_device_limit; 3810 } 3811 3812 int 3813 wlan_cfg_get_dp_soc_tx_spl_device_limit(struct wlan_cfg_dp_soc_ctxt *cfg) 3814 { 3815 return cfg->tx_spl_device_limit; 3816 } 3817 3818 int 3819 wlan_cfg_get_dp_soc_tx_sw_internode_queue(struct wlan_cfg_dp_soc_ctxt *cfg) 3820 { 3821 return cfg->tx_sw_internode_queue; 3822 } 3823 3824 int 3825 wlan_cfg_get_dp_soc_rxdma_err_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3826 { 3827 return cfg->rxdma_err_dst_ring; 3828 } 3829 3830 int 3831 wlan_cfg_get_dp_soc_rx_sw_desc_weight(struct wlan_cfg_dp_soc_ctxt *cfg) 3832 { 3833 return cfg->rx_sw_desc_weight; 3834 } 3835 3836 qdf_export_symbol(wlan_cfg_get_dp_soc_rx_sw_desc_weight); 3837 3838 int 3839 wlan_cfg_get_dp_soc_rx_sw_desc_num(struct wlan_cfg_dp_soc_ctxt *cfg) 3840 { 3841 return cfg->rx_sw_desc_num; 3842 } 3843 3844 uint32_t 3845 wlan_cfg_get_reo_rings_mapping(struct wlan_cfg_dp_soc_ctxt *cfg) 3846 { 3847 return cfg->reo_rings_mapping; 3848 } 3849 3850 bool 3851 wlan_cfg_get_dp_caps(struct wlan_cfg_dp_soc_ctxt *cfg, 3852 enum cdp_capabilities dp_caps) 3853 { 3854 switch (dp_caps) { 3855 case CDP_CFG_DP_TSO: 3856 return cfg->tso_enabled; 3857 case CDP_CFG_DP_LRO: 3858 return cfg->lro_enabled; 3859 case CDP_CFG_DP_SG: 3860 return cfg->sg_enabled; 3861 case CDP_CFG_DP_GRO: 3862 return cfg->gro_enabled; 3863 case CDP_CFG_DP_OL_TX_CSUM: 3864 return cfg->ol_tx_csum_enabled; 3865 case CDP_CFG_DP_OL_RX_CSUM: 3866 return cfg->ol_rx_csum_enabled; 3867 case CDP_CFG_DP_RAWMODE: 3868 return cfg->rawmode_enabled; 3869 case CDP_CFG_DP_PEER_FLOW_CTRL: 3870 return cfg->peer_flow_ctrl_enabled; 3871 case CDP_CFG_DP_MARK_NOTIFY_FRAME_SUPPORT: 3872 return cfg->notify_frame_support; 3873 default: 3874 return false; 3875 } 3876 } 3877 3878 void wlan_cfg_set_tso_desc_attach_defer(struct wlan_cfg_dp_soc_ctxt *cfg, 3879 bool val) 3880 { 3881 cfg->is_tso_desc_attach_defer = val; 3882 } 3883 3884 bool wlan_cfg_is_tso_desc_attach_defer(struct wlan_cfg_dp_soc_ctxt *cfg) 3885 { 3886 return cfg->is_tso_desc_attach_defer; 3887 } 3888 3889 #ifdef QCA_LL_TX_FLOW_CONTROL_V2 3890 /** 3891 * wlan_cfg_get_tx_flow_stop_queue_th() - Get flow control stop threshold 3892 * @cfg: config context 3893 * 3894 * Return: stop threshold 3895 */ 3896 int wlan_cfg_get_tx_flow_stop_queue_th(struct wlan_cfg_dp_soc_ctxt *cfg) 3897 { 3898 return cfg->tx_flow_stop_queue_threshold; 3899 } 3900 3901 /** 3902 * wlan_cfg_get_tx_flow_start_queue_offset() - Get flow control start offset 3903 * for TX to resume 3904 * @cfg: config context 3905 * 3906 * Return: stop threshold 3907 */ 3908 int wlan_cfg_get_tx_flow_start_queue_offset(struct wlan_cfg_dp_soc_ctxt *cfg) 3909 { 3910 return cfg->tx_flow_start_queue_offset; 3911 } 3912 #endif /* QCA_LL_TX_FLOW_CONTROL_V2 */ 3913 3914 void wlan_cfg_set_rx_flow_tag_enabled(struct wlan_cfg_dp_soc_ctxt *cfg, 3915 bool val) 3916 { 3917 cfg->is_rx_flow_tag_enabled = val; 3918 } 3919 3920 uint8_t *wlan_cfg_rx_fst_get_hash_key(struct wlan_cfg_dp_soc_ctxt *cfg) 3921 { 3922 return cfg->rx_toeplitz_hash_key; 3923 } 3924 3925 uint8_t wlan_cfg_rx_fst_get_max_search(struct wlan_cfg_dp_soc_ctxt *cfg) 3926 { 3927 return cfg->rx_flow_max_search; 3928 } 3929 3930 bool wlan_cfg_is_rx_flow_tag_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3931 { 3932 return cfg->is_rx_flow_tag_enabled; 3933 } 3934 3935 qdf_export_symbol(wlan_cfg_is_rx_flow_tag_enabled); 3936 3937 #ifdef WLAN_SUPPORT_RX_FISA 3938 bool wlan_cfg_is_rx_fisa_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3939 { 3940 return (bool)(cfg->is_rx_fisa_enabled); 3941 } 3942 3943 bool wlan_cfg_is_rx_fisa_lru_del_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3944 { 3945 return cfg->is_rx_fisa_lru_del_enabled; 3946 } 3947 #else 3948 bool wlan_cfg_is_rx_fisa_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3949 { 3950 return false; 3951 } 3952 3953 bool wlan_cfg_is_rx_fisa_lru_del_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3954 { 3955 return false; 3956 } 3957 #endif 3958 3959 bool wlan_cfg_is_poll_mode_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3960 { 3961 return (bool)(cfg->is_poll_mode_enabled); 3962 } 3963 3964 void 3965 wlan_cfg_set_rx_flow_search_table_per_pdev(struct wlan_cfg_dp_soc_ctxt *cfg, 3966 bool val) 3967 { 3968 cfg->is_rx_flow_search_table_per_pdev = val; 3969 } 3970 3971 bool wlan_cfg_is_rx_flow_search_table_per_pdev(struct wlan_cfg_dp_soc_ctxt *cfg) 3972 { 3973 return cfg->is_rx_flow_search_table_per_pdev; 3974 } 3975 3976 void wlan_cfg_set_rx_flow_search_table_size(struct wlan_cfg_dp_soc_ctxt *cfg, 3977 uint16_t val) 3978 { 3979 cfg->rx_flow_search_table_size = val; 3980 } 3981 3982 uint16_t 3983 wlan_cfg_get_rx_flow_search_table_size(struct wlan_cfg_dp_soc_ctxt *cfg) 3984 { 3985 return cfg->rx_flow_search_table_size; 3986 } 3987 3988 void 3989 wlan_cfg_set_rx_mon_protocol_flow_tag_enabled(struct wlan_cfg_dp_soc_ctxt *cfg, 3990 bool val) 3991 { 3992 cfg->is_rx_mon_protocol_flow_tag_enabled = val; 3993 } 3994 3995 bool 3996 wlan_cfg_is_rx_mon_protocol_flow_tag_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 3997 { 3998 return cfg->is_rx_mon_protocol_flow_tag_enabled; 3999 } 4000 4001 qdf_export_symbol(wlan_cfg_is_rx_mon_protocol_flow_tag_enabled); 4002 4003 void 4004 wlan_cfg_set_tx_per_pkt_vdev_id_check(struct wlan_cfg_dp_soc_ctxt *cfg, 4005 bool val) 4006 { 4007 cfg->tx_per_pkt_vdev_id_check = val; 4008 } 4009 4010 bool 4011 wlan_cfg_is_tx_per_pkt_vdev_id_check_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4012 { 4013 return cfg->tx_per_pkt_vdev_id_check; 4014 } 4015 4016 void 4017 wlan_cfg_set_peer_ext_stats(struct wlan_cfg_dp_soc_ctxt *cfg, 4018 bool val) 4019 { 4020 cfg->pext_stats_enabled = val; 4021 } 4022 4023 void 4024 wlan_cfg_set_peer_jitter_stats(struct wlan_cfg_dp_soc_ctxt *cfg, 4025 bool val) 4026 { 4027 cfg->jitter_stats_enabled = val; 4028 } 4029 4030 bool 4031 wlan_cfg_is_peer_ext_stats_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4032 { 4033 return cfg->pext_stats_enabled; 4034 } 4035 4036 bool wlan_cfg_is_fst_in_cmem_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4037 { 4038 return cfg->fst_in_cmem; 4039 } 4040 4041 bool wlan_cfg_is_peer_jitter_stats_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4042 { 4043 return cfg->jitter_stats_enabled; 4044 } 4045 4046 #ifdef WLAN_FEATURE_RX_PREALLOC_BUFFER_POOL 4047 bool wlan_cfg_is_rx_buffer_pool_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4048 { 4049 return cfg->is_rx_buff_pool_enabled; 4050 } 4051 4052 bool wlan_cfg_is_rx_refill_buffer_pool_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4053 { 4054 return cfg->is_rx_refill_buff_pool_enabled; 4055 } 4056 #else 4057 bool wlan_cfg_is_rx_buffer_pool_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4058 { 4059 return false; 4060 } 4061 4062 bool wlan_cfg_is_rx_refill_buffer_pool_enabled( 4063 struct wlan_cfg_dp_soc_ctxt *cfg) 4064 { 4065 return false; 4066 } 4067 #endif /* WLAN_FEATURE_RX_PREALLOC_BUFFER_POOL */ 4068 4069 #ifdef WLAN_DP_FEATURE_SW_LATENCY_MGR 4070 bool wlan_cfg_is_swlm_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4071 { 4072 return (bool)(cfg->is_swlm_enabled); 4073 } 4074 #else 4075 bool wlan_cfg_is_swlm_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4076 { 4077 return false; 4078 } 4079 #endif 4080 uint8_t wlan_cfg_radio0_default_reo_get(struct wlan_cfg_dp_soc_ctxt *cfg) 4081 { 4082 return cfg->radio0_rx_default_reo; 4083 } 4084 4085 uint8_t wlan_cfg_radio1_default_reo_get(struct wlan_cfg_dp_soc_ctxt *cfg) 4086 { 4087 return cfg->radio1_rx_default_reo; 4088 } 4089 4090 uint8_t wlan_cfg_radio2_default_reo_get(struct wlan_cfg_dp_soc_ctxt *cfg) 4091 { 4092 return cfg->radio2_rx_default_reo; 4093 } 4094 4095 void wlan_cfg_set_rxdma1_enable(struct wlan_cfg_dp_soc_ctxt *cfg) 4096 { 4097 cfg->rxdma1_enable = true; 4098 } 4099 4100 void 4101 wlan_cfg_set_delay_mon_replenish(struct wlan_cfg_dp_soc_ctxt *cfg, 4102 bool val) 4103 { 4104 cfg->delay_mon_replenish = val; 4105 } 4106 4107 bool 4108 wlan_cfg_is_delay_mon_replenish(struct wlan_cfg_dp_soc_ctxt *cfg) 4109 { 4110 return cfg->delay_mon_replenish; 4111 } 4112 4113 qdf_export_symbol(wlan_cfg_is_delay_mon_replenish); 4114 4115 void wlan_cfg_dp_soc_ctx_dump(struct wlan_cfg_dp_soc_ctxt *cfg) 4116 { 4117 dp_info("DP CFG SoC ctx: delay_mon_replenish = %d,", 4118 cfg->delay_mon_replenish); 4119 dp_info("reo_dst_ring_size = %d, delayed_replenish_entries = %d", 4120 cfg->reo_dst_ring_size, cfg->delayed_replenish_entries); 4121 } 4122 4123 #ifdef IPA_OFFLOAD 4124 uint32_t wlan_cfg_ipa_tx_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4125 { 4126 return cfg->ipa_tx_ring_size; 4127 } 4128 4129 uint32_t wlan_cfg_ipa_tx_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4130 { 4131 return cfg->ipa_tx_comp_ring_size; 4132 } 4133 4134 #ifdef IPA_WDI3_TX_TWO_PIPES 4135 int wlan_cfg_ipa_tx_alt_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4136 { 4137 return cfg->ipa_tx_alt_ring_size; 4138 } 4139 4140 int wlan_cfg_ipa_tx_alt_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4141 { 4142 return cfg->ipa_tx_alt_comp_ring_size; 4143 } 4144 4145 #else 4146 int wlan_cfg_ipa_tx_alt_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4147 { 4148 return cfg->ipa_tx_ring_size; 4149 } 4150 4151 int wlan_cfg_ipa_tx_alt_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4152 { 4153 return cfg->ipa_tx_comp_ring_size; 4154 } 4155 #endif 4156 #endif 4157 4158 #ifdef WLAN_SUPPORT_PPEDS 4159 bool 4160 wlan_cfg_get_dp_soc_is_ppeds_enabled(struct wlan_cfg_dp_soc_ctxt *cfg) 4161 { 4162 return cfg->ppeds_enable; 4163 } 4164 4165 int 4166 wlan_cfg_get_dp_soc_reo2ppe_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4167 { 4168 return cfg->reo2ppe_ring; 4169 } 4170 4171 int 4172 wlan_cfg_get_dp_soc_ppe2tcl_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4173 { 4174 return cfg->ppe2tcl_ring; 4175 } 4176 4177 int 4178 wlan_cfg_get_dp_soc_ppeds_num_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg) 4179 { 4180 return cfg->ppeds_num_tx_desc; 4181 } 4182 4183 int 4184 wlan_cfg_get_dp_soc_ppeds_tx_comp_napi_budget(struct wlan_cfg_dp_soc_ctxt *cfg) 4185 { 4186 return cfg->ppeds_tx_comp_napi_budget; 4187 } 4188 #endif 4189 4190 void 4191 wlan_cfg_get_prealloc_cfg(struct cdp_ctrl_objmgr_psoc *ctrl_psoc, 4192 struct wlan_dp_prealloc_cfg *cfg) 4193 { 4194 if (!ctrl_psoc || !cfg) 4195 return; 4196 4197 cfg->num_reo_dst_ring_entries = cfg_get(ctrl_psoc, 4198 CFG_DP_RX_DESTINATION_RING); 4199 cfg->num_tx_ring_entries = cfg_get(ctrl_psoc, CFG_DP_TX_RING_SIZE); 4200 cfg->num_tx_comp_ring_entries = cfg_get(ctrl_psoc, 4201 CFG_DP_TX_COMPL_RING_SIZE); 4202 cfg->num_wbm_rel_ring_entries = cfg_get(ctrl_psoc, 4203 CFG_DP_WBM_RELEASE_RING); 4204 cfg->num_rxdma_err_dst_ring_entries = cfg_get(ctrl_psoc, 4205 CFG_DP_RXDMA_ERR_DST_RING); 4206 cfg->num_reo_exception_ring_entries = cfg_get(ctrl_psoc, 4207 CFG_DP_REO_EXCEPTION_RING); 4208 cfg->num_tx_desc = cfg_get(ctrl_psoc, CFG_DP_TX_DESC); 4209 cfg->num_tx_ext_desc = cfg_get(ctrl_psoc, CFG_DP_TX_EXT_DESC); 4210 cfg->num_rxdma_buf_ring_entries = cfg_get(ctrl_psoc, 4211 CFG_DP_RXDMA_BUF_RING); 4212 cfg->num_rxdma_refill_ring_entries = cfg_get(ctrl_psoc, 4213 CFG_DP_RXDMA_REFILL_RING); 4214 cfg->num_reo_status_ring_entries = cfg_get(ctrl_psoc, 4215 CFG_DP_REO_STATUS_RING); 4216 cfg->num_mon_status_ring_entries = cfg_get(ctrl_psoc, 4217 CFG_DP_RXDMA_MONITOR_STATUS_RING); 4218 } 4219 4220 #ifdef WLAN_FEATURE_PKT_CAPTURE_V2 4221 uint32_t wlan_cfg_get_pkt_capture_mode(struct wlan_cfg_dp_soc_ctxt *cfg) 4222 { 4223 return cfg->pkt_capture_mode; 4224 } 4225 #endif 4226 4227 uint32_t 4228 wlan_cfg_get_dp_soc_rx_mon_buf_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4229 { 4230 return cfg->rx_mon_buf_ring_size; 4231 } 4232 4233 qdf_export_symbol(wlan_cfg_get_dp_soc_rx_mon_buf_ring_size); 4234 4235 uint32_t 4236 wlan_cfg_get_dp_soc_tx_mon_buf_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg) 4237 { 4238 return cfg->tx_mon_buf_ring_size; 4239 } 4240 4241 qdf_export_symbol(wlan_cfg_get_dp_soc_tx_mon_buf_ring_size); 4242 4243 uint8_t 4244 wlan_cfg_get_rx_rel_ring_id(struct wlan_cfg_dp_soc_ctxt *cfg) 4245 { 4246 return cfg->rx_rel_wbm2sw_ring_id; 4247 } 4248 4249 void 4250 wlan_cfg_set_rx_rel_ring_id(struct wlan_cfg_dp_soc_ctxt *cfg, 4251 uint8_t wbm2sw_ring_id) 4252 { 4253 cfg->rx_rel_wbm2sw_ring_id = wbm2sw_ring_id; 4254 } 4255 4256 #if defined(WLAN_FEATURE_11BE_MLO) && defined(WLAN_MLO_MULTI_CHIP) 4257 uint8_t 4258 wlan_cfg_mlo_rx_ring_map_get(struct wlan_cfg_dp_soc_ctxt *cfg) 4259 { 4260 return cfg->mlo_chip_rx_ring_map; 4261 } 4262 #endif 4263 4264 #ifdef QCA_VDEV_STATS_HW_OFFLOAD_SUPPORT 4265 bool 4266 wlan_cfg_get_vdev_stats_hw_offload_config(struct wlan_cfg_dp_soc_ctxt *cfg) 4267 { 4268 return cfg->vdev_stats_hw_offload_config; 4269 } 4270 4271 int wlan_cfg_get_vdev_stats_hw_offload_timer(struct wlan_cfg_dp_soc_ctxt *cfg) 4272 { 4273 return cfg->vdev_stats_hw_offload_timer; 4274 } 4275 4276 void 4277 wlan_cfg_set_vdev_stats_hw_offload_config(struct wlan_cfg_dp_soc_ctxt *cfg, 4278 bool val) 4279 { 4280 cfg->vdev_stats_hw_offload_config = val; 4281 } 4282 #else 4283 bool 4284 wlan_cfg_get_vdev_stats_hw_offload_config(struct wlan_cfg_dp_soc_ctxt *cfg) 4285 { 4286 return false; 4287 } 4288 4289 int wlan_cfg_get_vdev_stats_hw_offload_timer(struct wlan_cfg_dp_soc_ctxt *cfg) 4290 { 4291 return 0; 4292 } 4293 4294 void 4295 wlan_cfg_set_vdev_stats_hw_offload_config(struct wlan_cfg_dp_soc_ctxt *cfg, 4296 bool val) 4297 {} 4298 #endif 4299 4300 #ifdef CONFIG_SAWF 4301 bool wlan_cfg_get_sawf_config(struct wlan_cfg_dp_soc_ctxt *cfg) 4302 { 4303 return cfg->sawf_enabled; 4304 } 4305 4306 void wlan_cfg_set_sawf_config(struct wlan_cfg_dp_soc_ctxt *cfg, bool val) 4307 { 4308 cfg->sawf_enabled = val; 4309 } 4310 #else 4311 bool wlan_cfg_get_sawf_config(struct wlan_cfg_dp_soc_ctxt *cfg) 4312 { 4313 return false; 4314 } 4315 4316 void wlan_cfg_set_sawf_config(struct wlan_cfg_dp_soc_ctxt *cfg, bool val) 4317 { 4318 } 4319 #endif 4320 4321 #ifdef CONFIG_BERYLLIUM 4322 int wlan_cfg_get_host2txmon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 4323 int context) 4324 { 4325 return cfg->int_host2txmon_ring_mask[context]; 4326 } 4327 4328 qdf_export_symbol(wlan_cfg_get_host2txmon_ring_mask); 4329 4330 void wlan_cfg_set_host2txmon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 4331 int context, int mask) 4332 { 4333 cfg->int_host2txmon_ring_mask[context] = mask; 4334 } 4335 #else 4336 int wlan_cfg_get_host2txmon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 4337 int context) 4338 { 4339 return 0; 4340 } 4341 4342 void wlan_cfg_set_host2txmon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, 4343 int context, int mask) 4344 { 4345 } 4346 #endif 4347 4348 qdf_export_symbol(wlan_cfg_set_host2txmon_ring_mask); 4349 4350 void wlan_cfg_set_txmon_hw_support(struct wlan_cfg_dp_soc_ctxt *cfg, 4351 bool txmon_hw_support) 4352 { 4353 cfg->txmon_hw_support = txmon_hw_support; 4354 } 4355 4356 bool wlan_cfg_get_txmon_hw_support(struct wlan_cfg_dp_soc_ctxt *cfg) 4357 { 4358 return cfg->txmon_hw_support; 4359 } 4360 4361 qdf_export_symbol(wlan_cfg_get_txmon_hw_support); 4362 4363 uint8_t wlan_cfg_get_napi_scale_factor(struct wlan_cfg_dp_soc_ctxt *cfg) 4364 { 4365 return cfg->napi_scale_factor; 4366 } 4367 4368 bool wlan_cfg_get_txmon_sw_peer_filtering(struct wlan_cfg_dp_soc_ctxt *cfg) 4369 { 4370 return cfg->txmon_sw_peer_filtering; 4371 } 4372 4373 qdf_export_symbol(wlan_cfg_get_txmon_sw_peer_filtering); 4374