cdp_txrx_stats_struct.h 57 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864
  1. /*
  2. * Copyright (c) 2016-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. /**
  19. * @file cdp_txrx_stats_struct.h
  20. * @brief Define the host data path stats API functions
  21. * called by the host control SW and the OS interface module
  22. */
  23. #ifndef _CDP_TXRX_STATS_STRUCT_H_
  24. #define _CDP_TXRX_STATS_STRUCT_H_
  25. #ifdef FEATURE_TSO_STATS
  26. #include <qdf_types.h>
  27. #endif /* FEATURE_TSO_STATS */
  28. #define TXRX_STATS_LEVEL_OFF 0
  29. #define TXRX_STATS_LEVEL_BASIC 1
  30. #define TXRX_STATS_LEVEL_FULL 2
  31. #define BSS_CHAN_INFO_READ 1
  32. #define BSS_CHAN_INFO_READ_AND_CLEAR 2
  33. #define TX_FRAME_TYPE_DATA 0
  34. #define TX_FRAME_TYPE_MGMT 1
  35. #define TX_FRAME_TYPE_BEACON 2
  36. #ifndef TXRX_STATS_LEVEL
  37. #define TXRX_STATS_LEVEL TXRX_STATS_LEVEL_BASIC
  38. #endif
  39. /* 1 additional MCS is for invalid values */
  40. #define MAX_MCS (12 + 1)
  41. #define MAX_MCS_11A 8
  42. #define MAX_MCS_11B 7
  43. #define MAX_MCS_11AC 12
  44. /* 1 additional GI is for invalid values */
  45. #define MAX_GI (4 + 1)
  46. #define SS_COUNT 8
  47. #define MAX_BW 7
  48. #define MAX_RECEPTION_TYPES 4
  49. #define MAX_TRANSMIT_TYPES 9
  50. #define MAX_USER_POS 8
  51. #define MAX_MU_GROUP_ID 64
  52. #define MAX_RU_LOCATIONS 6
  53. #define RU_26 1
  54. #define RU_52 2
  55. #define RU_106 4
  56. #define RU_242 9
  57. #define RU_484 18
  58. #define RU_996 37
  59. /* WME stream classes */
  60. #define WME_AC_BE 0 /* best effort */
  61. #define WME_AC_BK 1 /* background */
  62. #define WME_AC_VI 2 /* video */
  63. #define WME_AC_VO 3 /* voice */
  64. #define WME_AC_MAX 4 /* MAX AC Value */
  65. #define CDP_MAX_RX_RINGS 4 /* max rx rings */
  66. #define CDP_MAX_TX_COMP_RINGS 3 /* max tx completion rings */
  67. #define CDP_MAX_TX_TQM_STATUS 9 /* max tx tqm completion status */
  68. #define CDP_MAX_TX_HTT_STATUS 7 /* max tx htt completion status */
  69. /* TID level VoW stats macros
  70. * to add and get stats
  71. */
  72. #define PFLOW_TXRX_TIDQ_STATS_ADD(_peer, _tid, _var, _val) \
  73. (((_peer)->tidq_stats[_tid]).stats[_var]) += _val
  74. #define PFLOW_TXRX_TIDQ_STATS_GET(_peer, _tid, _var, _val) \
  75. ((_peer)->tidq_stats[_tid].stats[_var])
  76. /*
  77. * Video only stats
  78. */
  79. #define PFLOW_CTRL_PDEV_VIDEO_STATS_SET(_pdev, _var, _val) \
  80. (((_pdev)->vow.vistats[_var]).value) = _val
  81. #define PFLOW_CTRL_PDEV_VIDEO_STATS_GET(_pdev, _var) \
  82. ((_pdev)->vow.vistats[_var].value)
  83. #define PFLOW_CTRL_PDEV_VIDEO_STATS_ADD(_pdev, _var, _val) \
  84. (((_pdev)->vow.vistats[_var]).value) += _val
  85. /*
  86. * video delay stats
  87. */
  88. #define PFLOW_CTRL_PDEV_DELAY_VIDEO_STATS_SET(_pdev, _var, _val) \
  89. (((_pdev)->vow.delaystats[_var]).value) = _val
  90. #define PFLOW_CTRL_PDEV_DELAY_VIDEO_STATS_GET(_pdev, _var) \
  91. ((_pdev)->vow.delaystats[_var].value)
  92. #define PFLOW_CTRL_PDEV_DELAY_VIDEO_STATS_ADD(_pdev, _var, _val) \
  93. (((_pdev)->vow.delaystats[_var]).value) += _val
  94. /*
  95. * Number of TLVs sent by FW. Needs to reflect
  96. * HTT_PPDU_STATS_MAX_TAG declared in FW
  97. */
  98. #define CDP_PPDU_STATS_MAX_TAG 14
  99. #define CDP_MAX_DATA_TIDS 9
  100. #define CDP_WDI_NUM_EVENTS WDI_NUM_EVENTS
  101. #define CDP_FCTL_RETRY 0x0800
  102. #define CDP_FC_IS_RETRY_SET(_fc) \
  103. ((_fc) & qdf_cpu_to_le16(CDP_FCTL_RETRY))
  104. #define INVALID_RSSI 255
  105. /*Max SU EVM count */
  106. #define DP_RX_MAX_SU_EVM_COUNT 32
  107. #define WDI_EVENT_BASE 0x100
  108. #define CDP_TXRX_RATECODE_MCS_MASK 0xF
  109. #define CDP_TXRX_RATECODE_NSS_MASK 0x3
  110. #define CDP_TXRX_RATECODE_NSS_LSB 4
  111. #define CDP_TXRX_RATECODE_PREM_MASK 0x3
  112. #define CDP_TXRX_RATECODE_PREM_LSB 6
  113. /* Below BW_GAIN should be added to the SNR value of every ppdu based on the
  114. * bandwidth. This table is obtained from HALPHY.
  115. * BW BW_Gain
  116. * 20 0
  117. * 40 3dBm
  118. * 80 6dBm
  119. * 160/80P80 9dBm
  120. */
  121. #define PKT_BW_GAIN_20MHZ 0
  122. #define PKT_BW_GAIN_40MHZ 3
  123. #define PKT_BW_GAIN_80MHZ 6
  124. #define PKT_BW_GAIN_160MHZ 9
  125. /*
  126. * cdp_tx_transmit_type: Transmit type index
  127. * SU: SU Transmit type index
  128. * MU_MIMO: MU_MIMO Transmit type index
  129. * MU_OFDMA: MU_OFDMA Transmit type index
  130. * MU_MIMO_OFDMA: MU MIMO OFDMA Transmit type index
  131. */
  132. enum cdp_tx_transmit_type {
  133. SU = 0,
  134. MU_MIMO,
  135. MU_OFDMA,
  136. MU_MIMO_OFDMA,
  137. };
  138. /*
  139. * cdp_ru_index: Different RU index
  140. *
  141. * RU_26_INDEX : 26-tone Resource Unit index
  142. * RU_52_INDEX : 52-tone Resource Unit index
  143. * RU_106_INDEX: 106-tone Resource Unit index
  144. * RU_242_INDEX: 242-tone Resource Unit index
  145. * RU_484_INDEX: 484-tone Resource Unit index
  146. * RU_996_INDEX: 996-tone Resource Unit index
  147. */
  148. enum cdp_ru_index {
  149. RU_26_INDEX = 0,
  150. RU_52_INDEX,
  151. RU_106_INDEX,
  152. RU_242_INDEX,
  153. RU_484_INDEX,
  154. RU_996_INDEX,
  155. };
  156. #ifdef FEATURE_TSO_STATS
  157. /* Number of TSO Packet Statistics captured */
  158. #define CDP_MAX_TSO_PACKETS 5
  159. /* Information for Number of Segments for a TSO Packet captured */
  160. #define CDP_MAX_TSO_SEGMENTS 2
  161. /* Information for Number of Fragments for a TSO Segment captured */
  162. #define CDP_MAX_TSO_FRAGMENTS 6
  163. #endif /* FEATURE_TSO_STATS */
  164. /* Different Packet Types */
  165. enum cdp_packet_type {
  166. DOT11_A = 0,
  167. DOT11_B = 1,
  168. DOT11_N = 2,
  169. DOT11_AC = 3,
  170. DOT11_AX = 4,
  171. DOT11_MAX = 5,
  172. };
  173. /*
  174. * cdp_mu_packet_type: MU Rx type index
  175. * RX_TYPE_MU_MIMO: MU MIMO Rx type index
  176. * RX_TYPE_MU_OFDMA: MU OFDMA Rx type index
  177. * MU_MIMO_OFDMA: MU Rx MAX type index
  178. */
  179. enum cdp_mu_packet_type {
  180. RX_TYPE_MU_MIMO = 0,
  181. RX_TYPE_MU_OFDMA = 1,
  182. RX_TYPE_MU_MAX = 2,
  183. };
  184. enum WDI_EVENT {
  185. WDI_EVENT_TX_STATUS = WDI_EVENT_BASE,
  186. WDI_EVENT_OFFLOAD_ALL,
  187. WDI_EVENT_RX_DESC_REMOTE,
  188. WDI_EVENT_RX_PEER_INVALID,
  189. WDI_EVENT_DBG_PRINT, /* NEED to integrate pktlog changes*/
  190. WDI_EVENT_RX_CBF_REMOTE,
  191. WDI_EVENT_RATE_FIND,
  192. WDI_EVENT_RATE_UPDATE,
  193. WDI_EVENT_SW_EVENT,
  194. WDI_EVENT_RX_DESC,
  195. WDI_EVENT_LITE_T2H,
  196. WDI_EVENT_LITE_RX,
  197. WDI_EVENT_RX_PPDU_DESC,
  198. WDI_EVENT_TX_PPDU_DESC,
  199. WDI_EVENT_TX_MSDU_DESC,
  200. WDI_EVENT_TX_DATA,
  201. WDI_EVENT_RX_DATA,
  202. WDI_EVENT_TX_MGMT_CTRL,
  203. WDI_EVENT_HTT_STATS,
  204. WDI_EVENT_TX_BEACON,
  205. WDI_EVENT_PEER_STATS,
  206. WDI_EVENT_TX_SOJOURN_STAT,
  207. WDI_EVENT_UPDATE_DP_STATS,
  208. WDI_EVENT_RX_MGMT_CTRL,
  209. WDI_EVENT_PEER_CREATE,
  210. WDI_EVENT_PEER_DESTROY,
  211. WDI_EVENT_PEER_FLUSH_RATE_STATS,
  212. WDI_EVENT_FLUSH_RATE_STATS_REQ,
  213. WDI_EVENT_RX_MPDU,
  214. /* End of new event items */
  215. WDI_EVENT_LAST
  216. };
  217. #define WDI_NUM_EVENTS WDI_EVENT_LAST - WDI_EVENT_BASE
  218. struct cdp_stats_extd {
  219. };
  220. /* TID level Tx/Rx stats
  221. *
  222. */
  223. enum cdp_txrx_tidq_stats {
  224. /* Tx Counters */
  225. TX_MSDU_TOTAL_LINUX_SUBSYSTEM,
  226. TX_MSDU_TOTAL_FROM_OSIF,
  227. TX_MSDU_TX_COMP_PKT_CNT,
  228. /* Rx Counters */
  229. RX_MSDU_TOTAL_FROM_FW,
  230. RX_MSDU_MCAST_FROM_FW,
  231. RX_TID_MISMATCH_FROM_FW,
  232. RX_MSDU_MISC_PKTS,
  233. RX_MSDU_IS_ARP,
  234. RX_MSDU_IS_EAP,
  235. RX_MSDU_IS_DHCP,
  236. RX_AGGREGATE_10,
  237. RX_AGGREGATE_20,
  238. RX_AGGREGATE_30,
  239. RX_AGGREGATE_40,
  240. RX_AGGREGATE_50,
  241. RX_AGGREGATE_60,
  242. RX_AGGREGATE_MORE,
  243. RX_AMSDU_1,
  244. RX_AMSDU_2,
  245. RX_AMSDU_3,
  246. RX_AMSDU_4,
  247. RX_AMSDU_MORE,
  248. RX_MSDU_CHAINED_FROM_FW,
  249. RX_MSDU_REORDER_FAILED_FROM_FW,
  250. RX_MSDU_REORDER_FLUSHED_FROM_FW,
  251. RX_MSDU_DISCARD_FROM_FW,
  252. RX_MSDU_DUPLICATE_FROM_FW,
  253. RX_MSDU_DELIVERED_TO_STACK,
  254. TIDQ_STATS_MAX,
  255. };
  256. struct cdp_tidq_stats {
  257. uint32_t stats[TIDQ_STATS_MAX];
  258. };
  259. /*
  260. * struct cdp_rx_su_evm_info: Rx evm info
  261. * @number_of_symbols: number of symbols
  262. * @nss_count: number of spatial streams
  263. * @pilot_count: number of pilot count
  264. */
  265. struct cdp_rx_su_evm_info {
  266. uint16_t number_of_symbols;
  267. uint8_t nss_count;
  268. uint8_t pilot_count;
  269. uint32_t pilot_evm[DP_RX_MAX_SU_EVM_COUNT];
  270. };
  271. /*
  272. * cdp_delay_stats_mode: Different types of delay statistics
  273. *
  274. * @CDP_DELAY_STATS_SW_ENQ: Stack to hw enqueue delay
  275. * @CDP_DELAY_STATS_TX_INTERFRAME: Interframe delay at radio entry point
  276. * @CDP_DELAY_STATS_FW_HW_TRANSMIT: Hw enqueue to tx completion delay
  277. * @CDP_DELAY_STATS_REAP_STACK: Delay in ring reap to indicating network stack
  278. * @CDP_DELAY_STATS_RX_INTERFRAME: Rx inteframe delay
  279. * @CDP_DELAY_STATS_MODE_MAX: Maximum delay mode
  280. */
  281. enum cdp_delay_stats_mode {
  282. CDP_DELAY_STATS_SW_ENQ,
  283. CDP_DELAY_STATS_TX_INTERFRAME,
  284. CDP_DELAY_STATS_FW_HW_TRANSMIT,
  285. CDP_DELAY_STATS_REAP_STACK,
  286. CDP_DELAY_STATS_RX_INTERFRAME,
  287. CDP_DELAY_STATS_MODE_MAX,
  288. };
  289. /*
  290. * cdp_delay_bucket_index
  291. * Index to be used for all delay stats
  292. */
  293. enum cdp_delay_bucket_index {
  294. CDP_DELAY_BUCKET_0,
  295. CDP_DELAY_BUCKET_1,
  296. CDP_DELAY_BUCKET_2,
  297. CDP_DELAY_BUCKET_3,
  298. CDP_DELAY_BUCKET_4,
  299. CDP_DELAY_BUCKET_5,
  300. CDP_DELAY_BUCKET_6,
  301. CDP_DELAY_BUCKET_7,
  302. CDP_DELAY_BUCKET_8,
  303. CDP_DELAY_BUCKET_9,
  304. CDP_DELAY_BUCKET_10,
  305. CDP_DELAY_BUCKET_11,
  306. CDP_DELAY_BUCKET_12,
  307. CDP_DELAY_BUCKET_MAX,
  308. };
  309. /*
  310. * struct cdp_tx_host_drop - packet drop due to following reasons.
  311. */
  312. enum cdp_tx_sw_drop {
  313. TX_DESC_ERR,
  314. TX_HAL_RING_ACCESS_ERR,
  315. TX_DMA_MAP_ERR,
  316. TX_HW_ENQUEUE,
  317. TX_SW_ENQUEUE,
  318. TX_MAX_DROP,
  319. };
  320. /*
  321. * struct cdp_rx_host_drop - packet drop due to following reasons.
  322. */
  323. enum cdp_rx_sw_drop {
  324. INTRABSS_DROP,
  325. MSDU_DONE_FAILURE,
  326. INVALID_PEER_VDEV,
  327. POLICY_CHECK_DROP,
  328. MEC_DROP,
  329. NAWDS_MCAST_DROP,
  330. MESH_FILTER_DROP,
  331. ENQUEUE_DROP,
  332. RX_MAX_DROP,
  333. };
  334. /*
  335. * struct cdp_delay_stats
  336. * @delay_bucket: division of buckets as per latency
  337. * @min_delay: minimum delay
  338. * @max_delay: maximum delay
  339. * @avg_delay: average delay
  340. */
  341. struct cdp_delay_stats {
  342. uint64_t delay_bucket[CDP_DELAY_BUCKET_MAX];
  343. uint32_t min_delay;
  344. uint32_t max_delay;
  345. uint32_t avg_delay;
  346. };
  347. /*
  348. * struct cdp_tid_tx_stats
  349. * @swq_delay: delay between wifi driver entry point and enqueue to HW in tx
  350. * @hwtx_delay: delay between wifi driver exit (enqueue to HW) and tx completion
  351. * @intfrm_delay: interframe delay
  352. * @success_cnt: total successful transmit count
  353. * @comp_fail_cnt: firmware drop found in tx completion path
  354. * @swdrop_cnt: software drop in tx path
  355. * @tqm_status_cnt: TQM completion status count
  356. * @htt_status_cnt: HTT completion status count
  357. */
  358. struct cdp_tid_tx_stats {
  359. struct cdp_delay_stats swq_delay;
  360. struct cdp_delay_stats hwtx_delay;
  361. struct cdp_delay_stats intfrm_delay;
  362. uint64_t success_cnt;
  363. uint64_t comp_fail_cnt;
  364. uint64_t swdrop_cnt[TX_MAX_DROP];
  365. uint64_t tqm_status_cnt[CDP_MAX_TX_TQM_STATUS];
  366. uint64_t htt_status_cnt[CDP_MAX_TX_HTT_STATUS];
  367. };
  368. /*
  369. * struct cdp_tid_tx_stats
  370. * @to_stack_delay: Time taken between ring reap to indication to network stack
  371. * @intfrm_delay: Interframe rx delay
  372. * @delivered_cnt: Total packets indicated to stack
  373. * @intrabss_cnt: Rx total intraBSS frames
  374. * @msdu_cnt: number of msdu received from HW
  375. * @mcast_msdu_cnt: Num Mcast Msdus received from HW in Rx
  376. * @bcast_msdu_cnt: Num Bcast Msdus received from HW in Rx
  377. * @fail_cnt: Rx deliver drop counters
  378. */
  379. struct cdp_tid_rx_stats {
  380. struct cdp_delay_stats to_stack_delay;
  381. struct cdp_delay_stats intfrm_delay;
  382. uint64_t delivered_to_stack;
  383. uint64_t intrabss_cnt;
  384. uint64_t msdu_cnt;
  385. uint64_t mcast_msdu_cnt;
  386. uint64_t bcast_msdu_cnt;
  387. uint64_t fail_cnt[RX_MAX_DROP];
  388. };
  389. /*
  390. * struct cdp_tid_stats
  391. * @ingress_stack: Total packets received from linux stack
  392. * @osif_drop: drops in osif layer
  393. * @tid_tx_stats: transmit counters per tid
  394. * @tid_rx_stats: receive counters per tid
  395. */
  396. struct cdp_tid_stats {
  397. uint64_t ingress_stack;
  398. uint64_t osif_drop;
  399. struct cdp_tid_tx_stats tid_tx_stats[CDP_MAX_TX_COMP_RINGS]
  400. [CDP_MAX_DATA_TIDS];
  401. struct cdp_tid_rx_stats tid_rx_stats[CDP_MAX_RX_RINGS]
  402. [CDP_MAX_DATA_TIDS];
  403. };
  404. /* struct cdp_pkt_info - packet info
  405. * @num: no of packets
  406. * @bytes: total no of bytes
  407. */
  408. struct cdp_pkt_info {
  409. uint32_t num;
  410. uint64_t bytes;
  411. };
  412. /* struct cdp_pkt_type - packet type
  413. * @mcs_count: Counter array for each MCS index
  414. */
  415. struct cdp_pkt_type {
  416. uint32_t mcs_count[MAX_MCS];
  417. };
  418. /*
  419. * struct cdp_rx_mu - Rx MU Stats
  420. * @ppdu_nss[SS_COUNT]: Packet Count in spatial streams
  421. * @mpdu_cnt_fcs_ok: Rx success mpdu count
  422. * @mpdu_cnt_fcs_err: Rx fail mpdu count
  423. * @cdp_pkt_type: counter array for each MCS index
  424. */
  425. struct cdp_rx_mu {
  426. uint32_t ppdu_nss[SS_COUNT];
  427. uint32_t mpdu_cnt_fcs_ok;
  428. uint32_t mpdu_cnt_fcs_err;
  429. struct cdp_pkt_type ppdu;
  430. };
  431. /* struct cdp_tx_pkt_info - tx packet info
  432. * num_msdu - successful msdu
  433. * num_mpdu - successful mpdu from compltn common
  434. * mpdu_tried - mpdu tried
  435. *
  436. * tx packet info counter field for mpdu success/tried and msdu
  437. */
  438. struct cdp_tx_pkt_info {
  439. uint32_t num_msdu;
  440. uint32_t num_mpdu;
  441. uint32_t mpdu_tried;
  442. };
  443. #ifdef FEATURE_TSO_STATS
  444. /**
  445. * struct cdp_tso_seg_histogram - Segment histogram for TCP Packets
  446. * @segs_1: packets with single segments
  447. * @segs_2_5: packets with 2-5 segments
  448. * @segs_6_10: packets with 6-10 segments
  449. * @segs_11_15: packets with 11-15 segments
  450. * @segs_16_20: packets with 16-20 segments
  451. * @segs_20_plus: packets with 20 plus segments
  452. */
  453. struct cdp_tso_seg_histogram {
  454. uint64_t segs_1;
  455. uint64_t segs_2_5;
  456. uint64_t segs_6_10;
  457. uint64_t segs_11_15;
  458. uint64_t segs_16_20;
  459. uint64_t segs_20_plus;
  460. };
  461. /**
  462. * struct cdp_tso_packet_info - Stats for TSO segments within a TSO packet
  463. * @tso_seg: TSO Segment information
  464. * @num_seg: Number of segments
  465. * @tso_packet_len: Size of the tso packet
  466. * @tso_seg_idx: segment number
  467. */
  468. struct cdp_tso_packet_info {
  469. struct qdf_tso_seg_t tso_seg[CDP_MAX_TSO_SEGMENTS];
  470. uint8_t num_seg;
  471. size_t tso_packet_len;
  472. uint32_t tso_seg_idx;
  473. };
  474. /**
  475. * struct cdp_tso_info - stats for tso packets
  476. * @tso_packet_info: TSO packet information
  477. */
  478. struct cdp_tso_info {
  479. struct cdp_tso_packet_info tso_packet_info[CDP_MAX_TSO_PACKETS];
  480. };
  481. #endif /* FEATURE_TSO_STATS */
  482. /**
  483. * struct cdp_tso_stats - TSO stats information
  484. * @num_tso_pkts: Total number of TSO Packets
  485. * @tso_comp: Total tso packet completions
  486. * @dropped_host: TSO packets dropped by host
  487. * @tso_no_mem_dropped: TSO packets dropped by host due to descriptor
  488. unavailablity
  489. * @dropped_target: TSO packets_dropped by target
  490. * @tso_info: Per TSO packet counters
  491. * @seg_histogram: TSO histogram stats
  492. */
  493. struct cdp_tso_stats {
  494. struct cdp_pkt_info num_tso_pkts;
  495. uint32_t tso_comp;
  496. struct cdp_pkt_info dropped_host;
  497. struct cdp_pkt_info tso_no_mem_dropped;
  498. uint32_t dropped_target;
  499. #ifdef FEATURE_TSO_STATS
  500. struct cdp_tso_info tso_info;
  501. struct cdp_tso_seg_histogram seg_histogram;
  502. #endif /* FEATURE_TSO_STATS */
  503. };
  504. /* struct cdp_tx_stats - tx stats
  505. * @cdp_pkt_info comp_pkt: Pkt Info for which completions were received
  506. * @cdp_pkt_info ucast: Unicast Packet Count
  507. * @cdp_pkt_info mcast: Multicast Packet Count
  508. * @cdp_pkt_info bcast: Broadcast Packet Count
  509. * @cdp_pkt_info nawds_mcast: NAWDS Multicast Packet Count
  510. * @nawds_mcast_drop: NAWDS Multicast Drop Count
  511. * @cdp_pkt_info tx_success: Successful Tx Packets
  512. * @tx_failed: Total Tx failure
  513. * @ofdma: Total Packets as ofdma
  514. * @stbc: Packets in STBC
  515. * @ldpc: Packets in LDPC
  516. * @retries: Packet retries
  517. * @non_amsdu_cnt: Number of MSDUs with no MSDU level aggregation
  518. * @amsdu_cnt: Number of MSDUs part of AMSDU
  519. * @tx_rate: Tx Rate
  520. * @last_tx_rate: Last tx rate for unicast packets
  521. * @last_tx_rate_mcs: Tx rate mcs for unicast packets
  522. * @mcast_last_tx_rate: Last tx rate for multicast packets
  523. * @mcast_last_tx_rate_mcs: Last tx rate mcs for multicast
  524. * @last_per: Tx Per
  525. * @rnd_avg_tx_rate: Rounded average tx rate
  526. * @avg_tx_rate: Average TX rate
  527. * @last_ack_rssi: RSSI of last acked packet
  528. * @tx_bytes_success_last: last Tx success bytes
  529. * @tx_data_success_last: last Tx success data
  530. * @tx_byte_rate: Bytes Trasmitted in last one sec
  531. * @tx_data_rate: Data Transmitted in last one sec
  532. * @sgi_count[MAX_GI]: SGI count
  533. * @nss[SS_COUNT]: Packet count for different num_spatial_stream values
  534. * @bw[MAX_BW]: Packet Count for different bandwidths
  535. * @wme_ac_type[WME_AC_MAX]: Wireless Multimedia type Count
  536. * @excess_retries_per_ac[WME_AC_MAX]: Wireless Multimedia type Count
  537. * @fw_rem: Discarded by firmware
  538. * @fw_rem_notx: firmware_discard_untransmitted
  539. * @fw_rem_tx: firmware_discard_transmitted
  540. * @age_out: aged out in mpdu/msdu queues
  541. * @fw_reason1: discarded by firmware reason 1
  542. * @fw_reason2: discarded by firmware reason 2
  543. * @fw_reason3: discarded by firmware reason 3
  544. * @mcs_count: MCS Count
  545. * @dot11_tx_pkts: dot11 tx packets
  546. * @an_tx_cnt: ald tx count
  547. * @an_tx_rates_used: ald rx rate used
  548. * @an_tx_bytes: ald tx bytes
  549. * @ald_txcount: ald tx count
  550. * @ald_lastper: ald last PER
  551. * @ald_max4msframelen: ald max frame len
  552. * @an_tx_ratecount: ald tx ratecount
  553. * @ald_retries: ald retries
  554. * @ald_ac_nobufs: #buffer overflows per node per AC
  555. * @ald_ac_excretries: #pkts dropped after excessive retries per node per AC
  556. * @rssi_chain: rssi chain
  557. * @inactive_time: inactive time in secs
  558. * @tx_ratecode: Tx rate code of last frame
  559. * @tx_flags: tx flags
  560. * @tx_power: Tx power latest
  561. * @is_tx_no_ack: no ack received
  562. * @is_tx_nodefkey: tx failed 'cuz no defkey
  563. * @is_tx_noheadroom: tx failed 'cuz no space
  564. * @is_crypto_enmicfail:
  565. * @is_tx_nonode: tx failed for no node
  566. * @is_tx_unknownmgt: tx of unknown mgt frame
  567. * @is_tx_badcipher: tx failed 'cuz key type
  568. * @ampdu_cnt: completion of aggregation
  569. * @non_ampdu_cnt: tx completion not aggregated
  570. * @failed_retry_count: packets failed due to retry above 802.11 retry limit
  571. * @retry_count: packets successfully send after one or more retry
  572. * @multiple_retry_count: packets successfully sent after more than one retry
  573. * @transmit_type: pkt info for tx transmit type
  574. * @mu_group_id: mumimo mu group id
  575. * @ru_start: RU start index
  576. * @ru_tones: RU tones size
  577. * @ru_loc: pkt info for RU location 26/ 52/ 106/ 242/ 484 counter
  578. * @num_ppdu_cookie_valid : Number of comp received with valid ppdu cookie
  579. */
  580. struct cdp_tx_stats {
  581. struct cdp_pkt_info comp_pkt;
  582. struct cdp_pkt_info ucast;
  583. struct cdp_pkt_info mcast;
  584. struct cdp_pkt_info bcast;
  585. struct cdp_pkt_info nawds_mcast;
  586. uint32_t nawds_mcast_drop;
  587. struct cdp_pkt_info tx_success;
  588. uint32_t tx_failed;
  589. uint32_t ofdma;
  590. uint32_t stbc;
  591. uint32_t ldpc;
  592. uint32_t retries;
  593. uint32_t non_amsdu_cnt;
  594. uint32_t amsdu_cnt;
  595. uint32_t tx_rate;
  596. uint32_t last_tx_rate;
  597. uint32_t last_tx_rate_mcs;
  598. uint32_t mcast_last_tx_rate;
  599. uint32_t mcast_last_tx_rate_mcs;
  600. uint32_t last_per;
  601. uint64_t rnd_avg_tx_rate;
  602. uint64_t avg_tx_rate;
  603. uint32_t last_ack_rssi;
  604. uint32_t tx_bytes_success_last;
  605. uint32_t tx_data_success_last;
  606. uint32_t tx_byte_rate;
  607. uint32_t tx_data_rate;
  608. uint32_t tx_data_ucast_last;
  609. uint32_t tx_data_ucast_rate;
  610. struct cdp_pkt_type pkt_type[DOT11_MAX];
  611. uint32_t sgi_count[MAX_GI];
  612. uint32_t nss[SS_COUNT];
  613. uint32_t bw[MAX_BW];
  614. uint32_t wme_ac_type[WME_AC_MAX];
  615. uint32_t excess_retries_per_ac[WME_AC_MAX];
  616. struct {
  617. struct cdp_pkt_info fw_rem;
  618. uint32_t fw_rem_notx;
  619. uint32_t fw_rem_tx;
  620. uint32_t age_out;
  621. uint32_t fw_reason1;
  622. uint32_t fw_reason2;
  623. uint32_t fw_reason3;
  624. } dropped;
  625. struct cdp_pkt_info dot11_tx_pkts;
  626. uint32_t fw_tx_cnt;
  627. uint32_t fw_tx_rates_used;
  628. uint32_t fw_tx_bytes;
  629. uint32_t fw_txcount;
  630. uint32_t fw_max4msframelen;
  631. uint32_t fw_ratecount;
  632. uint32_t ac_nobufs[WME_AC_MAX];
  633. uint32_t rssi_chain[WME_AC_MAX];
  634. uint32_t inactive_time;
  635. uint32_t tx_ratecode;
  636. uint32_t tx_flags;
  637. uint32_t tx_power;
  638. /* MSDUs which the target sent but couldn't get an ack for */
  639. struct cdp_pkt_info is_tx_no_ack;
  640. /*add for peer and upadted from ppdu*/
  641. uint32_t ampdu_cnt;
  642. uint32_t non_ampdu_cnt;
  643. uint32_t failed_retry_count;
  644. uint32_t retry_count;
  645. uint32_t multiple_retry_count;
  646. uint32_t last_tx_rate_used;
  647. struct cdp_tx_pkt_info transmit_type[MAX_TRANSMIT_TYPES];
  648. uint32_t mu_group_id[MAX_MU_GROUP_ID];
  649. uint32_t ru_start;
  650. uint32_t ru_tones;
  651. struct cdp_tx_pkt_info ru_loc[MAX_RU_LOCATIONS];
  652. uint32_t num_ppdu_cookie_valid;
  653. };
  654. /* struct cdp_rx_stats - rx Level Stats
  655. * @to_stack: Total packets sent up the stack
  656. * @rcvd_reo[CDP_MAX_RX_RINGS]: Packets received on the reo ring
  657. * @unicast: Total unicast packets
  658. * @multicast: Total multicast packets
  659. * @bcast: Broadcast Packet Count
  660. * @raw: Raw Pakets received
  661. * @nawds_mcast_drop: Total multicast packets
  662. * @mec_drop: Total MEC packets dropped
  663. * @pkts: Intra BSS packets received
  664. * @fail: Intra BSS packets failed
  665. * @mdns_no_fwd: Intra BSS MDNS packets not forwarded
  666. * @mic_err: Rx MIC errors CCMP
  667. * @decrypt_err: Rx Decryption Errors CRC
  668. * @fcserr: rx MIC check failed (CCMP)
  669. * @wme_ac_type[WME_AC_MAX]: Wireless Multimedia type Count
  670. * @reception_type[MAX_RECEPTION_TYPES]: Reception type os packets
  671. * @mcs_count[MAX_MCS]: mcs count
  672. * @sgi_count[MAX_GI]: sgi count
  673. * @nss[SS_COUNT]: packet count in spatiel Streams
  674. * @ppdu_nss[SS_COUNT]: PPDU packet count in spatial streams
  675. * @mpdu_cnt_fcs_ok: SU Rx success mpdu count
  676. * @mpdu_cnt_fcs_err: SU Rx fail mpdu count
  677. * @su_ax_ppdu_cnt: SU Rx packet count
  678. * @ppdu_cnt[MAX_RECEPTION_TYPES]: PPDU packet count in reception type
  679. * @rx_mu[RX_TYPE_MU_MAX]: Rx MU stats
  680. * @bw[MAX_BW]: Packet Count in different bandwidths
  681. * @non_ampdu_cnt: Number of MSDUs with no MPDU level aggregation
  682. * @ampdu_cnt: Number of MSDUs part of AMSPU
  683. * @non_amsdu_cnt: Number of MSDUs with no MSDU level aggregation
  684. * @amsdu_cnt: Number of MSDUs part of AMSDU
  685. * @bar_recv_cnt: Number of bar received
  686. * @rssi: RSSI of received signal
  687. * @last_rssi: Previous rssi
  688. * @avg_rssi: Average rssi
  689. * @rx_rate: Rx rate
  690. * @last_rx_rate: Previous rx rate
  691. * @rnd_avg_rx_rate: Rounded average rx rate
  692. * @avg_rx_rate: Average Rx rate
  693. * @dot11_rx_pkts: dot11 rx packets
  694. * @rx_bytes_last: last Rx success bytes
  695. * @rx_data_last: last rx success data
  696. * @rx_byte_rate: bytes received in last one sec
  697. * @rx_data_rate: data received in last one sec
  698. * @rx_retries: retries of packet in rx
  699. * @rx_mpdus: mpdu in rx
  700. * @rx_ppdus: ppdu in rx
  701. * @is_rx_tooshort: tooshort
  702. * @is_rx_decap: rx decap
  703. * @rx_ccmpmic: rx MIC check failed (CCMP)
  704. * @rx_tkipmic: rx MIC check failed (TKIP)
  705. * @rx_tkipicv: rx ICV check failed (TKIP)
  706. * @rx_wpimic: rx MIC check failed (WPI)
  707. * @rx_wepfail: rx wep processing failed
  708. * @rx_aggr: aggregation on rx
  709. * @rx_discard: packets discard in rx
  710. * @rx_ratecode: Rx rate code of last frame
  711. * @rx_flags: rx flags
  712. * @rx_rssi_measured_time: Time at which rssi is measured
  713. */
  714. struct cdp_rx_stats {
  715. struct cdp_pkt_info to_stack;
  716. struct cdp_pkt_info rcvd_reo[CDP_MAX_RX_RINGS];
  717. struct cdp_pkt_info unicast;
  718. struct cdp_pkt_info multicast;
  719. struct cdp_pkt_info bcast;
  720. struct cdp_pkt_info raw;
  721. uint32_t nawds_mcast_drop;
  722. struct cdp_pkt_info mec_drop;
  723. struct {
  724. struct cdp_pkt_info pkts;
  725. struct cdp_pkt_info fail;
  726. uint32_t mdns_no_fwd;
  727. } intra_bss;
  728. struct {
  729. uint32_t mic_err;
  730. uint32_t decrypt_err;
  731. uint32_t fcserr;
  732. } err;
  733. uint32_t wme_ac_type[WME_AC_MAX];
  734. uint32_t reception_type[MAX_RECEPTION_TYPES];
  735. struct cdp_pkt_type pkt_type[DOT11_MAX];
  736. uint32_t sgi_count[MAX_GI];
  737. uint32_t nss[SS_COUNT];
  738. uint32_t ppdu_nss[SS_COUNT];
  739. uint32_t mpdu_cnt_fcs_ok;
  740. uint32_t mpdu_cnt_fcs_err;
  741. struct cdp_pkt_type su_ax_ppdu_cnt;
  742. uint32_t ppdu_cnt[MAX_RECEPTION_TYPES];
  743. struct cdp_rx_mu rx_mu[RX_TYPE_MU_MAX];
  744. uint32_t bw[MAX_BW];
  745. uint32_t non_ampdu_cnt;
  746. uint32_t ampdu_cnt;
  747. uint32_t non_amsdu_cnt;
  748. uint32_t amsdu_cnt;
  749. uint32_t bar_recv_cnt;
  750. uint32_t rssi;
  751. uint32_t last_rssi;
  752. uint32_t avg_rssi;
  753. uint32_t rx_rate;
  754. uint32_t last_rx_rate;
  755. uint32_t rnd_avg_rx_rate;
  756. uint32_t avg_rx_rate;
  757. struct cdp_pkt_info dot11_rx_pkts;
  758. uint32_t rx_bytes_success_last;
  759. uint32_t rx_data_success_last;
  760. uint32_t rx_byte_rate;
  761. uint32_t rx_data_rate;
  762. uint32_t rx_retries;
  763. uint32_t rx_mpdus;
  764. uint32_t rx_ppdus;
  765. /*add for peer updated for ppdu*/
  766. uint32_t rx_aggr;
  767. uint32_t rx_discard;
  768. uint32_t rx_ratecode;
  769. uint32_t rx_flags;
  770. uint32_t rx_rssi_measured_time;
  771. };
  772. /* struct cdp_tx_ingress_stats - Tx ingress Stats
  773. * @rcvd: Total packets received for transmission
  774. * @processed: Tx packets processed
  775. * @inspect_pkts: Total packets passed to inspect handler
  776. * @nawds_mcast: NAWDS Multicast Packet Count
  777. * @bcast: Number of broadcast packets
  778. * @raw_pkt: Total Raw packets
  779. * @dma_map_error: DMA map error
  780. * @num_seg: No of segments in TSO packets
  781. * @tso_pkt:total no of TSO packets
  782. * @non_tso_pkts: non - TSO packets
  783. * @dropped_host: TSO packets dropped by host
  784. * @dropped_target:TSO packets dropped by target
  785. * @sg_pkt: Total scatter gather packets
  786. * @non_sg_pkts: non SG packets
  787. * @dropped_host: SG packets dropped by host
  788. * @dropped_target: SG packets dropped by target
  789. * @dma_map_error: Dma map error
  790. * @mcast_pkt: total no of multicast conversion packets
  791. * @dropped_map_error: packets dropped due to map error
  792. * @dropped_self_mac: packets dropped due to self Mac address
  793. * @dropped_send_fail: Packets dropped due to send fail
  794. * @ucast: total unicast packets transmitted
  795. * @fail_seg_alloc: Segment allocation failure
  796. * @clone_fail: NBUF clone failure
  797. * @dropped_pkt: Total scatter gather packets
  798. * @desc_na: Desc Not Available
  799. * @ring_full: ring full
  800. * @enqueue_fail: hw enqueue fail
  801. * @dma_error: dma fail
  802. * @res_full: Resource Full: Congestion Control
  803. * @exception_fw: packets sent to fw
  804. * @completion_fw: packets completions received from fw
  805. * @cce_classified:Number of packets classified by CCE
  806. * @cce_classified_raw:Number of raw packets classified by CCE
  807. * @sniffer_rcvd: Number of packets received with ppdu cookie
  808. */
  809. struct cdp_tx_ingress_stats {
  810. struct cdp_pkt_info rcvd;
  811. struct cdp_pkt_info processed;
  812. struct cdp_pkt_info reinject_pkts;
  813. struct cdp_pkt_info inspect_pkts;
  814. struct cdp_pkt_info nawds_mcast;
  815. struct cdp_pkt_info bcast;
  816. struct {
  817. struct cdp_pkt_info raw_pkt;
  818. uint32_t dma_map_error;
  819. uint32_t invalid_raw_pkt_datatype;
  820. } raw;
  821. /* Scatter Gather packet info */
  822. struct {
  823. struct cdp_pkt_info sg_pkt;
  824. struct cdp_pkt_info non_sg_pkts;
  825. struct cdp_pkt_info dropped_host;
  826. uint32_t dropped_target;
  827. uint32_t dma_map_error;
  828. } sg;
  829. /* Multicast Enhancement packets info */
  830. struct {
  831. struct cdp_pkt_info mcast_pkt;
  832. uint32_t dropped_map_error;
  833. uint32_t dropped_self_mac;
  834. uint32_t dropped_send_fail;
  835. uint32_t ucast;
  836. uint32_t fail_seg_alloc;
  837. uint32_t clone_fail;
  838. } mcast_en;
  839. /* Packets dropped on the Tx side */
  840. struct {
  841. struct cdp_pkt_info dropped_pkt;
  842. struct cdp_pkt_info desc_na;
  843. uint32_t ring_full;
  844. uint32_t enqueue_fail;
  845. uint32_t dma_error;
  846. uint32_t res_full;
  847. /* headroom insufficient */
  848. uint32_t headroom_insufficient;
  849. } dropped;
  850. /* Mesh packets info */
  851. struct {
  852. uint32_t exception_fw;
  853. uint32_t completion_fw;
  854. } mesh;
  855. uint32_t cce_classified;
  856. uint32_t cce_classified_raw;
  857. struct cdp_pkt_info sniffer_rcvd;
  858. struct cdp_tso_stats tso_stats;
  859. };
  860. /* struct cdp_vdev_stats - vdev stats structure
  861. * @tx_i: ingress tx stats
  862. * @tx: cdp tx stats
  863. * @rx: cdp rx stats
  864. * @tso_stats: tso stats
  865. */
  866. struct cdp_vdev_stats {
  867. struct cdp_tx_ingress_stats tx_i;
  868. struct cdp_tx_stats tx;
  869. struct cdp_rx_stats rx;
  870. struct cdp_tso_stats tso_stats;
  871. };
  872. /* struct cdp_peer_stats - peer stats structure
  873. * @tx: cdp tx stats
  874. * @rx: cdp rx stats
  875. */
  876. struct cdp_peer_stats {
  877. /* CDP Tx Stats */
  878. struct cdp_tx_stats tx;
  879. /* CDP Rx Stats */
  880. struct cdp_rx_stats rx;
  881. };
  882. /* struct cdp_interface_peer_stats - interface structure for txrx peer stats
  883. * @peer_hdl: control path peer handle
  884. * @last_peer_tx_rate: peer tx rate for last transmission
  885. * @peer_tx_rate: tx rate for current transmission
  886. * @peer_rssi: current rssi value of peer
  887. * @tx_packet_count: tx packet count
  888. * @rx_packet_count: rx packet count
  889. * @tx_byte_count: tx byte count
  890. * @rx_byte_count: rx byte count
  891. * @per: per error rate
  892. * @ack_rssi: RSSI of the last ack received
  893. * @rssi_changed: denotes rssi is changed
  894. */
  895. struct cdp_interface_peer_stats {
  896. void *peer_hdl;
  897. uint32_t last_peer_tx_rate;
  898. uint32_t peer_tx_rate;
  899. uint32_t peer_rssi;
  900. uint32_t tx_packet_count;
  901. uint32_t rx_packet_count;
  902. uint32_t tx_byte_count;
  903. uint32_t rx_byte_count;
  904. uint32_t per;
  905. uint32_t ack_rssi;
  906. uint8_t rssi_changed;
  907. };
  908. /* Tx completions per interrupt */
  909. struct cdp_hist_tx_comp {
  910. uint32_t pkts_1;
  911. uint32_t pkts_2_20;
  912. uint32_t pkts_21_40;
  913. uint32_t pkts_41_60;
  914. uint32_t pkts_61_80;
  915. uint32_t pkts_81_100;
  916. uint32_t pkts_101_200;
  917. uint32_t pkts_201_plus;
  918. };
  919. /* Rx ring descriptors reaped per interrupt */
  920. struct cdp_hist_rx_ind {
  921. uint32_t pkts_1;
  922. uint32_t pkts_2_20;
  923. uint32_t pkts_21_40;
  924. uint32_t pkts_41_60;
  925. uint32_t pkts_61_80;
  926. uint32_t pkts_81_100;
  927. uint32_t pkts_101_200;
  928. uint32_t pkts_201_plus;
  929. };
  930. struct cdp_htt_tlv_hdr {
  931. /* BIT [11 : 0] :- tag
  932. * BIT [23 : 12] :- length
  933. * BIT [31 : 24] :- reserved
  934. */
  935. uint32_t tag__length;
  936. };
  937. #define HTT_STATS_SUBTYPE_MAX 16
  938. struct cdp_htt_rx_pdev_fw_stats_tlv {
  939. struct cdp_htt_tlv_hdr tlv_hdr;
  940. /* BIT [ 7 : 0] :- mac_id
  941. * BIT [31 : 8] :- reserved
  942. */
  943. uint32_t mac_id__word;
  944. /* Num PPDU status processed from HW */
  945. uint32_t ppdu_recvd;
  946. /* Num MPDU across PPDUs with FCS ok */
  947. uint32_t mpdu_cnt_fcs_ok;
  948. /* Num MPDU across PPDUs with FCS err */
  949. uint32_t mpdu_cnt_fcs_err;
  950. /* Num MSDU across PPDUs */
  951. uint32_t tcp_msdu_cnt;
  952. /* Num MSDU across PPDUs */
  953. uint32_t tcp_ack_msdu_cnt;
  954. /* Num MSDU across PPDUs */
  955. uint32_t udp_msdu_cnt;
  956. /* Num MSDU across PPDUs */
  957. uint32_t other_msdu_cnt;
  958. /* Num MPDU on FW ring indicated */
  959. uint32_t fw_ring_mpdu_ind;
  960. /* Num MGMT MPDU given to protocol */
  961. uint32_t fw_ring_mgmt_subtype[HTT_STATS_SUBTYPE_MAX];
  962. /* Num ctrl MPDU given to protocol */
  963. uint32_t fw_ring_ctrl_subtype[HTT_STATS_SUBTYPE_MAX];
  964. /* Num mcast data packet received */
  965. uint32_t fw_ring_mcast_data_msdu;
  966. /* Num broadcast data packet received */
  967. uint32_t fw_ring_bcast_data_msdu;
  968. /* Num unicat data packet received */
  969. uint32_t fw_ring_ucast_data_msdu;
  970. /* Num null data packet received */
  971. uint32_t fw_ring_null_data_msdu;
  972. /* Num MPDU on FW ring dropped */
  973. uint32_t fw_ring_mpdu_drop;
  974. /* Num buf indication to offload */
  975. uint32_t ofld_local_data_ind_cnt;
  976. /* Num buf recycle from offload */
  977. uint32_t ofld_local_data_buf_recycle_cnt;
  978. /* Num buf indication to data_rx */
  979. uint32_t drx_local_data_ind_cnt;
  980. /* Num buf recycle from data_rx */
  981. uint32_t drx_local_data_buf_recycle_cnt;
  982. /* Num buf indication to protocol */
  983. uint32_t local_nondata_ind_cnt;
  984. /* Num buf recycle from protocol */
  985. uint32_t local_nondata_buf_recycle_cnt;
  986. /* Num buf fed */
  987. uint32_t fw_status_buf_ring_refill_cnt;
  988. /* Num ring empty encountered */
  989. uint32_t fw_status_buf_ring_empty_cnt;
  990. /* Num buf fed */
  991. uint32_t fw_pkt_buf_ring_refill_cnt;
  992. /* Num ring empty encountered */
  993. uint32_t fw_pkt_buf_ring_empty_cnt;
  994. /* Num buf fed */
  995. uint32_t fw_link_buf_ring_refill_cnt;
  996. /* Num ring empty encountered */
  997. uint32_t fw_link_buf_ring_empty_cnt;
  998. /* Num buf fed */
  999. uint32_t host_pkt_buf_ring_refill_cnt;
  1000. /* Num ring empty encountered */
  1001. uint32_t host_pkt_buf_ring_empty_cnt;
  1002. /* Num buf fed */
  1003. uint32_t mon_pkt_buf_ring_refill_cnt;
  1004. /* Num ring empty encountered */
  1005. uint32_t mon_pkt_buf_ring_empty_cnt;
  1006. /* Num buf fed */
  1007. uint32_t mon_status_buf_ring_refill_cnt;
  1008. /* Num ring empty encountered */
  1009. uint32_t mon_status_buf_ring_empty_cnt;
  1010. /* Num buf fed */
  1011. uint32_t mon_desc_buf_ring_refill_cnt;
  1012. /* Num ring empty encountered */
  1013. uint32_t mon_desc_buf_ring_empty_cnt;
  1014. /* Num buf fed */
  1015. uint32_t mon_dest_ring_update_cnt;
  1016. /* Num ring full encountered */
  1017. uint32_t mon_dest_ring_full_cnt;
  1018. /* Num rx suspend is attempted */
  1019. uint32_t rx_suspend_cnt;
  1020. /* Num rx suspend failed */
  1021. uint32_t rx_suspend_fail_cnt;
  1022. /* Num rx resume attempted */
  1023. uint32_t rx_resume_cnt;
  1024. /* Num rx resume failed */
  1025. uint32_t rx_resume_fail_cnt;
  1026. /* Num rx ring switch */
  1027. uint32_t rx_ring_switch_cnt;
  1028. /* Num rx ring restore */
  1029. uint32_t rx_ring_restore_cnt;
  1030. /* Num rx flush issued */
  1031. uint32_t rx_flush_cnt;
  1032. };
  1033. /* == TX PDEV STATS == */
  1034. struct cdp_htt_tx_pdev_stats_cmn_tlv {
  1035. struct cdp_htt_tlv_hdr tlv_hdr;
  1036. /* BIT [ 7 : 0] :- mac_id
  1037. * BIT [31 : 8] :- reserved
  1038. */
  1039. uint32_t mac_id__word;
  1040. /* Num queued to HW */
  1041. uint32_t hw_queued;
  1042. /* Num PPDU reaped from HW */
  1043. uint32_t hw_reaped;
  1044. /* Num underruns */
  1045. uint32_t underrun;
  1046. /* Num HW Paused counter. */
  1047. uint32_t hw_paused;
  1048. /* Num HW flush counter. */
  1049. uint32_t hw_flush;
  1050. /* Num HW filtered counter. */
  1051. uint32_t hw_filt;
  1052. /* Num PPDUs cleaned up in TX abort */
  1053. uint32_t tx_abort;
  1054. /* Num MPDUs requed by SW */
  1055. uint32_t mpdu_requed;
  1056. /* excessive retries */
  1057. uint32_t tx_xretry;
  1058. /* Last used data hw rate code */
  1059. uint32_t data_rc;
  1060. /* frames dropped due to excessive sw retries */
  1061. uint32_t mpdu_dropped_xretry;
  1062. /* illegal rate phy errors */
  1063. uint32_t illgl_rate_phy_err;
  1064. /* wal pdev continuous xretry */
  1065. uint32_t cont_xretry;
  1066. /* wal pdev continuous xretry */
  1067. uint32_t tx_timeout;
  1068. /* wal pdev resets */
  1069. uint32_t pdev_resets;
  1070. /* PhY/BB underrun */
  1071. uint32_t phy_underrun;
  1072. /* MPDU is more than txop limit */
  1073. uint32_t txop_ovf;
  1074. /* Number of Sequences posted */
  1075. uint32_t seq_posted;
  1076. /* Number of Sequences failed queueing */
  1077. uint32_t seq_failed_queueing;
  1078. /* Number of Sequences completed */
  1079. uint32_t seq_completed;
  1080. /* Number of Sequences restarted */
  1081. uint32_t seq_restarted;
  1082. /* Number of MU Sequences posted */
  1083. uint32_t mu_seq_posted;
  1084. /* Number of time HW ring is paused between seq switch within ISR */
  1085. uint32_t seq_switch_hw_paused;
  1086. /* Number of times seq continuation in DSR */
  1087. uint32_t next_seq_posted_dsr;
  1088. /* Number of times seq continuation in ISR */
  1089. uint32_t seq_posted_isr;
  1090. /* Number of seq_ctrl cached. */
  1091. uint32_t seq_ctrl_cached;
  1092. /* Number of MPDUs successfully transmitted */
  1093. uint32_t mpdu_count_tqm;
  1094. /* Number of MSDUs successfully transmitted */
  1095. uint32_t msdu_count_tqm;
  1096. /* Number of MPDUs dropped */
  1097. uint32_t mpdu_removed_tqm;
  1098. /* Number of MSDUs dropped */
  1099. uint32_t msdu_removed_tqm;
  1100. /* Num MPDUs flushed by SW, HWPAUSED, SW TXABORT (Reset,channel change) */
  1101. uint32_t mpdus_sw_flush;
  1102. /* Num MPDUs filtered by HW, all filter condition (TTL expired) */
  1103. uint32_t mpdus_hw_filter;
  1104. /* Num MPDUs truncated by PDG (TXOP, TBTT, PPDU_duration based on rate, dyn_bw) */
  1105. uint32_t mpdus_truncated;
  1106. /* Num MPDUs that was tried but didn't receive ACK or BA */
  1107. uint32_t mpdus_ack_failed;
  1108. /* Num MPDUs that was dropped due to expiry (MSDU TTL). */
  1109. uint32_t mpdus_expired;
  1110. /* Num MPDUs that was retried within seq_ctrl (MGMT/LEGACY) */
  1111. uint32_t mpdus_seq_hw_retry;
  1112. /* Num of TQM acked cmds processed */
  1113. uint32_t ack_tlv_proc;
  1114. /* coex_abort_mpdu_cnt valid. */
  1115. uint32_t coex_abort_mpdu_cnt_valid;
  1116. /* coex_abort_mpdu_cnt from TX FES stats. */
  1117. uint32_t coex_abort_mpdu_cnt;
  1118. /* Number of total PPDUs(DATA, MGMT, excludes selfgen) tried over the air (OTA) */
  1119. uint32_t num_total_ppdus_tried_ota;
  1120. /* Number of data PPDUs tried over the air (OTA) */
  1121. uint32_t num_data_ppdus_tried_ota;
  1122. /* Num Local control/mgmt frames (MSDUs) queued */
  1123. uint32_t local_ctrl_mgmt_enqued;
  1124. /* local_ctrl_mgmt_freed:
  1125. * Num Local control/mgmt frames (MSDUs) done
  1126. * It includes all local ctrl/mgmt completions
  1127. * (acked, no ack, flush, TTL, etc)
  1128. */
  1129. uint32_t local_ctrl_mgmt_freed;
  1130. /* Num Local data frames (MSDUs) queued */
  1131. uint32_t local_data_enqued;
  1132. /* local_data_freed:
  1133. * Num Local data frames (MSDUs) done
  1134. * It includes all local data completions
  1135. * (acked, no ack, flush, TTL, etc)
  1136. */
  1137. uint32_t local_data_freed;
  1138. /* Num MPDUs tried by SW */
  1139. uint32_t mpdu_tried;
  1140. /* Num of waiting seq posted in isr completion handler */
  1141. uint32_t isr_wait_seq_posted;
  1142. uint32_t tx_active_dur_us_low;
  1143. uint32_t tx_active_dur_us_high;
  1144. };
  1145. struct cdp_htt_tx_pdev_stats_urrn_tlv_v {
  1146. struct cdp_htt_tlv_hdr tlv_hdr;
  1147. uint32_t urrn_stats[1]; /* HTT_TX_PDEV_MAX_URRN_STATS */
  1148. };
  1149. /* NOTE: Variable length TLV, use length spec to infer array size */
  1150. struct cdp_htt_tx_pdev_stats_flush_tlv_v {
  1151. struct cdp_htt_tlv_hdr tlv_hdr;
  1152. uint32_t flush_errs[1]; /* HTT_TX_PDEV_MAX_FLUSH_REASON_STATS */
  1153. };
  1154. /* NOTE: Variable length TLV, use length spec to infer array size */
  1155. struct cdp_htt_tx_pdev_stats_sifs_tlv_v {
  1156. struct cdp_htt_tlv_hdr tlv_hdr;
  1157. uint32_t sifs_status[1]; /* HTT_TX_PDEV_MAX_SIFS_BURST_STATS */
  1158. };
  1159. /* NOTE: Variable length TLV, use length spec to infer array size */
  1160. struct cdp_htt_tx_pdev_stats_phy_err_tlv_v {
  1161. struct cdp_htt_tlv_hdr tlv_hdr;
  1162. uint32_t phy_errs[1]; /* HTT_TX_PDEV_MAX_PHY_ERR_STATS */
  1163. };
  1164. /* == RX PDEV/SOC STATS == */
  1165. /* HTT_STATS_RX_SOC_FW_STATS_TAG */
  1166. struct cdp_htt_rx_soc_fw_stats_tlv {
  1167. struct cdp_htt_tlv_hdr tlv_hdr;
  1168. /* Num Packets received on REO FW ring */
  1169. uint32_t fw_reo_ring_data_msdu;
  1170. /* Num bc/mc packets indicated from fw to host */
  1171. uint32_t fw_to_host_data_msdu_bcmc;
  1172. /* Num unicast packets indicated from fw to host */
  1173. uint32_t fw_to_host_data_msdu_uc;
  1174. /* Num remote buf recycle from offload */
  1175. uint32_t ofld_remote_data_buf_recycle_cnt;
  1176. /* Num remote free buf given to offload */
  1177. uint32_t ofld_remote_free_buf_indication_cnt;
  1178. };
  1179. struct cdp_htt_rx_soc_fw_refill_ring_num_refill_tlv_v {
  1180. struct cdp_htt_tlv_hdr tlv_hdr;
  1181. /* Num total buf refilled from refill ring */
  1182. uint32_t refill_ring_num_refill[1]; /* HTT_RX_STATS_REFILL_MAX_RING */
  1183. };
  1184. struct cdp_htt_rx_pdev_fw_ring_mpdu_err_tlv_v {
  1185. struct cdp_htt_tlv_hdr tlv_hdr;
  1186. /* Num error MPDU for each RxDMA error type */
  1187. uint32_t fw_ring_mpdu_err[1]; /* HTT_RX_STATS_RXDMA_MAX_ERR */
  1188. };
  1189. struct cdp_htt_rx_pdev_fw_mpdu_drop_tlv_v {
  1190. struct cdp_htt_tlv_hdr tlv_hdr;
  1191. /* Num MPDU dropped */
  1192. uint32_t fw_mpdu_drop[1]; /* HTT_RX_STATS_FW_DROP_REASON_MAX */
  1193. };
  1194. #define HTT_STATS_PHY_ERR_MAX 43
  1195. struct cdp_htt_rx_pdev_fw_stats_phy_err_tlv {
  1196. struct cdp_htt_tlv_hdr tlv_hdr;
  1197. /* BIT [ 7 : 0] :- mac_id
  1198. * BIT [31 : 8] :- reserved
  1199. */
  1200. uint32_t mac_id__word;
  1201. /* Num of phy err */
  1202. uint32_t total_phy_err_cnt;
  1203. /* Counts of different types of phy errs
  1204. * The mapping of PHY error types to phy_err array elements is HW dependent.
  1205. * The only currently-supported mapping is shown below:
  1206. *
  1207. * 0 phyrx_err_phy_off Reception aborted due to receiving a PHY_OFF TLV
  1208. * 1 phyrx_err_synth_off
  1209. * 2 phyrx_err_ofdma_timing
  1210. * 3 phyrx_err_ofdma_signal_parity
  1211. * 4 phyrx_err_ofdma_rate_illegal
  1212. * 5 phyrx_err_ofdma_length_illegal
  1213. * 6 phyrx_err_ofdma_restart
  1214. * 7 phyrx_err_ofdma_service
  1215. * 8 phyrx_err_ppdu_ofdma_power_drop
  1216. * 9 phyrx_err_cck_blokker
  1217. * 10 phyrx_err_cck_timing
  1218. * 11 phyrx_err_cck_header_crc
  1219. * 12 phyrx_err_cck_rate_illegal
  1220. * 13 phyrx_err_cck_length_illegal
  1221. * 14 phyrx_err_cck_restart
  1222. * 15 phyrx_err_cck_service
  1223. * 16 phyrx_err_cck_power_drop
  1224. * 17 phyrx_err_ht_crc_err
  1225. * 18 phyrx_err_ht_length_illegal
  1226. * 19 phyrx_err_ht_rate_illegal
  1227. * 20 phyrx_err_ht_zlf
  1228. * 21 phyrx_err_false_radar_ext
  1229. * 22 phyrx_err_green_field
  1230. * 23 phyrx_err_bw_gt_dyn_bw
  1231. * 24 phyrx_err_leg_ht_mismatch
  1232. * 25 phyrx_err_vht_crc_error
  1233. * 26 phyrx_err_vht_siga_unsupported
  1234. * 27 phyrx_err_vht_lsig_len_invalid
  1235. * 28 phyrx_err_vht_ndp_or_zlf
  1236. * 29 phyrx_err_vht_nsym_lt_zero
  1237. * 30 phyrx_err_vht_rx_extra_symbol_mismatch
  1238. * 31 phyrx_err_vht_rx_skip_group_id0
  1239. * 32 phyrx_err_vht_rx_skip_group_id1to62
  1240. * 33 phyrx_err_vht_rx_skip_group_id63
  1241. * 34 phyrx_err_ofdm_ldpc_decoder_disabled
  1242. * 35 phyrx_err_defer_nap
  1243. * 36 phyrx_err_fdomain_timeout
  1244. * 37 phyrx_err_lsig_rel_check
  1245. * 38 phyrx_err_bt_collision
  1246. * 39 phyrx_err_unsupported_mu_feedback
  1247. * 40 phyrx_err_ppdu_tx_interrupt_rx
  1248. * 41 phyrx_err_unsupported_cbf
  1249. * 42 phyrx_err_other
  1250. */
  1251. uint32_t phy_err[HTT_STATS_PHY_ERR_MAX];
  1252. };
  1253. struct cdp_htt_rx_soc_fw_refill_ring_empty_tlv_v {
  1254. struct cdp_htt_tlv_hdr tlv_hdr;
  1255. /* Num ring empty encountered */
  1256. uint32_t refill_ring_empty_cnt[1]; /* HTT_RX_STATS_REFILL_MAX_RING */
  1257. };
  1258. struct cdp_htt_tx_pdev_stats {
  1259. struct cdp_htt_tx_pdev_stats_cmn_tlv cmn_tlv;
  1260. struct cdp_htt_tx_pdev_stats_urrn_tlv_v underrun_tlv;
  1261. struct cdp_htt_tx_pdev_stats_sifs_tlv_v sifs_tlv;
  1262. struct cdp_htt_tx_pdev_stats_flush_tlv_v flush_tlv;
  1263. struct cdp_htt_tx_pdev_stats_phy_err_tlv_v phy_err_tlv;
  1264. };
  1265. struct cdp_htt_rx_soc_stats_t {
  1266. struct cdp_htt_rx_soc_fw_stats_tlv fw_tlv;
  1267. struct cdp_htt_rx_soc_fw_refill_ring_empty_tlv_v fw_refill_ring_empty_tlv;
  1268. struct cdp_htt_rx_soc_fw_refill_ring_num_refill_tlv_v fw_refill_ring_num_refill_tlv;
  1269. };
  1270. struct cdp_htt_rx_pdev_stats {
  1271. struct cdp_htt_rx_soc_stats_t soc_stats;
  1272. struct cdp_htt_rx_pdev_fw_stats_tlv fw_stats_tlv;
  1273. struct cdp_htt_rx_pdev_fw_ring_mpdu_err_tlv_v fw_ring_mpdu_err_tlv;
  1274. struct cdp_htt_rx_pdev_fw_mpdu_drop_tlv_v fw_ring_mpdu_drop;
  1275. struct cdp_htt_rx_pdev_fw_stats_phy_err_tlv fw_stats_phy_err_tlv;
  1276. };
  1277. #ifdef WLAN_SUPPORT_RX_PROTOCOL_TYPE_TAG
  1278. /* Since protocol type enumeration value is passed as CCE metadata
  1279. * to firmware, add a constant offset before passing it to firmware
  1280. */
  1281. #define RX_PROTOCOL_TAG_START_OFFSET 128
  1282. /* This should align with packet type enumerations in ieee80211_ioctl.h
  1283. * and wmi_unified_param.h files
  1284. */
  1285. #define RX_PROTOCOL_TAG_MAX 24
  1286. /* Macro that should be used to dump the statistics counter for all
  1287. * protocol types
  1288. */
  1289. #define RX_PROTOCOL_TAG_ALL 0xff
  1290. #endif /* WLAN_SUPPORT_RX_PROTOCOL_TYPE_TAG */
  1291. #define OFDMA_NUM_RU_SIZE 7
  1292. #define OFDMA_NUM_USERS 37
  1293. /* struct cdp_pdev_stats - pdev stats
  1294. * @msdu_not_done: packets dropped because msdu done bit not set
  1295. * @mec:Multicast Echo check
  1296. * @mesh_filter: Mesh Filtered packets
  1297. * @mon_rx_drop: packets dropped on monitor vap
  1298. * @wifi_parse: rxdma errors due to wifi parse error
  1299. * @mon_radiotap_update_err: not enough space to update radiotap
  1300. * @pkts: total packets replenished
  1301. * @rxdma_err: rxdma errors for replenished
  1302. * @nbuf_alloc_fail: nbuf alloc failed
  1303. * @map_err: Mapping failure
  1304. * @x86_fail: x86 failures
  1305. * @low_thresh_intrs: low threshold interrupts
  1306. * @rx_raw_pkts: Rx Raw Packets
  1307. * @mesh_mem_alloc: Mesh Rx Stats Alloc fail
  1308. * @tso_desc_cnt: TSO descriptors
  1309. * @sg_desc_cnt: SG Descriptors
  1310. * @vlan_tag_stp_cnt: Vlan tagged Stp packets in wifi parse error
  1311. * @desc_alloc_fail: desc alloc failed errors
  1312. * @ip_csum_err: ip checksum errors
  1313. * @tcp_udp_csum_err: tcp/udp checksum errors
  1314. * @buf_freelist: buffers added back in freelist
  1315. * @tx_i: Tx Ingress stats
  1316. * @tx:CDP Tx Stats
  1317. * @rx: CDP Rx Stats
  1318. * @tx_comp_histogram: Number of Tx completions per interrupt
  1319. * @rx_ind_histogram: Number of Rx ring descriptors reaped per interrupt
  1320. * @ppdu_stats_counter: ppdu stats counter
  1321. * @cdp_delayed_ba_not_recev: counter for delayed ba not received
  1322. * @htt_tx_pdev_stats: htt pdev stats for tx
  1323. * @htt_rx_pdev_stats: htt pdev stats for rx
  1324. * @data_rx_ru_size: UL ofdma data ru size counter array
  1325. * @nondata_rx_ru_size: UL ofdma non data ru size counter array
  1326. * @data_rx_ppdu: data rx ppdu counter
  1327. * @data_user: data user counter array
  1328. */
  1329. struct cdp_pdev_stats {
  1330. struct {
  1331. uint32_t msdu_not_done;
  1332. uint32_t mec;
  1333. uint32_t mesh_filter;
  1334. uint32_t wifi_parse;
  1335. /* Monitor mode related */
  1336. uint32_t mon_rx_drop;
  1337. uint32_t mon_radiotap_update_err;
  1338. } dropped;
  1339. struct {
  1340. struct cdp_pkt_info pkts;
  1341. uint32_t rxdma_err;
  1342. uint32_t nbuf_alloc_fail;
  1343. uint32_t map_err;
  1344. uint32_t x86_fail;
  1345. uint32_t low_thresh_intrs;
  1346. } replenish;
  1347. uint32_t rx_raw_pkts;
  1348. uint32_t mesh_mem_alloc;
  1349. uint32_t tso_desc_cnt;
  1350. uint32_t sg_desc_cnt;
  1351. uint32_t vlan_tag_stp_cnt;
  1352. /* Rx errors */
  1353. struct {
  1354. uint32_t desc_alloc_fail;
  1355. uint32_t ip_csum_err;
  1356. uint32_t tcp_udp_csum_err;
  1357. uint32_t rxdma_error;
  1358. uint32_t reo_error;
  1359. } err;
  1360. uint32_t buf_freelist;
  1361. struct cdp_tx_ingress_stats tx_i;
  1362. struct cdp_tx_stats tx;
  1363. struct cdp_rx_stats rx;
  1364. struct cdp_hist_tx_comp tx_comp_histogram;
  1365. struct cdp_hist_rx_ind rx_ind_histogram;
  1366. uint64_t ppdu_stats_counter[CDP_PPDU_STATS_MAX_TAG];
  1367. uint32_t cdp_delayed_ba_not_recev;
  1368. struct cdp_htt_tx_pdev_stats htt_tx_pdev_stats;
  1369. struct cdp_htt_rx_pdev_stats htt_rx_pdev_stats;
  1370. /* Received wdi messages from fw */
  1371. uint32_t wdi_event[CDP_WDI_NUM_EVENTS];
  1372. struct cdp_tid_stats tid_stats;
  1373. /* numbers of data/nondata per RU sizes */
  1374. struct {
  1375. uint32_t data_rx_ru_size[OFDMA_NUM_RU_SIZE];
  1376. uint32_t nondata_rx_ru_size[OFDMA_NUM_RU_SIZE];
  1377. uint32_t data_rx_ppdu;
  1378. uint32_t data_users[OFDMA_NUM_USERS];
  1379. } ul_ofdma;
  1380. struct cdp_tso_stats tso_stats;
  1381. };
  1382. #ifdef QCA_ENH_V3_STATS_SUPPORT
  1383. /*
  1384. * Enumeration of PDEV Configuration parameter
  1385. */
  1386. enum _ol_ath_param_t {
  1387. OL_ATH_PARAM_TXCHAINMASK = 1,
  1388. OL_ATH_PARAM_RXCHAINMASK = 2,
  1389. OL_ATH_PARAM_AMPDU = 6,
  1390. OL_ATH_PARAM_AMPDU_LIMIT = 7,
  1391. OL_ATH_PARAM_AMPDU_SUBFRAMES = 8,
  1392. OL_ATH_PARAM_TXPOWER_LIMIT2G = 12,
  1393. OL_ATH_PARAM_TXPOWER_LIMIT5G = 13,
  1394. OL_ATH_PARAM_LDPC = 32,
  1395. OL_ATH_PARAM_VOW_EXT_STATS = 45,
  1396. OL_ATH_PARAM_DYN_TX_CHAINMASK = 73,
  1397. OL_ATH_PARAM_BURST_ENABLE = 77,
  1398. OL_ATH_PARAM_BURST_DUR = 78,
  1399. OL_ATH_PARAM_BCN_BURST = 80,
  1400. OL_ATH_PARAM_DCS = 82,
  1401. #if UMAC_SUPPORT_PERIODIC_PERFSTATS
  1402. OL_ATH_PARAM_PRDPERFSTAT_THRPUT_ENAB = 83,
  1403. OL_ATH_PARAM_PRDPERFSTAT_THRPUT_WIN = 84,
  1404. OL_ATH_PARAM_PRDPERFSTAT_THRPUT = 85,
  1405. OL_ATH_PARAM_PRDPERFSTAT_PER_ENAB = 86,
  1406. OL_ATH_PARAM_PRDPERFSTAT_PER_WIN = 87,
  1407. OL_ATH_PARAM_PRDPERFSTAT_PER = 88,
  1408. #endif
  1409. /* UMAC_SUPPORT_PERIODIC_PERFSTATS */
  1410. OL_ATH_PARAM_TOTAL_PER = 89,
  1411. /* set manual rate for rts frame */
  1412. OL_ATH_PARAM_RTS_CTS_RATE = 92,
  1413. /* co channel interference threshold level */
  1414. OL_ATH_PARAM_DCS_COCH_THR = 93,
  1415. /* transmit error threshold */
  1416. OL_ATH_PARAM_DCS_TXERR_THR = 94,
  1417. /* phy error threshold */
  1418. OL_ATH_PARAM_DCS_PHYERR_THR = 95,
  1419. /*
  1420. * The IOCTL number is 114, it is made 114, inorder to make the IOCTL
  1421. * number same as Direct-attach IOCTL.
  1422. * Please, don't change number. This IOCTL gets the Interface code path
  1423. * it should be either DIRECT-ATTACH or OFF-LOAD.
  1424. */
  1425. OL_ATH_PARAM_GET_IF_ID = 114,
  1426. /* Enable Acs back Ground Channel selection Scan timer in AP mode*/
  1427. OL_ATH_PARAM_ACS_ENABLE_BK_SCANTIMEREN = 118,
  1428. /* ACS scan timer value in Seconds */
  1429. OL_ATH_PARAM_ACS_SCANTIME = 119,
  1430. /* Negligence Delta RSSI between two channel */
  1431. OL_ATH_PARAM_ACS_RSSIVAR = 120,
  1432. /* Negligence Delta Channel load between two channel*/
  1433. OL_ATH_PARAM_ACS_CHLOADVAR = 121,
  1434. /* Enable Limited OBSS check */
  1435. OL_ATH_PARAM_ACS_LIMITEDOBSS = 122,
  1436. /* Acs control flag for Scan timer */
  1437. OL_ATH_PARAM_ACS_CTRLFLAG = 123,
  1438. /* Acs Run time Debug level*/
  1439. OL_ATH_PARAM_ACS_DEBUGTRACE = 124,
  1440. OL_ATH_PARAM_SET_FW_HANG_ID = 137,
  1441. /* Radio type 1:11ac 0:11abgn */
  1442. OL_ATH_PARAM_RADIO_TYPE = 138,
  1443. OL_ATH_PARAM_IGMPMLD_OVERRIDE, /* IGMP/MLD packet override */
  1444. OL_ATH_PARAM_IGMPMLD_TID, /* IGMP/MLD packet TID no */
  1445. OL_ATH_PARAM_ARPDHCP_AC_OVERRIDE,
  1446. OL_ATH_PARAM_NON_AGG_SW_RETRY_TH,
  1447. OL_ATH_PARAM_AGG_SW_RETRY_TH,
  1448. /* Dont change this number it as per sync with DA
  1449. Blocking certian channel from ic channel list */
  1450. OL_ATH_PARAM_DISABLE_DFS = 144,
  1451. OL_ATH_PARAM_ENABLE_AMSDU = 145,
  1452. OL_ATH_PARAM_ENABLE_AMPDU = 146,
  1453. OL_ATH_PARAM_STA_KICKOUT_TH,
  1454. OL_ATH_PARAM_WLAN_PROF_ENABLE,
  1455. OL_ATH_PARAM_LTR_ENABLE,
  1456. OL_ATH_PARAM_LTR_AC_LATENCY_BE = 150,
  1457. OL_ATH_PARAM_LTR_AC_LATENCY_BK,
  1458. OL_ATH_PARAM_LTR_AC_LATENCY_VI,
  1459. OL_ATH_PARAM_LTR_AC_LATENCY_VO,
  1460. OL_ATH_PARAM_LTR_AC_LATENCY_TIMEOUT,
  1461. OL_ATH_PARAM_LTR_TX_ACTIVITY_TIMEOUT = 155,
  1462. OL_ATH_PARAM_LTR_SLEEP_OVERRIDE,
  1463. OL_ATH_PARAM_LTR_RX_OVERRIDE,
  1464. OL_ATH_PARAM_L1SS_ENABLE,
  1465. OL_ATH_PARAM_DSLEEP_ENABLE,
  1466. /* radar error threshold */
  1467. OL_ATH_PARAM_DCS_RADAR_ERR_THR = 160,
  1468. /* Tx channel utilization due to AP's tx and rx */
  1469. OL_ATH_PARAM_DCS_USERMAX_CU_THR,
  1470. /* interference detection threshold */
  1471. OL_ATH_PARAM_DCS_INTR_DETECT_THR,
  1472. /* sampling window, default 10secs */
  1473. OL_ATH_PARAM_DCS_SAMPLE_WINDOW,
  1474. /* debug logs enable/disable */
  1475. OL_ATH_PARAM_DCS_DEBUG,
  1476. OL_ATH_PARAM_ANI_ENABLE = 165,
  1477. OL_ATH_PARAM_ANI_POLL_PERIOD,
  1478. OL_ATH_PARAM_ANI_LISTEN_PERIOD,
  1479. OL_ATH_PARAM_ANI_OFDM_LEVEL,
  1480. OL_ATH_PARAM_ANI_CCK_LEVEL,
  1481. OL_ATH_PARAM_DSCP_TID_MAP = 170,
  1482. OL_ATH_PARAM_TXPOWER_SCALE,
  1483. /* Phy error penalty */
  1484. OL_ATH_PARAM_DCS_PHYERR_PENALTY,
  1485. #if ATH_SUPPORT_DSCP_OVERRIDE
  1486. /* set/get TID for sending HMMC packets */
  1487. OL_ATH_PARAM_HMMC_DSCP_TID_MAP,
  1488. /* set/get DSCP mapping override */
  1489. OL_ATH_PARAM_DSCP_OVERRIDE,
  1490. /* set/get HMMC-DSCP mapping override */
  1491. OL_ATH_PARAM_HMMC_DSCP_OVERRIDE = 175,
  1492. #endif
  1493. #if ATH_RX_LOOPLIMIT_TIMER
  1494. OL_ATH_PARAM_LOOPLIMIT_NUM,
  1495. #endif
  1496. OL_ATH_PARAM_ANTENNA_GAIN_2G,
  1497. OL_ATH_PARAM_ANTENNA_GAIN_5G,
  1498. OL_ATH_PARAM_RX_FILTER,
  1499. #if ATH_SUPPORT_HYFI_ENHANCEMENTS
  1500. OL_ATH_PARAM_BUFF_THRESH = 180,
  1501. OL_ATH_PARAM_BLK_REPORT_FLOOD,
  1502. OL_ATH_PARAM_DROP_STA_QUERY,
  1503. #endif
  1504. OL_ATH_PARAM_QBOOST,
  1505. OL_ATH_PARAM_SIFS_FRMTYPE,
  1506. OL_ATH_PARAM_SIFS_UAPSD = 185,
  1507. OL_ATH_PARAM_FW_RECOVERY_ID,
  1508. OL_ATH_PARAM_RESET_OL_STATS,
  1509. OL_ATH_PARAM_AGGR_BURST,
  1510. /* Number of deauth sent in consecutive rx_peer_invalid */
  1511. OL_ATH_PARAM_DEAUTH_COUNT,
  1512. OL_ATH_PARAM_BLOCK_INTERBSS = 190,
  1513. /* Firmware reset control for Bmiss / timeout / reset */
  1514. OL_ATH_PARAM_FW_DISABLE_RESET,
  1515. OL_ATH_PARAM_MSDU_TTL,
  1516. OL_ATH_PARAM_PPDU_DURATION,
  1517. OL_ATH_PARAM_SET_TXBF_SND_PERIOD,
  1518. OL_ATH_PARAM_ALLOW_PROMISC = 195,
  1519. OL_ATH_PARAM_BURST_MODE,
  1520. OL_ATH_PARAM_DYN_GROUPING,
  1521. OL_ATH_PARAM_DPD_ENABLE,
  1522. OL_ATH_PARAM_DBGLOG_RATELIM,
  1523. /* firmware should intimate us about ps state change for node */
  1524. OL_ATH_PARAM_PS_STATE_CHANGE = 200,
  1525. OL_ATH_PARAM_MCAST_BCAST_ECHO,
  1526. /* OBSS RSSI threshold for 20/40 coexistence */
  1527. OL_ATH_PARAM_OBSS_RSSI_THRESHOLD,
  1528. /* Link/node RX RSSI threshold for 20/40 coexistence */
  1529. OL_ATH_PARAM_OBSS_RX_RSSI_THRESHOLD,
  1530. #if ATH_CHANNEL_BLOCKING
  1531. OL_ATH_PARAM_ACS_BLOCK_MODE = 205,
  1532. #endif
  1533. OL_ATH_PARAM_ACS_TX_POWER_OPTION,
  1534. /*
  1535. * Default Antenna Polarization MSB 8 bits (24:31) specifying
  1536. * enable/disable ; LSB 24 bits (0:23) antenna mask value
  1537. */
  1538. OL_ATH_PARAM_ANT_POLARIZATION,
  1539. /* rate limit mute type error prints */
  1540. OL_ATH_PARAM_PRINT_RATE_LIMIT,
  1541. OL_ATH_PARAM_PDEV_RESET, /* Reset FW PDEV*/
  1542. /* Do not crash host when target assert happened*/
  1543. OL_ATH_PARAM_FW_DUMP_NO_HOST_CRASH = 210,
  1544. /* Consider OBSS non-erp to change to long slot*/
  1545. OL_ATH_PARAM_CONSIDER_OBSS_NON_ERP_LONG_SLOT = 211,
  1546. OL_ATH_PARAM_STATS_FC,
  1547. OL_ATH_PARAM_QFLUSHINTERVAL,
  1548. OL_ATH_PARAM_TOTAL_Q_SIZE,
  1549. OL_ATH_PARAM_TOTAL_Q_SIZE_RANGE0,
  1550. OL_ATH_PARAM_TOTAL_Q_SIZE_RANGE1,
  1551. OL_ATH_PARAM_TOTAL_Q_SIZE_RANGE2,
  1552. OL_ATH_PARAM_TOTAL_Q_SIZE_RANGE3,
  1553. OL_ATH_PARAM_MIN_THRESHOLD,
  1554. OL_ATH_PARAM_MAX_Q_LIMIT,
  1555. OL_ATH_PARAM_MIN_Q_LIMIT,
  1556. OL_ATH_PARAM_CONG_CTRL_TIMER_INTV,
  1557. OL_ATH_PARAM_STATS_TIMER_INTV,
  1558. OL_ATH_PARAM_ROTTING_TIMER_INTV,
  1559. OL_ATH_PARAM_LATENCY_PROFILE,
  1560. OL_ATH_PARAM_HOSTQ_DUMP,
  1561. OL_ATH_PARAM_TIDQ_MAP,
  1562. OL_ATH_PARAM_DBG_ARP_SRC_ADDR, /* ARP DEBUG source address*/
  1563. OL_ATH_PARAM_DBG_ARP_DST_ADDR, /* ARP DEBUG destination address*/
  1564. OL_ATH_PARAM_ARP_DBG_CONF, /* ARP debug configuration */
  1565. OL_ATH_PARAM_DISABLE_STA_VAP_AMSDU, /* Disable AMSDU for station vap */
  1566. #if ATH_SUPPORT_DFS && ATH_SUPPORT_STA_DFS
  1567. OL_ATH_PARAM_STADFS_ENABLE = 300, /* STA DFS is enabled or not */
  1568. #endif
  1569. #if QCA_AIRTIME_FAIRNESS
  1570. OL_ATH_PARAM_ATF_STRICT_SCHED = 301,
  1571. OL_ATH_PARAM_ATF_GROUP_POLICY = 302,
  1572. #endif
  1573. #if DBDC_REPEATER_SUPPORT
  1574. OL_ATH_PARAM_PRIMARY_RADIO,
  1575. OL_ATH_PARAM_DBDC_ENABLE,
  1576. #endif
  1577. OL_ATH_PARAM_TXPOWER_DBSCALE,
  1578. OL_ATH_PARAM_CTL_POWER_SCALE,
  1579. #if QCA_AIRTIME_FAIRNESS
  1580. OL_ATH_PARAM_ATF_OBSS_SCHED = 307,
  1581. OL_ATH_PARAM_ATF_OBSS_SCALE = 308,
  1582. #endif
  1583. OL_ATH_PARAM_PHY_OFDM_ERR = 309,
  1584. OL_ATH_PARAM_PHY_CCK_ERR = 310,
  1585. OL_ATH_PARAM_FCS_ERR = 311,
  1586. OL_ATH_PARAM_CHAN_UTIL = 312,
  1587. #if DBDC_REPEATER_SUPPORT
  1588. OL_ATH_PARAM_CLIENT_MCAST,
  1589. #endif
  1590. OL_ATH_PARAM_EMIWAR_80P80 = 314,
  1591. OL_ATH_PARAM_BATCHMODE = 315,
  1592. OL_ATH_PARAM_PACK_AGGR_DELAY = 316,
  1593. #if UMAC_SUPPORT_ACFG
  1594. OL_ATH_PARAM_DIAG_ENABLE = 317,
  1595. #endif
  1596. #if ATH_SUPPORT_VAP_QOS
  1597. OL_ATH_PARAM_VAP_QOS = 318,
  1598. #endif
  1599. OL_ATH_PARAM_CHAN_STATS_TH = 319,
  1600. /* Passive scan is enabled or disabled */
  1601. OL_ATH_PARAM_PASSIVE_SCAN_ENABLE = 320,
  1602. OL_ATH_MIN_RSSI_ENABLE = 321,
  1603. OL_ATH_MIN_RSSI = 322,
  1604. OL_ATH_PARAM_ACS_2G_ALLCHAN = 323,
  1605. #if DBDC_REPEATER_SUPPORT
  1606. OL_ATH_PARAM_DELAY_STAVAP_UP = 324,
  1607. #endif
  1608. /* It is used to set the channel switch options */
  1609. OL_ATH_PARAM_CHANSWITCH_OPTIONS = 327,
  1610. OL_ATH_BTCOEX_ENABLE = 328,
  1611. OL_ATH_BTCOEX_WL_PRIORITY = 329,
  1612. OL_ATH_PARAM_TID_OVERRIDE_QUEUE_MAPPING = 330,
  1613. OL_ATH_PARAM_CAL_VER_CHECK = 331,
  1614. OL_ATH_PARAM_NO_VLAN = 332,
  1615. OL_ATH_PARAM_CCA_THRESHOLD = 333,
  1616. OL_ATH_PARAM_ATF_LOGGING = 334,
  1617. OL_ATH_PARAM_STRICT_DOTH = 335,
  1618. OL_ATH_PARAM_DISCONNECTION_TIMEOUT = 336,
  1619. OL_ATH_PARAM_RECONFIGURATION_TIMEOUT = 337,
  1620. OL_ATH_PARAM_CHANNEL_SWITCH_COUNT = 338,
  1621. OL_ATH_PARAM_ALWAYS_PRIMARY = 339,
  1622. OL_ATH_PARAM_FAST_LANE = 340,
  1623. OL_ATH_GET_BTCOEX_DUTY_CYCLE = 341,
  1624. OL_ATH_PARAM_SECONDARY_OFFSET_IE = 342,
  1625. OL_ATH_PARAM_WIDE_BAND_SUB_ELEMENT = 343,
  1626. OL_ATH_PARAM_PREFERRED_UPLINK = 344,
  1627. OL_ATH_PARAM_PRECAC_ENABLE = 345,
  1628. OL_ATH_PARAM_PRECAC_TIMEOUT = 346,
  1629. OL_ATH_COEX_VER_CFG = 347,
  1630. OL_ATH_PARAM_DUMP_TARGET = 348,
  1631. OL_ATH_PARAM_PDEV_TO_REO_DEST = 349,
  1632. OL_ATH_PARAM_DUMP_CHAINMASK_TABLES = 350,
  1633. OL_ATH_PARAM_DUMP_OBJECTS = 351,
  1634. OL_ATH_PARAM_ACS_SRLOADVAR = 352,
  1635. OL_ATH_PARAM_MGMT_RSSI_THRESHOLD = 353,
  1636. OL_ATH_PARAM_EXT_NSS_CAPABLE = 354,
  1637. OL_ATH_PARAM_MGMT_PDEV_STATS_TIMER = 355,
  1638. OL_ATH_PARAM_TXACKTIMEOUT = 356,
  1639. OL_ATH_PARAM_ICM_ACTIVE = 357,
  1640. OL_ATH_PARAM_NOMINAL_NOISEFLOOR = 358,
  1641. OL_ATH_PARAM_CHAN_INFO = 359,
  1642. OL_ATH_PARAM_ACS_RANK = 360,
  1643. OL_ATH_PARAM_TXCHAINSOFT = 361,
  1644. OL_ATH_PARAM_WIDE_BAND_SCAN = 362,
  1645. OL_ATH_PARAM_CCK_TX_ENABLE = 363,
  1646. OL_ATH_PARAM_PAPI_ENABLE = 364,
  1647. OL_ATH_PARAM_ISOLATION = 365,
  1648. OL_ATH_PARAM_MAX_CLIENTS_PER_RADIO = 366,
  1649. #if defined(WLAN_DFS_PARTIAL_OFFLOAD) && defined(HOST_DFS_SPOOF_TEST)
  1650. OL_ATH_PARAM_DFS_HOST_WAIT_TIMEOUT = 367,
  1651. #endif
  1652. OL_ATH_PARAM_NF_THRESH = 368,
  1653. #ifdef OL_ATH_SMART_LOGGING
  1654. OL_ATH_PARAM_SMARTLOG_ENABLE = 369,
  1655. OL_ATH_PARAM_SMARTLOG_FATAL_EVENT = 370,
  1656. OL_ATH_PARAM_SMARTLOG_SKB_SZ = 371,
  1657. OL_ATH_PARAM_SMARTLOG_P1PINGFAIL = 372,
  1658. #endif /* OL_ATH_SMART_LOGGING */
  1659. #ifdef WLAN_DFS_PRECAC_AUTO_CHAN_SUPPORT
  1660. OL_ATH_PARAM_PRECAC_INTER_CHANNEL = 373,
  1661. OL_ATH_PARAM_PRECAC_CHAN_STATE = 374,
  1662. #endif
  1663. OL_ATH_PARAM_DBR_RING_STATUS = 375,
  1664. #ifdef QCN_ESP_IE
  1665. OL_ATH_PARAM_ESP_PERIODICITY = 376,
  1666. OL_ATH_PARAM_ESP_AIRTIME = 377,
  1667. OL_ATH_PARAM_ESP_PPDU_DURATION = 378,
  1668. OL_ATH_PARAM_ESP_BA_WINDOW = 379,
  1669. #endif /* QCN_ESP_IE */
  1670. OL_ATH_PARAM_CBS = 380,
  1671. OL_ATH_PARAM_DCS_SIM = 381,
  1672. OL_ATH_PARAM_CBS_DWELL_SPLIT_TIME = 382,
  1673. OL_ATH_PARAM_CBS_DWELL_REST_TIME = 383,
  1674. OL_ATH_PARAM_CBS_WAIT_TIME = 384,
  1675. OL_ATH_PARAM_CBS_REST_TIME = 385,
  1676. OL_ATH_PARAM_CBS_CSA = 386,
  1677. OL_ATH_PARAM_TWICE_ANTENNA_GAIN = 387,
  1678. OL_ATH_PARAM_ACTIVITY_FACTOR = 388,
  1679. OL_ATH_PARAM_CHAN_AP_RX_UTIL = 389,
  1680. OL_ATH_PARAM_CHAN_FREE = 390,
  1681. OL_ATH_PARAM_CHAN_AP_TX_UTIL = 391,
  1682. OL_ATH_PARAM_CHAN_OBSS_RX_UTIL = 392,
  1683. OL_ATH_PARAM_CHAN_NON_WIFI = 393,
  1684. #if PEER_FLOW_CONTROL
  1685. OL_ATH_PARAM_VIDEO_STATS_FC = 394,
  1686. OL_ATH_PARAM_VIDEO_DELAY_STATS_FC = 395,
  1687. #endif
  1688. OL_ATH_PARAM_ENABLE_PEER_RETRY_STATS = 396,
  1689. OL_ATH_PARAM_HE_UL_TRIG_INT = 397,
  1690. OL_ATH_PARAM_DFS_NOL_SUBCHANNEL_MARKING = 398,
  1691. /*
  1692. * Get the band that is tuned for low, high,
  1693. * full band freq range or it's 2g
  1694. */
  1695. OL_ATH_PARAM_BAND_INFO = 399,
  1696. OL_ATH_PARAM_BW_REDUCE = 400,
  1697. /* Enable/disable Spatial Reuse */
  1698. OL_ATH_PARAM_HE_SR = 401,
  1699. OL_ATH_PARAM_HE_UL_PPDU_DURATION = 402,
  1700. OL_ATH_PARAM_HE_UL_RU_ALLOCATION = 403,
  1701. OL_ATH_PARAM_PERIODIC_CFR_CAPTURE = 404,
  1702. OL_ATH_PARAM_FLUSH_PEER_RATE_STATS = 405,
  1703. OL_ATH_PARAM_DCS_RE_ENABLE_TIMER = 406,
  1704. /* Enable/disable Rx lite monitor mode */
  1705. OL_ATH_PARAM_RX_MON_LITE = 407,
  1706. /* wifi down indication used in MBSS feature */
  1707. OL_ATH_PARAM_WIFI_DOWN_IND = 408,
  1708. OL_ATH_PARAM_TX_CAPTURE = 409,
  1709. /* Enable fw dump collectin if wmi disconnects */
  1710. OL_ATH_PARAM_WMI_DIS_DUMP = 410,
  1711. OL_ATH_PARAM_ACS_CHAN_GRADE_ALGO = 411,
  1712. OL_ATH_PARAM_ACS_CHAN_EFFICIENCY_VAR = 412,
  1713. OL_ATH_PARAM_ACS_NEAR_RANGE_WEIGHTAGE = 413,
  1714. OL_ATH_PARAM_ACS_MID_RANGE_WEIGHTAGE = 414,
  1715. OL_ATH_PARAM_ACS_FAR_RANGE_WEIGHTAGE = 415,
  1716. /* Set SELF AP OBSS_PD_THRESHOLD value */
  1717. OL_ATH_PARAM_SET_CMD_OBSS_PD_THRESHOLD = 416,
  1718. /* Enable/Disable/Set MGMT_TTL in milliseconds. */
  1719. OL_ATH_PARAM_MGMT_TTL = 417,
  1720. /* Enable/Disable/Set PROBE_RESP_TTL in milliseconds */
  1721. OL_ATH_PARAM_PROBE_RESP_TTL = 418,
  1722. /* Set global MU PPDU duration for DL (usec units) */
  1723. OL_ATH_PARAM_MU_PPDU_DURATION = 419,
  1724. /* Set TBTT_CTRL_CFG */
  1725. OL_ATH_PARAM_TBTT_CTRL = 420,
  1726. /* Enable/disable AP OBSS_PD_THRESHOLD */
  1727. OL_ATH_PARAM_SET_CMD_OBSS_PD_THRESHOLD_ENABLE = 421,
  1728. /* Get baseline radio level channel width */
  1729. OL_ATH_PARAM_RCHWIDTH = 422,
  1730. /* Whether external ACS request is in progress */
  1731. OL_ATH_EXT_ACS_REQUEST_IN_PROGRESS = 423,
  1732. /* set/get hw mode */
  1733. OL_ATH_PARAM_HW_MODE = 424,
  1734. #if DBDC_REPEATER_SUPPORT
  1735. /* same ssid feature global disable */
  1736. OL_ATH_PARAM_SAME_SSID_DISABLE = 425,
  1737. #endif
  1738. /* get MBSS enable flag */
  1739. OL_ATH_PARAM_MBSS_EN = 426,
  1740. /* UNII-1 and UNII-2A channel coexistance */
  1741. OL_ATH_PARAM_CHAN_COEX = 427,
  1742. };
  1743. #endif
  1744. /* Bitmasks for stats that can block */
  1745. #define EXT_TXRX_FW_STATS 0x0001
  1746. #endif