wlan_cfg.h 31 KB

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