rx_reo_queue.h 54 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261
  1. /*
  2. * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for any
  5. * purpose with or without fee is hereby granted, provided that the above
  6. * copyright notice and this permission notice appear in all copies.
  7. *
  8. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  9. * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  10. * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  11. * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  12. * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  13. * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  14. * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  15. */
  16. #ifndef _RX_REO_QUEUE_H_
  17. #define _RX_REO_QUEUE_H_
  18. #if !defined(__ASSEMBLER__)
  19. #endif
  20. #include "uniform_descriptor_header.h"
  21. #define NUM_OF_DWORDS_RX_REO_QUEUE 32
  22. struct rx_reo_queue {
  23. #ifndef WIFI_BIT_ORDER_BIG_ENDIAN
  24. struct uniform_descriptor_header descriptor_header;
  25. uint32_t receive_queue_number : 16, // [15:0]
  26. reserved_1b : 16; // [31:16]
  27. uint32_t vld : 1, // [0:0]
  28. associated_link_descriptor_counter : 2, // [2:1]
  29. disable_duplicate_detection : 1, // [3:3]
  30. soft_reorder_enable : 1, // [4:4]
  31. ac : 2, // [6:5]
  32. bar : 1, // [7:7]
  33. rty : 1, // [8:8]
  34. chk_2k_mode : 1, // [9:9]
  35. oor_mode : 1, // [10:10]
  36. ba_window_size : 10, // [20:11]
  37. pn_check_needed : 1, // [21:21]
  38. pn_shall_be_even : 1, // [22:22]
  39. pn_shall_be_uneven : 1, // [23:23]
  40. pn_handling_enable : 1, // [24:24]
  41. pn_size : 2, // [26:25]
  42. ignore_ampdu_flag : 1, // [27:27]
  43. reserved_2b : 4; // [31:28]
  44. uint32_t svld : 1, // [0:0]
  45. ssn : 12, // [12:1]
  46. current_index : 10, // [22:13]
  47. seq_2k_error_detected_flag : 1, // [23:23]
  48. pn_error_detected_flag : 1, // [24:24]
  49. reserved_3a : 6, // [30:25]
  50. pn_valid : 1; // [31:31]
  51. uint32_t pn_31_0 : 32; // [31:0]
  52. uint32_t pn_63_32 : 32; // [31:0]
  53. uint32_t pn_95_64 : 32; // [31:0]
  54. uint32_t pn_127_96 : 32; // [31:0]
  55. uint32_t last_rx_enqueue_timestamp : 32; // [31:0]
  56. uint32_t last_rx_dequeue_timestamp : 32; // [31:0]
  57. uint32_t ptr_to_next_aging_queue_31_0 : 32; // [31:0]
  58. uint32_t ptr_to_next_aging_queue_39_32 : 8, // [7:0]
  59. reserved_11a : 24; // [31:8]
  60. uint32_t ptr_to_previous_aging_queue_31_0 : 32; // [31:0]
  61. uint32_t ptr_to_previous_aging_queue_39_32 : 8, // [7:0]
  62. statistics_counter_index : 6, // [13:8]
  63. reserved_13a : 18; // [31:14]
  64. uint32_t rx_bitmap_31_0 : 32; // [31:0]
  65. uint32_t rx_bitmap_63_32 : 32; // [31:0]
  66. uint32_t rx_bitmap_95_64 : 32; // [31:0]
  67. uint32_t rx_bitmap_127_96 : 32; // [31:0]
  68. uint32_t rx_bitmap_159_128 : 32; // [31:0]
  69. uint32_t rx_bitmap_191_160 : 32; // [31:0]
  70. uint32_t rx_bitmap_223_192 : 32; // [31:0]
  71. uint32_t rx_bitmap_255_224 : 32; // [31:0]
  72. uint32_t rx_bitmap_287_256 : 32; // [31:0]
  73. uint32_t current_mpdu_count : 7, // [6:0]
  74. current_msdu_count : 25; // [31:7]
  75. uint32_t last_sn_reg_index : 4, // [3:0]
  76. timeout_count : 6, // [9:4]
  77. forward_due_to_bar_count : 6, // [15:10]
  78. duplicate_count : 16; // [31:16]
  79. uint32_t frames_in_order_count : 24, // [23:0]
  80. bar_received_count : 8; // [31:24]
  81. uint32_t mpdu_frames_processed_count : 32; // [31:0]
  82. uint32_t msdu_frames_processed_count : 32; // [31:0]
  83. uint32_t total_processed_byte_count : 32; // [31:0]
  84. uint32_t late_receive_mpdu_count : 12, // [11:0]
  85. window_jump_2k : 4, // [15:12]
  86. hole_count : 16; // [31:16]
  87. uint32_t aging_drop_mpdu_count : 16, // [15:0]
  88. aging_drop_interval : 8, // [23:16]
  89. reserved_30 : 8; // [31:24]
  90. uint32_t reserved_31 : 32; // [31:0]
  91. #else
  92. struct uniform_descriptor_header descriptor_header;
  93. uint32_t reserved_1b : 16, // [31:16]
  94. receive_queue_number : 16; // [15:0]
  95. uint32_t reserved_2b : 4, // [31:28]
  96. ignore_ampdu_flag : 1, // [27:27]
  97. pn_size : 2, // [26:25]
  98. pn_handling_enable : 1, // [24:24]
  99. pn_shall_be_uneven : 1, // [23:23]
  100. pn_shall_be_even : 1, // [22:22]
  101. pn_check_needed : 1, // [21:21]
  102. ba_window_size : 10, // [20:11]
  103. oor_mode : 1, // [10:10]
  104. chk_2k_mode : 1, // [9:9]
  105. rty : 1, // [8:8]
  106. bar : 1, // [7:7]
  107. ac : 2, // [6:5]
  108. soft_reorder_enable : 1, // [4:4]
  109. disable_duplicate_detection : 1, // [3:3]
  110. associated_link_descriptor_counter : 2, // [2:1]
  111. vld : 1; // [0:0]
  112. uint32_t pn_valid : 1, // [31:31]
  113. reserved_3a : 6, // [30:25]
  114. pn_error_detected_flag : 1, // [24:24]
  115. seq_2k_error_detected_flag : 1, // [23:23]
  116. current_index : 10, // [22:13]
  117. ssn : 12, // [12:1]
  118. svld : 1; // [0:0]
  119. uint32_t pn_31_0 : 32; // [31:0]
  120. uint32_t pn_63_32 : 32; // [31:0]
  121. uint32_t pn_95_64 : 32; // [31:0]
  122. uint32_t pn_127_96 : 32; // [31:0]
  123. uint32_t last_rx_enqueue_timestamp : 32; // [31:0]
  124. uint32_t last_rx_dequeue_timestamp : 32; // [31:0]
  125. uint32_t ptr_to_next_aging_queue_31_0 : 32; // [31:0]
  126. uint32_t reserved_11a : 24, // [31:8]
  127. ptr_to_next_aging_queue_39_32 : 8; // [7:0]
  128. uint32_t ptr_to_previous_aging_queue_31_0 : 32; // [31:0]
  129. uint32_t reserved_13a : 18, // [31:14]
  130. statistics_counter_index : 6, // [13:8]
  131. ptr_to_previous_aging_queue_39_32 : 8; // [7:0]
  132. uint32_t rx_bitmap_31_0 : 32; // [31:0]
  133. uint32_t rx_bitmap_63_32 : 32; // [31:0]
  134. uint32_t rx_bitmap_95_64 : 32; // [31:0]
  135. uint32_t rx_bitmap_127_96 : 32; // [31:0]
  136. uint32_t rx_bitmap_159_128 : 32; // [31:0]
  137. uint32_t rx_bitmap_191_160 : 32; // [31:0]
  138. uint32_t rx_bitmap_223_192 : 32; // [31:0]
  139. uint32_t rx_bitmap_255_224 : 32; // [31:0]
  140. uint32_t rx_bitmap_287_256 : 32; // [31:0]
  141. uint32_t current_msdu_count : 25, // [31:7]
  142. current_mpdu_count : 7; // [6:0]
  143. uint32_t duplicate_count : 16, // [31:16]
  144. forward_due_to_bar_count : 6, // [15:10]
  145. timeout_count : 6, // [9:4]
  146. last_sn_reg_index : 4; // [3:0]
  147. uint32_t bar_received_count : 8, // [31:24]
  148. frames_in_order_count : 24; // [23:0]
  149. uint32_t mpdu_frames_processed_count : 32; // [31:0]
  150. uint32_t msdu_frames_processed_count : 32; // [31:0]
  151. uint32_t total_processed_byte_count : 32; // [31:0]
  152. uint32_t hole_count : 16, // [31:16]
  153. window_jump_2k : 4, // [15:12]
  154. late_receive_mpdu_count : 12; // [11:0]
  155. uint32_t reserved_30 : 8, // [31:24]
  156. aging_drop_interval : 8, // [23:16]
  157. aging_drop_mpdu_count : 16; // [15:0]
  158. uint32_t reserved_31 : 32; // [31:0]
  159. #endif
  160. };
  161. /* Description DESCRIPTOR_HEADER
  162. Details about which module owns this struct.
  163. Note that sub field "Buffer_type" shall be set to "Receive_REO_queue_descriptor"
  164. */
  165. /* Description OWNER
  166. Consumer: In DEBUG mode: WBM, TQM, TXDMA, RXDMA, REO
  167. Producer: In DEBUG mode: WBM, TQM, TXDMA, RXDMA, REO
  168. The owner of this data structure:
  169. <enum 0 WBM_owned> Buffer Manager currently owns this data
  170. structure.
  171. <enum 1 SW_OR_FW_owned> Software of FW currently owns this
  172. data structure.
  173. <enum 2 TQM_owned> Transmit Queue Manager currently owns
  174. this data structure.
  175. <enum 3 RXDMA_owned> Receive DMA currently owns this data
  176. structure.
  177. <enum 4 REO_owned> Reorder currently owns this data structure.
  178. <enum 5 SWITCH_owned> SWITCH currently owns this data structure.
  179. <legal 0-5>
  180. */
  181. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_OWNER_OFFSET 0x00000000
  182. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_OWNER_LSB 0
  183. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_OWNER_MSB 3
  184. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_OWNER_MASK 0x0000000f
  185. /* Description BUFFER_TYPE
  186. Consumer: In DEBUG mode: WBM, TQM, TXDMA, RXDMA, REO
  187. Producer: In DEBUG mode: WBM, TQM, TXDMA, RXDMA, REO
  188. Field describing what contents format is of this descriptor
  189. <enum 0 Transmit_MSDU_Link_descriptor>
  190. <enum 1 Transmit_MPDU_Link_descriptor>
  191. <enum 2 Transmit_MPDU_Queue_head_descriptor>
  192. <enum 3 Transmit_MPDU_Queue_ext_descriptor>
  193. <enum 4 Transmit_flow_descriptor>
  194. <enum 5 Transmit_buffer> NOT TO BE USED:
  195. <enum 6 Receive_MSDU_Link_descriptor>
  196. <enum 7 Receive_MPDU_Link_descriptor>
  197. <enum 8 Receive_REO_queue_descriptor>
  198. <enum 9 Receive_REO_queue_1k_descriptor>
  199. <enum 10 Receive_REO_queue_ext_descriptor>
  200. <enum 11 Receive_buffer>
  201. <enum 12 Idle_link_list_entry>
  202. <legal 0-12>
  203. */
  204. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_BUFFER_TYPE_OFFSET 0x00000000
  205. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_BUFFER_TYPE_LSB 4
  206. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_BUFFER_TYPE_MSB 7
  207. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_BUFFER_TYPE_MASK 0x000000f0
  208. /* Description TX_MPDU_QUEUE_NUMBER
  209. Consumer: TQM/Debug
  210. Producer: SW (in 'TX_MPDU_QUEUE_HEAD')/TQM (elsewhere)
  211. Field only valid if Buffer_type is any of Transmit_MPDU_*_descriptor
  212. Indicates the MPDU queue ID to which this MPDU descriptor
  213. belongs
  214. Used for tracking and debugging
  215. <legal all>
  216. */
  217. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_TX_MPDU_QUEUE_NUMBER_OFFSET 0x00000000
  218. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_TX_MPDU_QUEUE_NUMBER_LSB 8
  219. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_TX_MPDU_QUEUE_NUMBER_MSB 27
  220. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_TX_MPDU_QUEUE_NUMBER_MASK 0x0fffff00
  221. /* Description RESERVED_0A
  222. <legal 0>
  223. */
  224. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_RESERVED_0A_OFFSET 0x00000000
  225. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_RESERVED_0A_LSB 28
  226. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_RESERVED_0A_MSB 31
  227. #define RX_REO_QUEUE_DESCRIPTOR_HEADER_RESERVED_0A_MASK 0xf0000000
  228. /* Description RECEIVE_QUEUE_NUMBER
  229. Indicates the MPDU queue ID to which this MPDU link descriptor
  230. belongs
  231. Used for tracking and debugging
  232. <legal all>
  233. */
  234. #define RX_REO_QUEUE_RECEIVE_QUEUE_NUMBER_OFFSET 0x00000004
  235. #define RX_REO_QUEUE_RECEIVE_QUEUE_NUMBER_LSB 0
  236. #define RX_REO_QUEUE_RECEIVE_QUEUE_NUMBER_MSB 15
  237. #define RX_REO_QUEUE_RECEIVE_QUEUE_NUMBER_MASK 0x0000ffff
  238. /* Description RESERVED_1B
  239. <legal 0>
  240. */
  241. #define RX_REO_QUEUE_RESERVED_1B_OFFSET 0x00000004
  242. #define RX_REO_QUEUE_RESERVED_1B_LSB 16
  243. #define RX_REO_QUEUE_RESERVED_1B_MSB 31
  244. #define RX_REO_QUEUE_RESERVED_1B_MASK 0xffff0000
  245. /* Description VLD
  246. Valid bit indicating a session is established and the queue
  247. descriptor is valid(Filled by SW)
  248. <legal all>
  249. */
  250. #define RX_REO_QUEUE_VLD_OFFSET 0x00000008
  251. #define RX_REO_QUEUE_VLD_LSB 0
  252. #define RX_REO_QUEUE_VLD_MSB 0
  253. #define RX_REO_QUEUE_VLD_MASK 0x00000001
  254. /* Description ASSOCIATED_LINK_DESCRIPTOR_COUNTER
  255. Indicates which of the 3 link descriptor counters shall
  256. be incremented or decremented when link descriptors are
  257. added or removed from this flow queue.
  258. MSDU link descriptors related with MPDUs stored in the re-order
  259. buffer shall also be included in this count.
  260. <legal 0-2>
  261. */
  262. #define RX_REO_QUEUE_ASSOCIATED_LINK_DESCRIPTOR_COUNTER_OFFSET 0x00000008
  263. #define RX_REO_QUEUE_ASSOCIATED_LINK_DESCRIPTOR_COUNTER_LSB 1
  264. #define RX_REO_QUEUE_ASSOCIATED_LINK_DESCRIPTOR_COUNTER_MSB 2
  265. #define RX_REO_QUEUE_ASSOCIATED_LINK_DESCRIPTOR_COUNTER_MASK 0x00000006
  266. /* Description DISABLE_DUPLICATE_DETECTION
  267. When set, do not perform any duplicate detection.
  268. <legal all>
  269. */
  270. #define RX_REO_QUEUE_DISABLE_DUPLICATE_DETECTION_OFFSET 0x00000008
  271. #define RX_REO_QUEUE_DISABLE_DUPLICATE_DETECTION_LSB 3
  272. #define RX_REO_QUEUE_DISABLE_DUPLICATE_DETECTION_MSB 3
  273. #define RX_REO_QUEUE_DISABLE_DUPLICATE_DETECTION_MASK 0x00000008
  274. /* Description SOFT_REORDER_ENABLE
  275. When set, REO has been instructed to not perform the actual
  276. re-ordering of frames for this queue, but just to insert
  277. the reorder opcodes.
  278. Note that this implies that REO is also not going to perform
  279. any MSDU level operations, and the entire MPDU (and thus
  280. pointer to the MSDU link descriptor) will be pushed to
  281. a destination ring that SW has programmed in a SW programmable
  282. configuration register in REO
  283. <legal all>
  284. */
  285. #define RX_REO_QUEUE_SOFT_REORDER_ENABLE_OFFSET 0x00000008
  286. #define RX_REO_QUEUE_SOFT_REORDER_ENABLE_LSB 4
  287. #define RX_REO_QUEUE_SOFT_REORDER_ENABLE_MSB 4
  288. #define RX_REO_QUEUE_SOFT_REORDER_ENABLE_MASK 0x00000010
  289. /* Description AC
  290. Indicates which access category the queue descriptor belongs
  291. to(filled by SW)
  292. <legal all>
  293. */
  294. #define RX_REO_QUEUE_AC_OFFSET 0x00000008
  295. #define RX_REO_QUEUE_AC_LSB 5
  296. #define RX_REO_QUEUE_AC_MSB 6
  297. #define RX_REO_QUEUE_AC_MASK 0x00000060
  298. /* Description BAR
  299. Indicates if BAR has been received (mostly used for debug
  300. purpose and this is filled by REO)
  301. <legal all>
  302. */
  303. #define RX_REO_QUEUE_BAR_OFFSET 0x00000008
  304. #define RX_REO_QUEUE_BAR_LSB 7
  305. #define RX_REO_QUEUE_BAR_MSB 7
  306. #define RX_REO_QUEUE_BAR_MASK 0x00000080
  307. /* Description RTY
  308. Retry bit is checked if this bit is set.
  309. <legal all>
  310. */
  311. #define RX_REO_QUEUE_RTY_OFFSET 0x00000008
  312. #define RX_REO_QUEUE_RTY_LSB 8
  313. #define RX_REO_QUEUE_RTY_MSB 8
  314. #define RX_REO_QUEUE_RTY_MASK 0x00000100
  315. /* Description CHK_2K_MODE
  316. Indicates what type of operation is expected from Reo when
  317. the received frame SN falls within the 2K window
  318. <legal all>
  319. */
  320. #define RX_REO_QUEUE_CHK_2K_MODE_OFFSET 0x00000008
  321. #define RX_REO_QUEUE_CHK_2K_MODE_LSB 9
  322. #define RX_REO_QUEUE_CHK_2K_MODE_MSB 9
  323. #define RX_REO_QUEUE_CHK_2K_MODE_MASK 0x00000200
  324. /* Description OOR_MODE
  325. Out of Order mode:
  326. Indicates what type of operation is expected when the received
  327. frame falls within the OOR window.
  328. <legal all>
  329. */
  330. #define RX_REO_QUEUE_OOR_MODE_OFFSET 0x00000008
  331. #define RX_REO_QUEUE_OOR_MODE_LSB 10
  332. #define RX_REO_QUEUE_OOR_MODE_MSB 10
  333. #define RX_REO_QUEUE_OOR_MODE_MASK 0x00000400
  334. /* Description BA_WINDOW_SIZE
  335. Indicates the negotiated (window size + 1).
  336. It can go up to Max of 256bits.
  337. A value 255 means 256 bitmap, 63 means 64 bitmap, 0 (means
  338. non-BA session, with window size of 0). The 3 values here
  339. are the main values validated, but other values should
  340. work as well.
  341. A value 1023 means 1024 bitmap, 511 means 512 bitmap. The
  342. 2 values here are the main values validated for 1k-bitmap
  343. support, but other values should work as well.
  344. A BA window size of 0 (=> one frame entry bitmap), means
  345. that there is NO RX_REO_QUEUE_EXT descriptor following
  346. this RX_REO_QUEUE STRUCT in memory
  347. A BA window size of 1 - 105 means that there is 1 RX_REO_QUEUE_EXT
  348. descriptor directly following this RX_REO_QUEUE STRUCT
  349. in memory.
  350. A BA window size of 106 - 210 means that there are 2 RX_REO_QUEUE_EXT
  351. descriptors directly following this RX_REO_QUEUE STRUCT
  352. in memory
  353. A BA window size of 211 - 256 means that there are 3 RX_REO_QUEUE_EXT
  354. descriptors directly following this RX_REO_QUEUE STRUCT
  355. in memory
  356. A BA window size of 257 - 315 means that there is one RX_REO_QUEUE_1K
  357. descriptor followed by 3 RX_REO_QUEUE_EXT descriptors directly
  358. following this RX_REO_QUEUE STRUCT in memory
  359. A BA window size of 316 - 420 means that there is one RX_REO_QUEUE_1K
  360. descriptor followed by 4 RX_REO_QUEUE_EXT descriptors directly
  361. following this RX_REO_QUEUE STRUCT in memory
  362. ...
  363. A BA window size of 946 - 1024 means that there is one RX_REO_QUEUE_1K
  364. descriptor followed by 10 RX_REO_QUEUE_EXT descriptors
  365. directly following this RX_REO_QUEUE STRUCT in memory
  366. TODO: Should the above text use '255' and '1023' instead
  367. of '256' and '1024'?
  368. <legal 0 - 1023>
  369. */
  370. #define RX_REO_QUEUE_BA_WINDOW_SIZE_OFFSET 0x00000008
  371. #define RX_REO_QUEUE_BA_WINDOW_SIZE_LSB 11
  372. #define RX_REO_QUEUE_BA_WINDOW_SIZE_MSB 20
  373. #define RX_REO_QUEUE_BA_WINDOW_SIZE_MASK 0x001ff800
  374. /* Description PN_CHECK_NEEDED
  375. When set, REO shall perform the PN increment check
  376. <legal all>
  377. */
  378. #define RX_REO_QUEUE_PN_CHECK_NEEDED_OFFSET 0x00000008
  379. #define RX_REO_QUEUE_PN_CHECK_NEEDED_LSB 21
  380. #define RX_REO_QUEUE_PN_CHECK_NEEDED_MSB 21
  381. #define RX_REO_QUEUE_PN_CHECK_NEEDED_MASK 0x00200000
  382. /* Description PN_SHALL_BE_EVEN
  383. Field only valid when 'pn_check_needed' is set.
  384. When set, REO shall confirm that the received PN number
  385. is not only incremented, but also always an even number
  386. <legal all>
  387. */
  388. #define RX_REO_QUEUE_PN_SHALL_BE_EVEN_OFFSET 0x00000008
  389. #define RX_REO_QUEUE_PN_SHALL_BE_EVEN_LSB 22
  390. #define RX_REO_QUEUE_PN_SHALL_BE_EVEN_MSB 22
  391. #define RX_REO_QUEUE_PN_SHALL_BE_EVEN_MASK 0x00400000
  392. /* Description PN_SHALL_BE_UNEVEN
  393. Field only valid when 'pn_check_needed' is set.
  394. When set, REO shall confirm that the received PN number
  395. is not only incremented, but also always an uneven number
  396. <legal all>
  397. */
  398. #define RX_REO_QUEUE_PN_SHALL_BE_UNEVEN_OFFSET 0x00000008
  399. #define RX_REO_QUEUE_PN_SHALL_BE_UNEVEN_LSB 23
  400. #define RX_REO_QUEUE_PN_SHALL_BE_UNEVEN_MSB 23
  401. #define RX_REO_QUEUE_PN_SHALL_BE_UNEVEN_MASK 0x00800000
  402. /* Description PN_HANDLING_ENABLE
  403. Field only valid when 'pn_check_needed' is set.
  404. When set, and REO detected a PN error, HW shall set the 'pn_error_detected_flag'.
  405. <legal all>
  406. */
  407. #define RX_REO_QUEUE_PN_HANDLING_ENABLE_OFFSET 0x00000008
  408. #define RX_REO_QUEUE_PN_HANDLING_ENABLE_LSB 24
  409. #define RX_REO_QUEUE_PN_HANDLING_ENABLE_MSB 24
  410. #define RX_REO_QUEUE_PN_HANDLING_ENABLE_MASK 0x01000000
  411. /* Description PN_SIZE
  412. Size of the PN field check.
  413. Needed for wrap around handling...
  414. <enum 0 pn_size_24>
  415. <enum 1 pn_size_48>
  416. <enum 2 pn_size_128>
  417. <legal 0-2>
  418. */
  419. #define RX_REO_QUEUE_PN_SIZE_OFFSET 0x00000008
  420. #define RX_REO_QUEUE_PN_SIZE_LSB 25
  421. #define RX_REO_QUEUE_PN_SIZE_MSB 26
  422. #define RX_REO_QUEUE_PN_SIZE_MASK 0x06000000
  423. /* Description IGNORE_AMPDU_FLAG
  424. When set, REO shall ignore the ampdu_flag on the entrance
  425. descriptor for this queue.
  426. <legal all>
  427. */
  428. #define RX_REO_QUEUE_IGNORE_AMPDU_FLAG_OFFSET 0x00000008
  429. #define RX_REO_QUEUE_IGNORE_AMPDU_FLAG_LSB 27
  430. #define RX_REO_QUEUE_IGNORE_AMPDU_FLAG_MSB 27
  431. #define RX_REO_QUEUE_IGNORE_AMPDU_FLAG_MASK 0x08000000
  432. /* Description RESERVED_2B
  433. <legal 0>
  434. */
  435. #define RX_REO_QUEUE_RESERVED_2B_OFFSET 0x00000008
  436. #define RX_REO_QUEUE_RESERVED_2B_LSB 28
  437. #define RX_REO_QUEUE_RESERVED_2B_MSB 31
  438. #define RX_REO_QUEUE_RESERVED_2B_MASK 0xf0000000
  439. /* Description SVLD
  440. Sequence number in next field is valid one. It can be filled
  441. by SW if the want to fill in the any negotiated SSN, otherwise
  442. REO will fill the sequence number of first received packet
  443. and set this bit to 1.
  444. <legal all>
  445. */
  446. #define RX_REO_QUEUE_SVLD_OFFSET 0x0000000c
  447. #define RX_REO_QUEUE_SVLD_LSB 0
  448. #define RX_REO_QUEUE_SVLD_MSB 0
  449. #define RX_REO_QUEUE_SVLD_MASK 0x00000001
  450. /* Description SSN
  451. Starting Sequence number of the session, this changes whenever
  452. window moves. (can be filled by SW then maintained by REO)
  453. <legal all>
  454. */
  455. #define RX_REO_QUEUE_SSN_OFFSET 0x0000000c
  456. #define RX_REO_QUEUE_SSN_LSB 1
  457. #define RX_REO_QUEUE_SSN_MSB 12
  458. #define RX_REO_QUEUE_SSN_MASK 0x00001ffe
  459. /* Description CURRENT_INDEX
  460. Points to last forwarded packet
  461. <legal all>
  462. */
  463. #define RX_REO_QUEUE_CURRENT_INDEX_OFFSET 0x0000000c
  464. #define RX_REO_QUEUE_CURRENT_INDEX_LSB 13
  465. #define RX_REO_QUEUE_CURRENT_INDEX_MSB 22
  466. #define RX_REO_QUEUE_CURRENT_INDEX_MASK 0x007fe000
  467. /* Description SEQ_2K_ERROR_DETECTED_FLAG
  468. Set by REO, can only be cleared by SW
  469. When set, REO has detected a 2k error jump in the sequence
  470. number and from that moment forward, all new frames are
  471. forwarded directly to FW, without duplicate detect, reordering,
  472. etc.
  473. <legal all>
  474. */
  475. #define RX_REO_QUEUE_SEQ_2K_ERROR_DETECTED_FLAG_OFFSET 0x0000000c
  476. #define RX_REO_QUEUE_SEQ_2K_ERROR_DETECTED_FLAG_LSB 23
  477. #define RX_REO_QUEUE_SEQ_2K_ERROR_DETECTED_FLAG_MSB 23
  478. #define RX_REO_QUEUE_SEQ_2K_ERROR_DETECTED_FLAG_MASK 0x00800000
  479. /* Description PN_ERROR_DETECTED_FLAG
  480. Set by REO, can only be cleared by SW
  481. When set, REO has detected a PN error and from that moment
  482. forward, all new frames are forwarded directly to FW, without
  483. duplicate detect, reordering, etc.
  484. <legal all>
  485. */
  486. #define RX_REO_QUEUE_PN_ERROR_DETECTED_FLAG_OFFSET 0x0000000c
  487. #define RX_REO_QUEUE_PN_ERROR_DETECTED_FLAG_LSB 24
  488. #define RX_REO_QUEUE_PN_ERROR_DETECTED_FLAG_MSB 24
  489. #define RX_REO_QUEUE_PN_ERROR_DETECTED_FLAG_MASK 0x01000000
  490. /* Description RESERVED_3A
  491. <legal 0>
  492. */
  493. #define RX_REO_QUEUE_RESERVED_3A_OFFSET 0x0000000c
  494. #define RX_REO_QUEUE_RESERVED_3A_LSB 25
  495. #define RX_REO_QUEUE_RESERVED_3A_MSB 30
  496. #define RX_REO_QUEUE_RESERVED_3A_MASK 0x7e000000
  497. /* Description PN_VALID
  498. PN number in next fields are valid. It can be filled by
  499. SW if it wants to fill in the any negotiated SSN, otherwise
  500. REO will fill the pn based on the first received packet
  501. and set this bit to 1.
  502. <legal all>
  503. */
  504. #define RX_REO_QUEUE_PN_VALID_OFFSET 0x0000000c
  505. #define RX_REO_QUEUE_PN_VALID_LSB 31
  506. #define RX_REO_QUEUE_PN_VALID_MSB 31
  507. #define RX_REO_QUEUE_PN_VALID_MASK 0x80000000
  508. /* Description PN_31_0
  509. Bits [31:0] of the PN number extracted from the IV field
  510. <legal all>
  511. */
  512. #define RX_REO_QUEUE_PN_31_0_OFFSET 0x00000010
  513. #define RX_REO_QUEUE_PN_31_0_LSB 0
  514. #define RX_REO_QUEUE_PN_31_0_MSB 31
  515. #define RX_REO_QUEUE_PN_31_0_MASK 0xffffffff
  516. /* Description PN_63_32
  517. Bits [63:32] of the PN number.
  518. <legal all>
  519. */
  520. #define RX_REO_QUEUE_PN_63_32_OFFSET 0x00000014
  521. #define RX_REO_QUEUE_PN_63_32_LSB 0
  522. #define RX_REO_QUEUE_PN_63_32_MSB 31
  523. #define RX_REO_QUEUE_PN_63_32_MASK 0xffffffff
  524. /* Description PN_95_64
  525. Bits [95:64] of the PN number.
  526. <legal all>
  527. */
  528. #define RX_REO_QUEUE_PN_95_64_OFFSET 0x00000018
  529. #define RX_REO_QUEUE_PN_95_64_LSB 0
  530. #define RX_REO_QUEUE_PN_95_64_MSB 31
  531. #define RX_REO_QUEUE_PN_95_64_MASK 0xffffffff
  532. /* Description PN_127_96
  533. Bits [127:96] of the PN number.
  534. <legal all>
  535. */
  536. #define RX_REO_QUEUE_PN_127_96_OFFSET 0x0000001c
  537. #define RX_REO_QUEUE_PN_127_96_LSB 0
  538. #define RX_REO_QUEUE_PN_127_96_MSB 31
  539. #define RX_REO_QUEUE_PN_127_96_MASK 0xffffffff
  540. /* Description LAST_RX_ENQUEUE_TIMESTAMP
  541. This timestamp is updated when an MPDU is received and accesses
  542. this Queue Descriptor. It does not include the access due
  543. to Command TLVs or Aging (which will be updated in Last_rx_dequeue_timestamp).
  544. <legal all>
  545. */
  546. #define RX_REO_QUEUE_LAST_RX_ENQUEUE_TIMESTAMP_OFFSET 0x00000020
  547. #define RX_REO_QUEUE_LAST_RX_ENQUEUE_TIMESTAMP_LSB 0
  548. #define RX_REO_QUEUE_LAST_RX_ENQUEUE_TIMESTAMP_MSB 31
  549. #define RX_REO_QUEUE_LAST_RX_ENQUEUE_TIMESTAMP_MASK 0xffffffff
  550. /* Description LAST_RX_DEQUEUE_TIMESTAMP
  551. This timestamp is used for Aging. When an MPDU or multiple
  552. MPDUs are forwarded, either due to window movement, bar,
  553. aging or command flush, this timestamp is updated. Also
  554. when the bitmap is all zero and the first time an MPDU is
  555. queued (opcode=QCUR), this timestamp is updated for aging.
  556. <legal all>
  557. */
  558. #define RX_REO_QUEUE_LAST_RX_DEQUEUE_TIMESTAMP_OFFSET 0x00000024
  559. #define RX_REO_QUEUE_LAST_RX_DEQUEUE_TIMESTAMP_LSB 0
  560. #define RX_REO_QUEUE_LAST_RX_DEQUEUE_TIMESTAMP_MSB 31
  561. #define RX_REO_QUEUE_LAST_RX_DEQUEUE_TIMESTAMP_MASK 0xffffffff
  562. /* Description PTR_TO_NEXT_AGING_QUEUE_31_0
  563. Address (address bits 31-0)of next RX_REO_QUEUE descriptor
  564. in the 'receive timestamp' ordered list.
  565. From it the Position of this queue descriptor in the per
  566. AC aging waitlist can be derived.
  567. Value 0x0 indicates the 'NULL' pointer which implies that
  568. this is the last entry in the list.
  569. <legal all>
  570. */
  571. #define RX_REO_QUEUE_PTR_TO_NEXT_AGING_QUEUE_31_0_OFFSET 0x00000028
  572. #define RX_REO_QUEUE_PTR_TO_NEXT_AGING_QUEUE_31_0_LSB 0
  573. #define RX_REO_QUEUE_PTR_TO_NEXT_AGING_QUEUE_31_0_MSB 31
  574. #define RX_REO_QUEUE_PTR_TO_NEXT_AGING_QUEUE_31_0_MASK 0xffffffff
  575. /* Description PTR_TO_NEXT_AGING_QUEUE_39_32
  576. Address (address bits 39-32)of next RX_REO_QUEUE descriptor
  577. in the 'receive timestamp' ordered list.
  578. From it the Position of this queue descriptor in the per
  579. AC aging waitlist can be derived.
  580. Value 0x0 indicates the 'NULL' pointer which implies that
  581. this is the last entry in the list.
  582. <legal all>
  583. */
  584. #define RX_REO_QUEUE_PTR_TO_NEXT_AGING_QUEUE_39_32_OFFSET 0x0000002c
  585. #define RX_REO_QUEUE_PTR_TO_NEXT_AGING_QUEUE_39_32_LSB 0
  586. #define RX_REO_QUEUE_PTR_TO_NEXT_AGING_QUEUE_39_32_MSB 7
  587. #define RX_REO_QUEUE_PTR_TO_NEXT_AGING_QUEUE_39_32_MASK 0x000000ff
  588. /* Description RESERVED_11A
  589. <legal 0>
  590. */
  591. #define RX_REO_QUEUE_RESERVED_11A_OFFSET 0x0000002c
  592. #define RX_REO_QUEUE_RESERVED_11A_LSB 8
  593. #define RX_REO_QUEUE_RESERVED_11A_MSB 31
  594. #define RX_REO_QUEUE_RESERVED_11A_MASK 0xffffff00
  595. /* Description PTR_TO_PREVIOUS_AGING_QUEUE_31_0
  596. Address (address bits 31-0)of next RX_REO_QUEUE descriptor
  597. in the 'receive timestamp' ordered list.
  598. From it the Position of this queue descriptor in the per
  599. AC aging waitlist can be derived.
  600. Value 0x0 indicates the 'NULL' pointer which implies that
  601. this is the first entry in the list.
  602. <legal all>
  603. */
  604. #define RX_REO_QUEUE_PTR_TO_PREVIOUS_AGING_QUEUE_31_0_OFFSET 0x00000030
  605. #define RX_REO_QUEUE_PTR_TO_PREVIOUS_AGING_QUEUE_31_0_LSB 0
  606. #define RX_REO_QUEUE_PTR_TO_PREVIOUS_AGING_QUEUE_31_0_MSB 31
  607. #define RX_REO_QUEUE_PTR_TO_PREVIOUS_AGING_QUEUE_31_0_MASK 0xffffffff
  608. /* Description PTR_TO_PREVIOUS_AGING_QUEUE_39_32
  609. Address (address bits 39-32)of next RX_REO_QUEUE descriptor
  610. in the 'receive timestamp' ordered list.
  611. From it the Position of this queue descriptor in the per
  612. AC aging waitlist can be derived.
  613. Value 0x0 indicates the 'NULL' pointer which implies that
  614. this is the first entry in the list.
  615. <legal all>
  616. */
  617. #define RX_REO_QUEUE_PTR_TO_PREVIOUS_AGING_QUEUE_39_32_OFFSET 0x00000034
  618. #define RX_REO_QUEUE_PTR_TO_PREVIOUS_AGING_QUEUE_39_32_LSB 0
  619. #define RX_REO_QUEUE_PTR_TO_PREVIOUS_AGING_QUEUE_39_32_MSB 7
  620. #define RX_REO_QUEUE_PTR_TO_PREVIOUS_AGING_QUEUE_39_32_MASK 0x000000ff
  621. /* Description STATISTICS_COUNTER_INDEX
  622. Usually all the queues pertaining to one virtual device
  623. use one statistics register set, and each virtual device
  624. maps to a different set in case of not too many virtual
  625. devices.
  626. <legal 0-47>
  627. */
  628. #define RX_REO_QUEUE_STATISTICS_COUNTER_INDEX_OFFSET 0x00000034
  629. #define RX_REO_QUEUE_STATISTICS_COUNTER_INDEX_LSB 8
  630. #define RX_REO_QUEUE_STATISTICS_COUNTER_INDEX_MSB 13
  631. #define RX_REO_QUEUE_STATISTICS_COUNTER_INDEX_MASK 0x00003f00
  632. /* Description RESERVED_13A
  633. <legal 0>
  634. */
  635. #define RX_REO_QUEUE_RESERVED_13A_OFFSET 0x00000034
  636. #define RX_REO_QUEUE_RESERVED_13A_LSB 14
  637. #define RX_REO_QUEUE_RESERVED_13A_MSB 31
  638. #define RX_REO_QUEUE_RESERVED_13A_MASK 0xffffc000
  639. /* Description RX_BITMAP_31_0
  640. When a bit is set, the corresponding frame is currently
  641. held in the re-order queue.
  642. The bitmap is Fully managed by HW.
  643. SW shall init this to 0, and then never ever change it
  644. <legal all>
  645. */
  646. #define RX_REO_QUEUE_RX_BITMAP_31_0_OFFSET 0x00000038
  647. #define RX_REO_QUEUE_RX_BITMAP_31_0_LSB 0
  648. #define RX_REO_QUEUE_RX_BITMAP_31_0_MSB 31
  649. #define RX_REO_QUEUE_RX_BITMAP_31_0_MASK 0xffffffff
  650. /* Description RX_BITMAP_63_32
  651. See Rx_bitmap_31_0 description
  652. <legal all>
  653. */
  654. #define RX_REO_QUEUE_RX_BITMAP_63_32_OFFSET 0x0000003c
  655. #define RX_REO_QUEUE_RX_BITMAP_63_32_LSB 0
  656. #define RX_REO_QUEUE_RX_BITMAP_63_32_MSB 31
  657. #define RX_REO_QUEUE_RX_BITMAP_63_32_MASK 0xffffffff
  658. /* Description RX_BITMAP_95_64
  659. See Rx_bitmap_31_0 description
  660. <legal all>
  661. */
  662. #define RX_REO_QUEUE_RX_BITMAP_95_64_OFFSET 0x00000040
  663. #define RX_REO_QUEUE_RX_BITMAP_95_64_LSB 0
  664. #define RX_REO_QUEUE_RX_BITMAP_95_64_MSB 31
  665. #define RX_REO_QUEUE_RX_BITMAP_95_64_MASK 0xffffffff
  666. /* Description RX_BITMAP_127_96
  667. See Rx_bitmap_31_0 description
  668. <legal all>
  669. */
  670. #define RX_REO_QUEUE_RX_BITMAP_127_96_OFFSET 0x00000044
  671. #define RX_REO_QUEUE_RX_BITMAP_127_96_LSB 0
  672. #define RX_REO_QUEUE_RX_BITMAP_127_96_MSB 31
  673. #define RX_REO_QUEUE_RX_BITMAP_127_96_MASK 0xffffffff
  674. /* Description RX_BITMAP_159_128
  675. See Rx_bitmap_31_0 description
  676. <legal all>
  677. */
  678. #define RX_REO_QUEUE_RX_BITMAP_159_128_OFFSET 0x00000048
  679. #define RX_REO_QUEUE_RX_BITMAP_159_128_LSB 0
  680. #define RX_REO_QUEUE_RX_BITMAP_159_128_MSB 31
  681. #define RX_REO_QUEUE_RX_BITMAP_159_128_MASK 0xffffffff
  682. /* Description RX_BITMAP_191_160
  683. See Rx_bitmap_31_0 description
  684. <legal all>
  685. */
  686. #define RX_REO_QUEUE_RX_BITMAP_191_160_OFFSET 0x0000004c
  687. #define RX_REO_QUEUE_RX_BITMAP_191_160_LSB 0
  688. #define RX_REO_QUEUE_RX_BITMAP_191_160_MSB 31
  689. #define RX_REO_QUEUE_RX_BITMAP_191_160_MASK 0xffffffff
  690. /* Description RX_BITMAP_223_192
  691. See Rx_bitmap_31_0 description
  692. <legal all>
  693. */
  694. #define RX_REO_QUEUE_RX_BITMAP_223_192_OFFSET 0x00000050
  695. #define RX_REO_QUEUE_RX_BITMAP_223_192_LSB 0
  696. #define RX_REO_QUEUE_RX_BITMAP_223_192_MSB 31
  697. #define RX_REO_QUEUE_RX_BITMAP_223_192_MASK 0xffffffff
  698. /* Description RX_BITMAP_255_224
  699. See Rx_bitmap_31_0 description
  700. <legal all>
  701. */
  702. #define RX_REO_QUEUE_RX_BITMAP_255_224_OFFSET 0x00000054
  703. #define RX_REO_QUEUE_RX_BITMAP_255_224_LSB 0
  704. #define RX_REO_QUEUE_RX_BITMAP_255_224_MSB 31
  705. #define RX_REO_QUEUE_RX_BITMAP_255_224_MASK 0xffffffff
  706. /* Description RX_BITMAP_287_256
  707. See Rx_bitmap_31_0 description
  708. <legal all>
  709. */
  710. #define RX_REO_QUEUE_RX_BITMAP_287_256_OFFSET 0x00000058
  711. #define RX_REO_QUEUE_RX_BITMAP_287_256_LSB 0
  712. #define RX_REO_QUEUE_RX_BITMAP_287_256_MSB 31
  713. #define RX_REO_QUEUE_RX_BITMAP_287_256_MASK 0xffffffff
  714. /* Description CURRENT_MPDU_COUNT
  715. The number of MPDUs in the queue.
  716. <legal all>
  717. */
  718. #define RX_REO_QUEUE_CURRENT_MPDU_COUNT_OFFSET 0x0000005c
  719. #define RX_REO_QUEUE_CURRENT_MPDU_COUNT_LSB 0
  720. #define RX_REO_QUEUE_CURRENT_MPDU_COUNT_MSB 6
  721. #define RX_REO_QUEUE_CURRENT_MPDU_COUNT_MASK 0x0000007f
  722. /* Description CURRENT_MSDU_COUNT
  723. The number of MSDUs in the queue.
  724. <legal all>
  725. */
  726. #define RX_REO_QUEUE_CURRENT_MSDU_COUNT_OFFSET 0x0000005c
  727. #define RX_REO_QUEUE_CURRENT_MSDU_COUNT_LSB 7
  728. #define RX_REO_QUEUE_CURRENT_MSDU_COUNT_MSB 31
  729. #define RX_REO_QUEUE_CURRENT_MSDU_COUNT_MASK 0xffffff80
  730. /* Description LAST_SN_REG_INDEX
  731. REO has registers to save the last SN seen in up to 9 REO
  732. queues, to support "leaky APs."
  733. This field gives the register number to use for saving the
  734. last SN of this REO queue.
  735. <legal 0-8>
  736. */
  737. #define RX_REO_QUEUE_LAST_SN_REG_INDEX_OFFSET 0x00000060
  738. #define RX_REO_QUEUE_LAST_SN_REG_INDEX_LSB 0
  739. #define RX_REO_QUEUE_LAST_SN_REG_INDEX_MSB 3
  740. #define RX_REO_QUEUE_LAST_SN_REG_INDEX_MASK 0x0000000f
  741. /* Description TIMEOUT_COUNT
  742. The number of times that REO started forwarding frames even
  743. though there is a hole in the bitmap. Forwarding reason
  744. is Timeout
  745. The counter saturates and freezes at 0x3F
  746. <legal all>
  747. */
  748. #define RX_REO_QUEUE_TIMEOUT_COUNT_OFFSET 0x00000060
  749. #define RX_REO_QUEUE_TIMEOUT_COUNT_LSB 4
  750. #define RX_REO_QUEUE_TIMEOUT_COUNT_MSB 9
  751. #define RX_REO_QUEUE_TIMEOUT_COUNT_MASK 0x000003f0
  752. /* Description FORWARD_DUE_TO_BAR_COUNT
  753. The number of times that REO started forwarding frames even
  754. though there is a hole in the bitmap. Forwarding reason
  755. is reception of BAR frame.
  756. The counter saturates and freezes at 0x3F
  757. <legal all>
  758. */
  759. #define RX_REO_QUEUE_FORWARD_DUE_TO_BAR_COUNT_OFFSET 0x00000060
  760. #define RX_REO_QUEUE_FORWARD_DUE_TO_BAR_COUNT_LSB 10
  761. #define RX_REO_QUEUE_FORWARD_DUE_TO_BAR_COUNT_MSB 15
  762. #define RX_REO_QUEUE_FORWARD_DUE_TO_BAR_COUNT_MASK 0x0000fc00
  763. /* Description DUPLICATE_COUNT
  764. The number of duplicate frames that have been detected
  765. <legal all>
  766. */
  767. #define RX_REO_QUEUE_DUPLICATE_COUNT_OFFSET 0x00000060
  768. #define RX_REO_QUEUE_DUPLICATE_COUNT_LSB 16
  769. #define RX_REO_QUEUE_DUPLICATE_COUNT_MSB 31
  770. #define RX_REO_QUEUE_DUPLICATE_COUNT_MASK 0xffff0000
  771. /* Description FRAMES_IN_ORDER_COUNT
  772. The number of frames that have been received in order (without
  773. a hole that prevented them from being forwarded immediately)
  774. This corresponds to the Reorder opcodes:
  775. 'FWDCUR' and 'FWD BUF'
  776. <legal all>
  777. */
  778. #define RX_REO_QUEUE_FRAMES_IN_ORDER_COUNT_OFFSET 0x00000064
  779. #define RX_REO_QUEUE_FRAMES_IN_ORDER_COUNT_LSB 0
  780. #define RX_REO_QUEUE_FRAMES_IN_ORDER_COUNT_MSB 23
  781. #define RX_REO_QUEUE_FRAMES_IN_ORDER_COUNT_MASK 0x00ffffff
  782. /* Description BAR_RECEIVED_COUNT
  783. The number of times a BAR frame is received.
  784. This corresponds to the Reorder opcodes with 'DROP'
  785. The counter saturates and freezes at 0xFF
  786. <legal all>
  787. */
  788. #define RX_REO_QUEUE_BAR_RECEIVED_COUNT_OFFSET 0x00000064
  789. #define RX_REO_QUEUE_BAR_RECEIVED_COUNT_LSB 24
  790. #define RX_REO_QUEUE_BAR_RECEIVED_COUNT_MSB 31
  791. #define RX_REO_QUEUE_BAR_RECEIVED_COUNT_MASK 0xff000000
  792. /* Description MPDU_FRAMES_PROCESSED_COUNT
  793. The total number of MPDU frames that have been processed
  794. by REO. 'Processing' here means that REO has received them
  795. out of the entrance ring, and retrieved the corresponding
  796. RX_REO_QUEUE Descriptor.
  797. Note that this count includes duplicates, frames that later
  798. had errors, etc.
  799. Note that field 'Duplicate_count' indicates how many of
  800. these MPDUs were duplicates.
  801. <legal all>
  802. */
  803. #define RX_REO_QUEUE_MPDU_FRAMES_PROCESSED_COUNT_OFFSET 0x00000068
  804. #define RX_REO_QUEUE_MPDU_FRAMES_PROCESSED_COUNT_LSB 0
  805. #define RX_REO_QUEUE_MPDU_FRAMES_PROCESSED_COUNT_MSB 31
  806. #define RX_REO_QUEUE_MPDU_FRAMES_PROCESSED_COUNT_MASK 0xffffffff
  807. /* Description MSDU_FRAMES_PROCESSED_COUNT
  808. The total number of MSDU frames that have been processed
  809. by REO. 'Processing' here means that REO has received them
  810. out of the entrance ring, and retrieved the corresponding
  811. RX_REO_QUEUE Descriptor.
  812. Note that this count includes duplicates, frames that later
  813. had errors, etc.
  814. <legal all>
  815. */
  816. #define RX_REO_QUEUE_MSDU_FRAMES_PROCESSED_COUNT_OFFSET 0x0000006c
  817. #define RX_REO_QUEUE_MSDU_FRAMES_PROCESSED_COUNT_LSB 0
  818. #define RX_REO_QUEUE_MSDU_FRAMES_PROCESSED_COUNT_MSB 31
  819. #define RX_REO_QUEUE_MSDU_FRAMES_PROCESSED_COUNT_MASK 0xffffffff
  820. /* Description TOTAL_PROCESSED_BYTE_COUNT
  821. An approximation of the number of bytes processed for this
  822. queue.
  823. 'Processing' here means that REO has received them out of
  824. the entrance ring, and retrieved the corresponding RX_REO_QUEUE
  825. Descriptor.
  826. Note that this count includes duplicates, frames that later
  827. had errors, etc.
  828. In 64 byte units
  829. <legal all>
  830. */
  831. #define RX_REO_QUEUE_TOTAL_PROCESSED_BYTE_COUNT_OFFSET 0x00000070
  832. #define RX_REO_QUEUE_TOTAL_PROCESSED_BYTE_COUNT_LSB 0
  833. #define RX_REO_QUEUE_TOTAL_PROCESSED_BYTE_COUNT_MSB 31
  834. #define RX_REO_QUEUE_TOTAL_PROCESSED_BYTE_COUNT_MASK 0xffffffff
  835. /* Description LATE_RECEIVE_MPDU_COUNT
  836. The number of MPDUs received after the window had already
  837. moved on. The 'late' sequence window is defined as (Window
  838. SSN - 256) - (Window SSN - 1)
  839. This corresponds with Out of order detection in duplicate
  840. detect FSM
  841. The counter saturates and freezes at 0xFFF
  842. <legal all>
  843. */
  844. #define RX_REO_QUEUE_LATE_RECEIVE_MPDU_COUNT_OFFSET 0x00000074
  845. #define RX_REO_QUEUE_LATE_RECEIVE_MPDU_COUNT_LSB 0
  846. #define RX_REO_QUEUE_LATE_RECEIVE_MPDU_COUNT_MSB 11
  847. #define RX_REO_QUEUE_LATE_RECEIVE_MPDU_COUNT_MASK 0x00000fff
  848. /* Description WINDOW_JUMP_2K
  849. The number of times the window moved more then 2K
  850. The counter saturates and freezes at 0xF
  851. (Note: field name can not start with number: previous 2k_window_jump)
  852. <legal all>
  853. */
  854. #define RX_REO_QUEUE_WINDOW_JUMP_2K_OFFSET 0x00000074
  855. #define RX_REO_QUEUE_WINDOW_JUMP_2K_LSB 12
  856. #define RX_REO_QUEUE_WINDOW_JUMP_2K_MSB 15
  857. #define RX_REO_QUEUE_WINDOW_JUMP_2K_MASK 0x0000f000
  858. /* Description HOLE_COUNT
  859. The number of times a hole was created in the receive bitmap.
  860. This corresponds to the Reorder opcodes with 'QCUR'
  861. <legal all>
  862. */
  863. #define RX_REO_QUEUE_HOLE_COUNT_OFFSET 0x00000074
  864. #define RX_REO_QUEUE_HOLE_COUNT_LSB 16
  865. #define RX_REO_QUEUE_HOLE_COUNT_MSB 31
  866. #define RX_REO_QUEUE_HOLE_COUNT_MASK 0xffff0000
  867. /* Description AGING_DROP_MPDU_COUNT
  868. The number of holes in the bitmap that moved due to aging
  869. counter expiry
  870. <legal all>
  871. */
  872. #define RX_REO_QUEUE_AGING_DROP_MPDU_COUNT_OFFSET 0x00000078
  873. #define RX_REO_QUEUE_AGING_DROP_MPDU_COUNT_LSB 0
  874. #define RX_REO_QUEUE_AGING_DROP_MPDU_COUNT_MSB 15
  875. #define RX_REO_QUEUE_AGING_DROP_MPDU_COUNT_MASK 0x0000ffff
  876. /* Description AGING_DROP_INTERVAL
  877. The number of times holes got removed from the bitmap due
  878. to aging counter expiry
  879. <legal all>
  880. */
  881. #define RX_REO_QUEUE_AGING_DROP_INTERVAL_OFFSET 0x00000078
  882. #define RX_REO_QUEUE_AGING_DROP_INTERVAL_LSB 16
  883. #define RX_REO_QUEUE_AGING_DROP_INTERVAL_MSB 23
  884. #define RX_REO_QUEUE_AGING_DROP_INTERVAL_MASK 0x00ff0000
  885. /* Description RESERVED_30
  886. <legal 0>
  887. */
  888. #define RX_REO_QUEUE_RESERVED_30_OFFSET 0x00000078
  889. #define RX_REO_QUEUE_RESERVED_30_LSB 24
  890. #define RX_REO_QUEUE_RESERVED_30_MSB 31
  891. #define RX_REO_QUEUE_RESERVED_30_MASK 0xff000000
  892. /* Description RESERVED_31
  893. <legal 0>
  894. */
  895. #define RX_REO_QUEUE_RESERVED_31_OFFSET 0x0000007c
  896. #define RX_REO_QUEUE_RESERVED_31_LSB 0
  897. #define RX_REO_QUEUE_RESERVED_31_MSB 31
  898. #define RX_REO_QUEUE_RESERVED_31_MASK 0xffffffff
  899. #endif // RX_REO_QUEUE