wlan_cfg.h 31 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039
  1. /*
  2. * Copyright (c) 2013-2019 The Linux Foundation. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for
  5. * any purpose with or without fee is hereby granted, provided that the
  6. * above copyright notice and this permission notice appear in all
  7. * copies.
  8. *
  9. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
  10. * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
  11. * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
  12. * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
  13. * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
  14. * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  15. * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  16. * PERFORMANCE OF THIS SOFTWARE.
  17. */
  18. #ifndef __WLAN_CFG_H
  19. #define __WLAN_CFG_H
  20. /*
  21. * Temporary place holders. These should come either from target config
  22. * or platform configuration
  23. */
  24. #if defined(WLAN_MAX_PDEVS) && (WLAN_MAX_PDEVS == 1)
  25. #define WLAN_CFG_DST_RING_CACHED_DESC 0
  26. #define MAX_PDEV_CNT 1
  27. #define WLAN_CFG_INT_NUM_CONTEXTS 7
  28. #define WLAN_CFG_RXDMA1_ENABLE 1
  29. /*
  30. * This mask defines how many transmit frames account for 1 NAPI work unit
  31. * 0 means each tx completion is 1 unit
  32. */
  33. #define DP_TX_NAPI_BUDGET_DIV_MASK 0
  34. /* PPDU Stats Configuration - Configure bitmask for enabling tx ppdu tlv's */
  35. #define DP_PPDU_TXLITE_STATS_BITMASK_CFG 0x1FFF
  36. #define NUM_RXDMA_RINGS_PER_PDEV 2
  37. #else
  38. #define WLAN_CFG_DST_RING_CACHED_DESC 1
  39. #define MAX_PDEV_CNT 3
  40. #define WLAN_CFG_INT_NUM_CONTEXTS 11
  41. #define NUM_RXDMA_RINGS_PER_PDEV 1
  42. #endif
  43. #define WLAN_CFG_INT_NUM_CONTEXTS_MAX 11
  44. /* Tx configuration */
  45. #define MAX_LINK_DESC_BANKS 8
  46. #define MAX_TXDESC_POOLS 4
  47. #define MAX_TCL_DATA_RINGS 4
  48. /* Rx configuration */
  49. #define MAX_RXDESC_POOLS 4
  50. #define MAX_REO_DEST_RINGS 4
  51. #define MAX_RX_MAC_RINGS 2
  52. /* DP process status */
  53. #if defined(MAX_PDEV_CNT) && (MAX_PDEV_CNT == 1)
  54. #define CONFIG_PROCESS_RX_STATUS 1
  55. #define CONFIG_PROCESS_TX_STATUS 1
  56. #else
  57. #define CONFIG_PROCESS_RX_STATUS 0
  58. #define CONFIG_PROCESS_TX_STATUS 0
  59. #endif
  60. /* Miscellaneous configuration */
  61. #define MAX_IDLE_SCATTER_BUFS 16
  62. #define DP_MAX_IRQ_PER_CONTEXT 12
  63. #define MAX_HTT_METADATA_LEN 32
  64. #define MAX_NUM_PEER_ID_PER_PEER 8
  65. #define DP_MAX_TIDS 17
  66. #define DP_NON_QOS_TID 16
  67. struct wlan_cfg_dp_pdev_ctxt;
  68. /**
  69. * struct wlan_srng_cfg - Per ring configuration parameters
  70. * @timer_threshold: Config to control interrupts based on timer duration
  71. * @batch_count_threshold: Config to control interrupts based on
  72. * number of packets in the ring
  73. * @low_threshold: Config to control low threshold interrupts for SRC rings
  74. */
  75. struct wlan_srng_cfg {
  76. uint32_t timer_threshold;
  77. uint32_t batch_count_threshold;
  78. uint32_t low_threshold;
  79. };
  80. /**
  81. * struct wlan_cfg_dp_soc_ctxt - Configuration parameters for SoC (core TxRx)
  82. * @num_int_ctxts: Number of NAPI/Interrupt contexts to be registered for DP
  83. * @max_clients: Maximum number of peers/stations supported by device
  84. * @max_alloc_size: Maximum allocation size for any dynamic memory
  85. * allocation request for this device
  86. * @per_pdev_tx_ring: 0: TCL ring is not mapped per radio
  87. * 1: Each TCL ring is mapped to one radio/pdev
  88. * @num_tcl_data_rings: Number of TCL Data rings supported by device
  89. * @per_pdev_rx_ring: 0: REO ring is not mapped per radio
  90. * 1: Each REO ring is mapped to one radio/pdev
  91. * @num_tx_desc_pool: Number of Tx Descriptor pools
  92. * @num_tx_ext_desc_pool: Number of Tx MSDU extension Descriptor pools
  93. * @num_tx_desc: Number of Tx Descriptors per pool
  94. * @min_tx_desc: Minimum number of Tx Descriptors per pool
  95. * @num_tx_ext_desc: Number of Tx MSDU extension Descriptors per pool
  96. * @max_peer_id: Maximum value of peer id that FW can assign for a client
  97. * @htt_packet_type: Default 802.11 encapsulation type for any VAP created
  98. * @int_tx_ring_mask: Bitmap of Tx interrupts mapped to each NAPI/Intr context
  99. * @int_rx_ring_mask: Bitmap of Rx interrupts mapped to each NAPI/Intr context
  100. * @int_rx_mon_ring_mask: Bitmap of Rx monitor ring interrupts mapped to each
  101. * NAPI/Intr context
  102. * @int_rx_err_ring_mask: Bitmap of Rx err ring interrupts mapped to each
  103. * NAPI/Intr context
  104. * @int_wbm_rel_ring_mask: Bitmap of wbm rel ring interrupts mapped to each
  105. * NAPI/Intr context
  106. * @int_reo_status_ring_mask: Bitmap of reo status ring interrupts mapped to
  107. * each NAPI/Intr context
  108. * @int_ce_ring_mask: Bitmap of CE interrupts mapped to each NAPI/Intr context
  109. * @lro_enabled: enable/disable lro feature
  110. * @rx_hash: Enable hash based steering of rx packets
  111. * @tso_enabled: enable/disable tso feature
  112. * @lro_enabled: enable/disable LRO feature
  113. * @sg_enabled: enable disable scatter gather feature
  114. * @gro_enabled: enable disable GRO feature
  115. * @ipa_enabled: Flag indicating if IPA is enabled
  116. * @ol_tx_csum_enabled: Flag indicating if TX csum is enabled
  117. * @ol_rx_csum_enabled: Flag indicating if Rx csum is enabled
  118. * @rawmode_enabled: Flag indicating if RAW mode is enabled
  119. * @peer_flow_ctrl_enabled: Flag indicating if peer flow control is enabled
  120. * @napi_enabled: enable/disable interrupt mode for reaping tx and rx packets
  121. * @tcp_udp_checksumoffload: enable/disable checksum offload
  122. * @nss_cfg: nss configuration
  123. * @rx_defrag_min_timeout: rx defrag minimum timeout
  124. * @wbm_release_ring: wbm release ring size
  125. * @tcl_cmd_ring: tcl cmd ring size
  126. * @tcl_status_ring: tcl status ring size
  127. * @reo_reinject_ring: reo reinject ring
  128. * @rx_release_ring: rx release ring size
  129. * @reo_exception_ring: reo exception ring size
  130. * @reo_cmd_ring: reo cmd ring size
  131. * @reo_status_ring: reo status ting size
  132. * @rxdma_refill_ring: rxdma refill ring size
  133. * @rxdma_err_dst_ring: rxdma error detination ring size
  134. * @raw_mode_war: enable/disable raw mode war
  135. * @enable_data_stall_detection: flag to enable data stall detection
  136. * @disable_intra_bss_fwd: flag to disable intra bss forwarding
  137. * @rxdma1_enable: flag to indicate if rxdma1 is enabled
  138. * @tx_comp_loop_pkt_limit: Max # of packets to be processed in 1 tx comp loop
  139. * @rx_reap_loop_pkt_limit: Max # of packets to be processed in 1 rx reap loop
  140. * @rx_hp_oos_update_limit: Max # of HP OOS (out of sync) updates
  141. * @rx_enable_eol_data_check: flag to enable check for more ring data at end of
  142. * dp_rx_process loop
  143. * tx_comp_enable_eol_data_check: flag to enable/disable checking for more data
  144. * at end of tx_comp_handler loop.
  145. */
  146. struct wlan_cfg_dp_soc_ctxt {
  147. int num_int_ctxts;
  148. int max_clients;
  149. int max_alloc_size;
  150. int per_pdev_tx_ring;
  151. int num_tcl_data_rings;
  152. int per_pdev_rx_ring;
  153. int per_pdev_lmac_ring;
  154. int num_reo_dest_rings;
  155. int num_tx_desc_pool;
  156. int num_tx_ext_desc_pool;
  157. int num_tx_desc;
  158. int min_tx_desc;
  159. int num_tx_ext_desc;
  160. int max_peer_id;
  161. int htt_packet_type;
  162. int int_batch_threshold_tx;
  163. int int_timer_threshold_tx;
  164. int int_batch_threshold_rx;
  165. int int_timer_threshold_rx;
  166. int int_batch_threshold_other;
  167. int int_timer_threshold_other;
  168. int int_timer_threshold_mon;
  169. int tx_ring_size;
  170. int tx_comp_ring_size;
  171. int tx_comp_ring_size_nss;
  172. int int_tx_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  173. int int_rx_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  174. int int_rx_mon_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  175. int int_host2rxdma_mon_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  176. int int_rxdma2host_mon_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  177. int int_ce_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  178. int int_rx_err_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  179. int int_rx_wbm_rel_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  180. int int_reo_status_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  181. int int_rxdma2host_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  182. int int_host2rxdma_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS];
  183. int hw_macid[MAX_PDEV_CNT];
  184. int base_hw_macid;
  185. bool rx_hash;
  186. bool tso_enabled;
  187. bool lro_enabled;
  188. bool sg_enabled;
  189. bool gro_enabled;
  190. bool ipa_enabled;
  191. bool ol_tx_csum_enabled;
  192. bool ol_rx_csum_enabled;
  193. bool rawmode_enabled;
  194. bool peer_flow_ctrl_enabled;
  195. bool napi_enabled;
  196. bool tcp_udp_checksumoffload;
  197. bool defrag_timeout_check;
  198. int nss_cfg;
  199. uint32_t tx_flow_stop_queue_threshold;
  200. uint32_t tx_flow_start_queue_offset;
  201. int rx_defrag_min_timeout;
  202. int reo_dst_ring_size;
  203. int wbm_release_ring;
  204. int tcl_cmd_ring;
  205. int tcl_status_ring;
  206. int reo_reinject_ring;
  207. int rx_release_ring;
  208. int reo_exception_ring;
  209. int reo_cmd_ring;
  210. int reo_status_ring;
  211. int rxdma_refill_ring;
  212. int rxdma_err_dst_ring;
  213. uint32_t per_pkt_trace;
  214. bool raw_mode_war;
  215. bool enable_data_stall_detection;
  216. bool disable_intra_bss_fwd;
  217. bool rxdma1_enable;
  218. int max_ast_idx;
  219. #ifdef WLAN_FEATURE_RX_SOFTIRQ_TIME_LIMIT
  220. uint32_t tx_comp_loop_pkt_limit;
  221. uint32_t rx_reap_loop_pkt_limit;
  222. uint32_t rx_hp_oos_update_limit;
  223. bool rx_enable_eol_data_check;
  224. bool tx_comp_enable_eol_data_check;
  225. #endif /* WLAN_FEATURE_RX_SOFTIRQ_TIME_LIMIT */
  226. };
  227. /**
  228. * struct wlan_cfg_dp_pdev_ctxt - Configuration parameters for pdev (radio)
  229. * @rx_dma_buf_ring_size - Size of RxDMA buffer ring
  230. * @dma_mon_buf_ring_size - Size of RxDMA Monitor buffer ring
  231. * @dma_mon_dest_ring_size - Size of RxDMA Monitor Destination ring
  232. * @dma_mon_status_ring_size - Size of RxDMA Monitor Status ring
  233. * @rxdma_monitor_desc_ring - rxdma monitor desc ring size
  234. */
  235. struct wlan_cfg_dp_pdev_ctxt {
  236. int rx_dma_buf_ring_size;
  237. int dma_mon_buf_ring_size;
  238. int dma_mon_dest_ring_size;
  239. int dma_mon_status_ring_size;
  240. int rxdma_monitor_desc_ring;
  241. int num_mac_rings;
  242. int nss_enabled;
  243. };
  244. /**
  245. * wlan_cfg_soc_attach() - Attach configuration interface for SoC
  246. * @ctrl_obj - PSOC object
  247. *
  248. * Allocates context for Soc configuration parameters,
  249. * Read configuration information from device tree/ini file and
  250. * returns back handle
  251. *
  252. * Return: Handle to configuration context
  253. */
  254. struct wlan_cfg_dp_soc_ctxt *wlan_cfg_soc_attach(void *ctrl_obj);
  255. /**
  256. * wlan_cfg_soc_detach() - Detach soc configuration handle
  257. * @wlan_cfg_ctx: soc configuration handle
  258. *
  259. * De-allocates memory allocated for SoC configuration
  260. *
  261. * Return:none
  262. */
  263. void wlan_cfg_soc_detach(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  264. /**
  265. * wlan_cfg_pdev_attach() Attach configuration interface for pdev
  266. * @ctrl_obj - PSOC object
  267. *
  268. * Allocates context for pdev configuration parameters,
  269. * Read configuration information from device tree/ini file and
  270. * returns back handle
  271. *
  272. * Return: Handle to configuration context
  273. */
  274. struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_pdev_attach(void *ctrl_obj);
  275. /**
  276. * wlan_cfg_pdev_detach() Detach and free pdev configuration handle
  277. * @wlan_cfg_pdev_ctx - PDEV Configuration Handle
  278. *
  279. * Return: void
  280. */
  281. void wlan_cfg_pdev_detach(struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_pdev_ctx);
  282. void wlan_cfg_set_num_contexts(struct wlan_cfg_dp_soc_ctxt *cfg, int num);
  283. void wlan_cfg_set_tx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  284. int context, int mask);
  285. void wlan_cfg_set_rx_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  286. int context, int mask);
  287. void wlan_cfg_set_rx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  288. int context, int mask);
  289. void wlan_cfg_set_ce_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  290. int context, int mask);
  291. void wlan_cfg_set_rxbuf_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int context,
  292. int mask);
  293. void wlan_cfg_set_max_peer_id(struct wlan_cfg_dp_soc_ctxt *cfg, uint32_t val);
  294. void wlan_cfg_set_max_ast_idx(struct wlan_cfg_dp_soc_ctxt *cfg, uint32_t val);
  295. int wlan_cfg_get_max_ast_idx(struct wlan_cfg_dp_soc_ctxt *cfg);
  296. int wlan_cfg_set_rx_err_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  297. int context, int mask);
  298. int wlan_cfg_set_rx_wbm_rel_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  299. int context, int mask);
  300. int wlan_cfg_set_reo_status_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  301. int context, int mask);
  302. /**
  303. * wlan_cfg_get_num_contexts() - Number of interrupt contexts to be registered
  304. * @wlan_cfg_ctx - Configuration Handle
  305. *
  306. * For WIN, DP_NUM_INTERRUPT_CONTEXTS will be equal to number of CPU cores.
  307. * Each context (for linux it is a NAPI context) will have a tx_ring_mask,
  308. * rx_ring_mask ,and rx_monitor_ring mask to indicate the rings
  309. * that are processed by the handler.
  310. *
  311. * Return: num_contexts
  312. */
  313. int wlan_cfg_get_num_contexts(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  314. /**
  315. * wlan_cfg_get_tx_ring_mask() - Return Tx interrupt mask mapped to an
  316. * interrupt context
  317. * @wlan_cfg_ctx - Configuration Handle
  318. * @context - Numerical ID identifying the Interrupt/NAPI context
  319. *
  320. * Return: int_tx_ring_mask[context]
  321. */
  322. int wlan_cfg_get_tx_ring_mask(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx,
  323. int context);
  324. /**
  325. * wlan_cfg_get_rx_ring_mask() - Return Rx interrupt mask mapped to an
  326. * interrupt context
  327. * @wlan_cfg_ctx - Configuration Handle
  328. * @context - Numerical ID identifying the Interrupt/NAPI context
  329. *
  330. * Return: int_rx_ring_mask[context]
  331. */
  332. int wlan_cfg_get_rx_ring_mask(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx,
  333. int context);
  334. /**
  335. * wlan_cfg_get_rx_mon_ring_mask() - Return Rx monitor ring interrupt mask
  336. * mapped to an interrupt context
  337. * @wlan_cfg_ctx - Configuration Handle
  338. * @context - Numerical ID identifying the Interrupt/NAPI context
  339. *
  340. * Return: int_rx_mon_ring_mask[context]
  341. */
  342. int wlan_cfg_get_rx_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx,
  343. int context);
  344. /**
  345. * wlan_cfg_set_rxdma2host_ring_mask() - Set rxdma2host ring interrupt mask
  346. * for the given interrupt context
  347. * @wlan_cfg_ctx - Configuration Handle
  348. * @context - Numerical ID identifying the Interrupt/NAPI context
  349. *
  350. */
  351. void wlan_cfg_set_rxdma2host_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  352. int context, int mask);
  353. /**
  354. * wlan_cfg_get_rxdma2host_ring_mask() - Return rxdma2host ring interrupt mask
  355. * mapped to an interrupt context
  356. * @wlan_cfg_ctx - Configuration Handle
  357. * @context - Numerical ID identifying the Interrupt/NAPI context
  358. *
  359. * Return: int_rxdma2host_ring_mask[context]
  360. */
  361. int wlan_cfg_get_rxdma2host_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  362. int context);
  363. /**
  364. * wlan_cfg_set_host2rxdma_ring_mask() - Set host2rxdma ring interrupt mask
  365. * for the given interrupt context
  366. * @wlan_cfg_ctx - Configuration Handle
  367. * @context - Numerical ID identifying the Interrupt/NAPI context
  368. *
  369. */
  370. void wlan_cfg_set_host2rxdma_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  371. int context, int mask);
  372. /**
  373. * wlan_cfg_get_host2rxdma_ring_mask() - Return host2rxdma ring interrupt mask
  374. * mapped to an interrupt context
  375. * @wlan_cfg_ctx - Configuration Handle
  376. * @context - Numerical ID identifying the Interrupt/NAPI context
  377. *
  378. * Return: int_host2rxdma_ring_mask[context]
  379. */
  380. int wlan_cfg_get_host2rxdma_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  381. int context);
  382. /**
  383. * wlan_cfg_set_host2rxdma_mon_ring_mask() - Set host2rxdma monitor ring
  384. * interrupt mask for the given interrupt context
  385. * @wlan_cfg_ctx - Configuration Handle
  386. * @context - Numerical ID identifying the Interrupt/NAPI context
  387. *
  388. */
  389. void wlan_cfg_set_host2rxdma_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  390. int context, int mask);
  391. /**
  392. * wlan_cfg_get_host2rxdma_mon_ring_mask() - Return host2rxdma monitoe ring
  393. * interrupt mask mapped to an interrupt context
  394. * @wlan_cfg_ctx - Configuration Handle
  395. * @context - Numerical ID identifying the Interrupt/NAPI context
  396. *
  397. * Return: int_host2rxdma_mon_ring_mask[context]
  398. */
  399. int wlan_cfg_get_host2rxdma_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  400. int context);
  401. /**
  402. * wlan_cfg_set_rxdma2host_mon_ring_mask() - Set rxdma2host monitor
  403. * destination ring interrupt mask
  404. * for the given interrupt context
  405. * @wlan_cfg_ctx - Configuration Handle
  406. * @context - Numerical ID identifying the Interrupt/NAPI context
  407. *
  408. */
  409. void wlan_cfg_set_rxdma2host_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  410. int context, int mask);
  411. /**
  412. * wlan_cfg_get_rxdma2host_mon_ring_mask() - Return rxdma2host monitor
  413. * destination ring interrupt mask
  414. * mapped to an interrupt context
  415. * @wlan_cfg_ctx - Configuration Handle
  416. * @context - Numerical ID identifying the Interrupt/NAPI context
  417. *
  418. * Return: int_rxdma2host_mon_ring_mask[context]
  419. */
  420. int wlan_cfg_get_rxdma2host_mon_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg,
  421. int context);
  422. /**
  423. * wlan_cfg_set_hw_macid() - Set HW MAC Id for the given PDEV index
  424. *
  425. * @wlan_cfg_ctx - Configuration Handle
  426. * @pdev_idx - Index of SW PDEV
  427. * @hw_macid - HW MAC Id
  428. *
  429. */
  430. void wlan_cfg_set_hw_macid(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx,
  431. int hw_macid);
  432. /**
  433. * wlan_cfg_get_hw_macid() - Get HW MAC Id for the given PDEV index
  434. *
  435. * @wlan_cfg_ctx - Configuration Handle
  436. * @pdev_idx - Index of SW PDEV
  437. *
  438. * Return: HW MAC Id
  439. */
  440. int wlan_cfg_get_hw_macid(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx);
  441. /**
  442. * wlan_cfg_get_hw_mac_idx() - Get 0 based HW MAC index for the given
  443. * PDEV index
  444. *
  445. * @wlan_cfg_ctx - Configuration Handle
  446. * @pdev_idx - Index of SW PDEV
  447. *
  448. * Return: HW MAC index
  449. */
  450. int wlan_cfg_get_hw_mac_idx(struct wlan_cfg_dp_soc_ctxt *cfg, int pdev_idx);
  451. /**
  452. * wlan_cfg_get_rx_err_ring_mask() - Return Rx monitor ring interrupt mask
  453. * mapped to an interrupt context
  454. * @wlan_cfg_ctx - Configuration Handle
  455. * @context - Numerical ID identifying the Interrupt/NAPI context
  456. *
  457. * Return: int_rx_err_ring_mask[context]
  458. */
  459. int wlan_cfg_get_rx_err_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int
  460. context);
  461. /**
  462. * wlan_cfg_get_rx_wbm_rel_ring_mask() - Return Rx monitor ring interrupt mask
  463. * mapped to an interrupt context
  464. * @wlan_cfg_ctx - Configuration Handle
  465. * @context - Numerical ID identifying the Interrupt/NAPI context
  466. *
  467. * Return: int_wbm_rel_ring_mask[context]
  468. */
  469. int wlan_cfg_get_rx_wbm_rel_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int
  470. context);
  471. /**
  472. * wlan_cfg_get_reo_status_ring_mask() - Return Rx monitor ring interrupt mask
  473. * mapped to an interrupt context
  474. * @wlan_cfg_ctx - Configuration Handle
  475. * @context - Numerical ID identifying the Interrupt/NAPI context
  476. *
  477. * Return: int_reo_status_ring_mask[context]
  478. */
  479. int wlan_cfg_get_reo_status_ring_mask(struct wlan_cfg_dp_soc_ctxt *cfg, int
  480. context);
  481. /**
  482. * wlan_cfg_get_ce_ring_mask() - Return CE ring interrupt mask
  483. * mapped to an interrupt context
  484. * @wlan_cfg_ctx - Configuration Handle
  485. * @context - Numerical ID identifying the Interrupt/NAPI context
  486. *
  487. * Return: int_ce_ring_mask[context]
  488. */
  489. int wlan_cfg_get_ce_ring_mask(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx,
  490. int context);
  491. /**
  492. * wlan_cfg_get_max_clients() - Return maximum number of peers/stations
  493. * supported by device
  494. * @wlan_cfg_ctx - Configuration Handle
  495. *
  496. * Return: max_clients
  497. */
  498. uint32_t wlan_cfg_get_max_clients(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  499. /**
  500. * wlan_cfg_max_alloc_size() - Return Maximum allocation size for any dynamic
  501. * memory allocation request for this device
  502. * @wlan_cfg_ctx - Configuration Handle
  503. *
  504. * Return: max_alloc_size
  505. */
  506. uint32_t wlan_cfg_max_alloc_size(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  507. /*
  508. * wlan_cfg_per_pdev_tx_ring() - Return true if Tx rings are mapped as
  509. * one per radio
  510. * @wlan_cfg_ctx - Configuration Handle
  511. *
  512. * Return: per_pdev_tx_ring
  513. */
  514. int wlan_cfg_per_pdev_tx_ring(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  515. /*
  516. * wlan_cfg_num_tcl_data_rings() - Number of TCL Data rings supported by device
  517. * @wlan_cfg_ctx
  518. *
  519. * Return: num_tcl_data_rings
  520. */
  521. int wlan_cfg_num_tcl_data_rings(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  522. /*
  523. * wlan_cfg_per_pdev_rx_ring() - Return true if Rx rings are mapped as
  524. * one per radio
  525. * @wlan_cfg_ctx
  526. *
  527. * Return: per_pdev_rx_ring
  528. */
  529. int wlan_cfg_per_pdev_rx_ring(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  530. /*
  531. * wlan_cfg_per_pdev_lmac_ring() - Return true if error rings are mapped as
  532. * one per radio
  533. * @wlan_cfg_ctx
  534. *
  535. * Return: return 1 if per pdev error ring else 0
  536. */
  537. int wlan_cfg_per_pdev_lmac_ring(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  538. /*
  539. * wlan_cfg_num_reo_dest_rings() - Number of REO Data rings supported by device
  540. * @wlan_cfg_ctx - Configuration Handle
  541. *
  542. * Return: num_reo_dest_rings
  543. */
  544. int wlan_cfg_num_reo_dest_rings(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  545. /*
  546. * wlan_cfg_pkt_type() - Default 802.11 encapsulation type
  547. * @wlan_cfg_ctx - Configuration Handle
  548. *
  549. * Return: htt_pkt_type_ethernet
  550. */
  551. int wlan_cfg_pkt_type(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  552. /*
  553. * wlan_cfg_get_num_tx_desc_pool() - Number of Tx Descriptor pools for the
  554. * device
  555. * @wlan_cfg_ctx - Configuration Handle
  556. *
  557. * Return: num_tx_desc_pool
  558. */
  559. int wlan_cfg_get_num_tx_desc_pool(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  560. /*
  561. * wlan_cfg_set_num_tx_desc_pool() - Set the number of Tx Descriptor pools for the
  562. * device
  563. * @wlan_cfg_ctx - Configuration Handle
  564. * @num_pool - Number of pool
  565. */
  566. void wlan_cfg_set_num_tx_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg, int num_pool);
  567. /*
  568. * wlan_cfg_get_num_tx_ext_desc_pool() - Number of Tx MSDU ext Descriptor
  569. * pools
  570. * @wlan_cfg_ctx - Configuration Handle
  571. *
  572. * Return: num_tx_ext_desc_pool
  573. */
  574. int wlan_cfg_get_num_tx_ext_desc_pool(
  575. struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  576. /*
  577. * wlan_cfg_get_reo_dst_ring_size() - Get REO destination ring size
  578. *
  579. * @wlan_cfg_ctx - Configuration Handle
  580. *
  581. * Return: reo_dst_ring_size
  582. */
  583. int wlan_cfg_get_reo_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  584. /*
  585. * wlan_cfg_set_num_tx_desc_pool() - Set the REO Destination ring size
  586. *
  587. * @wlan_cfg_ctx - Configuration Handle
  588. * @reo_dst_ring_size - REO Destination ring size
  589. */
  590. void wlan_cfg_set_reo_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg,
  591. int reo_dst_ring_size);
  592. /*
  593. * wlan_cfg_set_raw_mode_war() - Set raw mode war configuration
  594. *
  595. * @wlan_cfg_ctx - Configuration Handle
  596. * @raw_mode_war - raw mode war configuration
  597. */
  598. void wlan_cfg_set_raw_mode_war(struct wlan_cfg_dp_soc_ctxt *cfg,
  599. bool raw_mode_war);
  600. /*
  601. * wlan_cfg_get_raw_mode_war() - Get raw mode war configuration
  602. *
  603. * @wlan_cfg_ctx - Configuration Handle
  604. *
  605. * Return: reo_dst_ring_size
  606. */
  607. bool wlan_cfg_get_raw_mode_war(struct wlan_cfg_dp_soc_ctxt *cfg);
  608. /*
  609. * wlan_cfg_set_num_tx_ext_desc_pool() - Set the number of Tx MSDU ext Descriptor
  610. * pools
  611. * @wlan_cfg_ctx - Configuration Handle
  612. * @num_pool - Number of pool
  613. */
  614. void wlan_cfg_set_num_tx_ext_desc_pool(struct wlan_cfg_dp_soc_ctxt *cfg, int num_pool);
  615. /*
  616. * wlan_cfg_get_num_tx_desc() - Number of Tx Descriptors per pool
  617. * @wlan_cfg_ctx - Configuration Handle
  618. *
  619. * Return: num_tx_desc
  620. */
  621. int wlan_cfg_get_num_tx_desc(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  622. /*
  623. * wlan_cfg_get_min_tx_desc() - Minimum number of Tx Descriptors per pool
  624. * @wlan_cfg_ctx - Configuration Handle
  625. *
  626. * Return: num_tx_desc
  627. */
  628. int wlan_cfg_get_min_tx_desc(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  629. /*
  630. * wlan_cfg_set_num_tx_desc() - Set the number of Tx Descriptors per pool
  631. *
  632. * @wlan_cfg_ctx - Configuration Handle
  633. * @num_desc: Number of descriptor
  634. */
  635. void wlan_cfg_set_num_tx_desc(struct wlan_cfg_dp_soc_ctxt *cfg, int num_desc);
  636. /*
  637. * wlan_cfg_get_num_tx_ext_desc() - Number of Tx MSDU extension Descriptors
  638. * per pool
  639. * @wlan_cfg_ctx - Configuration Handle
  640. *
  641. * Return: num_tx_ext_desc
  642. */
  643. int wlan_cfg_get_num_tx_ext_desc(struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx);
  644. /*
  645. * wlan_cfg_set_num_tx_ext_desc() - Set the number of Tx MSDU extension Descriptors
  646. * per pool
  647. * @wlan_cfg_ctx - Configuration Handle
  648. * @num_desc: Number of descriptor
  649. */
  650. void wlan_cfg_set_num_tx_ext_desc(struct wlan_cfg_dp_soc_ctxt *cfg, int num_ext_desc);
  651. /*
  652. * wlan_cfg_max_peer_id() - Get maximum peer ID
  653. * @cfg: Configuration Handle
  654. *
  655. * Return: maximum peer ID
  656. */
  657. uint32_t wlan_cfg_max_peer_id(struct wlan_cfg_dp_soc_ctxt *cfg);
  658. /*
  659. * wlan_cfg_get_dma_mon_buf_ring_size() - Return Size of monitor buffer ring
  660. * @wlan_cfg_pdev_ctx
  661. *
  662. * Return: dma_mon_buf_ring_size
  663. */
  664. int wlan_cfg_get_dma_mon_buf_ring_size(
  665. struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_pdev_ctx);
  666. /*
  667. * wlan_cfg_get_dma_mon_dest_ring_size() - Return Size of RxDMA Monitor
  668. * Destination ring
  669. * @wlan_cfg_pdev_ctx
  670. *
  671. * Return: dma_mon_dest_size
  672. */
  673. int wlan_cfg_get_dma_mon_dest_ring_size(
  674. struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_pdev_ctx);
  675. /*
  676. * wlan_cfg_get_dma_mon_stat_ring_size() - Return size of Monitor Status ring
  677. * @wlan_cfg_pdev_ctx
  678. *
  679. * Return: dma_mon_stat_ring_size
  680. */
  681. int wlan_cfg_get_dma_mon_stat_ring_size(
  682. struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_pdev_ctx);
  683. /*
  684. * wlan_cfg_get_dma_mon_desc_ring_size - Get rxdma monitor size
  685. * @wlan_cfg_soc_ctx
  686. *
  687. * Return: rxdma monitor desc ring size
  688. */
  689. int
  690. wlan_cfg_get_dma_mon_desc_ring_size(struct wlan_cfg_dp_pdev_ctxt *cfg);
  691. /*
  692. * wlan_cfg_get_rx_dma_buf_ring_size() - Return Size of RxDMA buffer ring
  693. * @wlan_cfg_pdev_ctx
  694. *
  695. * Return: rx_dma_buf_ring_size
  696. */
  697. int wlan_cfg_get_rx_dma_buf_ring_size(
  698. struct wlan_cfg_dp_pdev_ctxt *wlan_cfg_pdev_ctx);
  699. /*
  700. * wlan_cfg_get_num_mac_rings() - Return the number of MAC RX DMA rings
  701. * per pdev
  702. * @wlan_cfg_pdev_ctx
  703. *
  704. * Return: number of mac DMA rings per pdev
  705. */
  706. int wlan_cfg_get_num_mac_rings(struct wlan_cfg_dp_pdev_ctxt *cfg);
  707. /*
  708. * wlan_cfg_is_lro_enabled - Return LRO enabled/disabled
  709. * @wlan_cfg_dp_soc_ctxt
  710. *
  711. * Return: true - LRO enabled false - LRO disabled
  712. */
  713. bool wlan_cfg_is_lro_enabled(struct wlan_cfg_dp_soc_ctxt *cfg);
  714. /*
  715. * wlan_cfg_is_gro_enabled - Return GRO enabled/disabled
  716. * @wlan_cfg_dp_soc_ctxt
  717. *
  718. * Return: true - GRO enabled false - GRO disabled
  719. */
  720. bool wlan_cfg_is_gro_enabled(struct wlan_cfg_dp_soc_ctxt *cfg);
  721. /*
  722. * wlan_cfg_is_rx_hash_enabled - Return RX hash enabled/disabled
  723. * @wlan_cfg_dp_soc_ctxt
  724. *
  725. * Return: true - enabled false - disabled
  726. */
  727. bool wlan_cfg_is_rx_hash_enabled(struct wlan_cfg_dp_soc_ctxt *cfg);
  728. /*
  729. * wlan_cfg_is_ipa_enabled - Return IPA enabled/disabled
  730. * @wlan_cfg_dp_soc_ctxt
  731. *
  732. * Return: true - enabled false - disabled
  733. */
  734. bool wlan_cfg_is_ipa_enabled(struct wlan_cfg_dp_soc_ctxt *cfg);
  735. /*
  736. * wlan_cfg_set_rx_hash - set rx hash enabled/disabled
  737. * @wlan_cfg_soc_ctx
  738. * @rx_hash
  739. */
  740. void wlan_cfg_set_rx_hash(struct wlan_cfg_dp_soc_ctxt *cfg, bool rx_hash);
  741. /*
  742. * wlan_cfg_get_dp_pdev_nss_enabled - Return pdev nss enabled/disabled
  743. * @wlan_cfg_pdev_ctx
  744. *
  745. * Return: 1 - enabled 0 - disabled
  746. */
  747. int wlan_cfg_get_dp_pdev_nss_enabled(struct wlan_cfg_dp_pdev_ctxt *cfg);
  748. /*
  749. * wlan_cfg_set_dp_pdev_nss_enabled - set pdev nss enabled/disabled
  750. * @wlan_cfg_pdev_ctx
  751. */
  752. void wlan_cfg_set_dp_pdev_nss_enabled(struct wlan_cfg_dp_pdev_ctxt *cfg, int nss_enabled);
  753. /*
  754. * wlan_cfg_get_dp_soc_nss_cfg - Return soc nss config
  755. * @wlan_cfg_pdev_ctx
  756. *
  757. * Return: nss_cfg
  758. */
  759. int wlan_cfg_get_dp_soc_nss_cfg(struct wlan_cfg_dp_soc_ctxt *cfg);
  760. /*
  761. * wlan_cfg_set_dp_soc_nss_cfg - set soc nss config
  762. * @wlan_cfg_pdev_ctx
  763. *
  764. */
  765. void wlan_cfg_set_dp_soc_nss_cfg(struct wlan_cfg_dp_soc_ctxt *cfg, int nss_cfg);
  766. /*
  767. * wlan_cfg_get_int_batch_threshold_tx - Get interrupt mitigation cfg for Tx
  768. * @wlan_cfg_soc_ctx
  769. *
  770. * Return: Batch threshold
  771. */
  772. int wlan_cfg_get_int_batch_threshold_tx(struct wlan_cfg_dp_soc_ctxt *cfg);
  773. /*
  774. * wlan_cfg_get_int_timer_threshold_tx - Get interrupt mitigation cfg for Tx
  775. * @wlan_cfg_soc_ctx
  776. *
  777. * Return: Timer threshold
  778. */
  779. int wlan_cfg_get_int_timer_threshold_tx(struct wlan_cfg_dp_soc_ctxt *cfg);
  780. /*
  781. * wlan_cfg_get_int_batch_threshold_rx - Get interrupt mitigation cfg for Rx
  782. * @wlan_cfg_soc_ctx
  783. *
  784. * Return: Batch threshold
  785. */
  786. int wlan_cfg_get_int_batch_threshold_rx(struct wlan_cfg_dp_soc_ctxt *cfg);
  787. /*
  788. * wlan_cfg_get_int_batch_threshold_rx - Get interrupt mitigation cfg for Rx
  789. * @wlan_cfg_soc_ctx
  790. *
  791. * Return: Timer threshold
  792. */
  793. int wlan_cfg_get_int_timer_threshold_rx(struct wlan_cfg_dp_soc_ctxt *cfg);
  794. /*
  795. * wlan_cfg_get_int_batch_threshold_tx - Get interrupt mitigation cfg for other srngs
  796. * @wlan_cfg_soc_ctx
  797. *
  798. * Return: Batch threshold
  799. */
  800. int wlan_cfg_get_int_batch_threshold_other(struct wlan_cfg_dp_soc_ctxt *cfg);
  801. /*
  802. * wlan_cfg_get_int_batch_threshold_tx - Get interrupt mitigation cfg for other srngs
  803. * @wlan_cfg_soc_ctx
  804. *
  805. * Return: Timer threshold
  806. */
  807. int wlan_cfg_get_int_timer_threshold_other(struct wlan_cfg_dp_soc_ctxt *cfg);
  808. /*
  809. * wlan_cfg_get_int_timer_threshold_mon - Get int mitigation cfg for mon srngs
  810. * @wlan_cfg_soc_ctx
  811. *
  812. * Return: Timer threshold
  813. */
  814. int wlan_cfg_get_int_timer_threshold_mon(struct wlan_cfg_dp_soc_ctxt *cfg);
  815. /*
  816. * wlan_cfg_get_checksum_offload - Get checksum offload enable or disable status
  817. * @wlan_cfg_soc_ctx
  818. *
  819. * Return: Checksum offload enable or disable
  820. */
  821. int wlan_cfg_get_checksum_offload(struct wlan_cfg_dp_soc_ctxt *cfg);
  822. /*
  823. * wlan_cfg_tx_ring_size - Get Tx DMA ring size (TCL Data Ring)
  824. * @wlan_cfg_soc_ctx
  825. *
  826. * Return: Tx Ring Size
  827. */
  828. int wlan_cfg_tx_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  829. /*
  830. * wlan_cfg_tx_comp_ring_size - Get Tx completion ring size (WBM Ring)
  831. * @wlan_cfg_soc_ctx
  832. *
  833. * Return: Tx Completion ring size
  834. */
  835. int wlan_cfg_tx_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  836. /*
  837. * wlan_cfg_get_dp_soc_wbm_release_ring_size - Get wbm_release_ring size
  838. * @wlan_cfg_soc_ctx
  839. *
  840. * Return: wbm_release_ring size
  841. */
  842. int
  843. wlan_cfg_get_dp_soc_wbm_release_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  844. /*
  845. * wlan_cfg_get_dp_soc_tcl_cmd_ring_size - Get tcl_cmd_ring size
  846. * @wlan_cfg_soc_ctx
  847. *
  848. * Return: tcl_cmd_ring size
  849. */
  850. int
  851. wlan_cfg_get_dp_soc_tcl_cmd_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  852. /*
  853. * wlan_cfg_get_dp_soc_tcl_status_ring_size - Get tcl_status_ring size
  854. * @wlan_cfg_soc_ctx
  855. *
  856. * Return: tcl_status_ring size
  857. */
  858. int
  859. wlan_cfg_get_dp_soc_tcl_status_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  860. /*
  861. * wlan_cfg_get_dp_soc_reo_reinject_ring_size - Get reo_reinject_ring size
  862. * @wlan_cfg_soc_ctx
  863. *
  864. * Return: reo_reinject_ring size
  865. */
  866. int
  867. wlan_cfg_get_dp_soc_reo_reinject_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  868. /*
  869. * wlan_cfg_get_dp_soc_rx_release_ring_size - Get rx_release_ring size
  870. * @wlan_cfg_soc_ctx
  871. *
  872. * Return: rx_release_ring size
  873. */
  874. int
  875. wlan_cfg_get_dp_soc_rx_release_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  876. /*
  877. * wlan_cfg_get_dp_soc_reo_exception_ring_size - Get reo_exception_ring size
  878. * @wlan_cfg_soc_ctx
  879. *
  880. * Return: reo_exception_ring size
  881. */
  882. int
  883. wlan_cfg_get_dp_soc_reo_exception_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  884. /*
  885. * wlan_cfg_get_dp_soc_reo_cmd_ring_size - Get reo_cmd_ring size
  886. * @wlan_cfg_soc_ctx
  887. *
  888. * Return: reo_cmd_ring size
  889. */
  890. int
  891. wlan_cfg_get_dp_soc_reo_cmd_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  892. /*
  893. * wlan_cfg_get_dp_soc_reo_status_ring_size - Get reo_status_ring size
  894. * @wlan_cfg_soc_ctx
  895. *
  896. * Return: reo_status_ring size
  897. */
  898. int
  899. wlan_cfg_get_dp_soc_reo_status_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  900. /*
  901. * wlan_cfg_get_dp_soc_rxdma_refill_ring_size - Get rxdma refill ring size
  902. * @wlan_cfg_soc_ctx
  903. *
  904. * Return: rxdma refill ring size
  905. */
  906. int
  907. wlan_cfg_get_dp_soc_rxdma_refill_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  908. /*
  909. * wlan_cfg_get_dp_soc_rxdma_err_dst_ring_size - Get rxdma dst ring size
  910. * @wlan_cfg_soc_ctx
  911. *
  912. * Return: rxdma error dst ring size
  913. */
  914. int
  915. wlan_cfg_get_dp_soc_rxdma_err_dst_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
  916. /*
  917. * wlan_cfg_get_dp_caps - Get dp capablities
  918. * @wlan_cfg_soc_ctx
  919. * @dp_caps: enum for dp capablities
  920. *
  921. * Return: bool if a dp capabilities is enabled
  922. */
  923. bool
  924. wlan_cfg_get_dp_caps(struct wlan_cfg_dp_soc_ctxt *cfg,
  925. enum cdp_capabilities dp_caps);
  926. /**
  927. * wlan_set_srng_cfg() - Fill per ring specific
  928. * configuration parameters
  929. * @wlan_cfg: global srng configuration table
  930. *
  931. * Return: None
  932. */
  933. void wlan_set_srng_cfg(struct wlan_srng_cfg **wlan_cfg);
  934. #ifdef QCA_LL_TX_FLOW_CONTROL_V2
  935. int wlan_cfg_get_tx_flow_stop_queue_th(struct wlan_cfg_dp_soc_ctxt *cfg);
  936. int wlan_cfg_get_tx_flow_start_queue_offset(struct wlan_cfg_dp_soc_ctxt *cfg);
  937. #endif /* QCA_LL_TX_FLOW_CONTROL_V2 */
  938. int wlan_cfg_get_rx_defrag_min_timeout(struct wlan_cfg_dp_soc_ctxt *cfg);
  939. int wlan_cfg_get_defrag_timeout_check(struct wlan_cfg_dp_soc_ctxt *cfg);
  940. #endif