wbm_release_ring_tx.h 41 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044
  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 _WBM_RELEASE_RING_TX_H_
  17. #define _WBM_RELEASE_RING_TX_H_
  18. #if !defined(__ASSEMBLER__)
  19. #endif
  20. #include "tx_rate_stats_info.h"
  21. #include "buffer_addr_info.h"
  22. #define NUM_OF_DWORDS_WBM_RELEASE_RING_TX 8
  23. struct wbm_release_ring_tx {
  24. #ifndef WIFI_BIT_ORDER_BIG_ENDIAN
  25. struct buffer_addr_info released_buff_or_desc_addr_info;
  26. uint32_t release_source_module : 3, // [2:0]
  27. bm_action : 3, // [5:3]
  28. buffer_or_desc_type : 3, // [8:6]
  29. first_msdu_index : 4, // [12:9]
  30. tqm_release_reason : 4, // [16:13]
  31. rbm_override_valid : 1, // [17:17]
  32. rbm_override : 4, // [21:18]
  33. reserved_2a : 7, // [28:22]
  34. cache_id : 1, // [29:29]
  35. cookie_conversion_status : 1, // [30:30]
  36. wbm_internal_error : 1; // [31:31]
  37. uint32_t tqm_status_number : 24, // [23:0]
  38. transmit_count : 7, // [30:24]
  39. sw_release_details_valid : 1; // [31:31]
  40. uint32_t ack_frame_rssi : 8, // [7:0]
  41. first_msdu : 1, // [8:8]
  42. last_msdu : 1, // [9:9]
  43. fw_tx_notify_frame : 3, // [12:10]
  44. buffer_timestamp : 19; // [31:13]
  45. struct tx_rate_stats_info tx_rate_stats;
  46. uint32_t sw_peer_id : 16, // [15:0]
  47. tid : 4, // [19:16]
  48. tqm_status_number_31_24 : 8, // [27:20]
  49. looping_count : 4; // [31:28]
  50. #else
  51. struct buffer_addr_info released_buff_or_desc_addr_info;
  52. uint32_t wbm_internal_error : 1, // [31:31]
  53. cookie_conversion_status : 1, // [30:30]
  54. cache_id : 1, // [29:29]
  55. reserved_2a : 7, // [28:22]
  56. rbm_override : 4, // [21:18]
  57. rbm_override_valid : 1, // [17:17]
  58. tqm_release_reason : 4, // [16:13]
  59. first_msdu_index : 4, // [12:9]
  60. buffer_or_desc_type : 3, // [8:6]
  61. bm_action : 3, // [5:3]
  62. release_source_module : 3; // [2:0]
  63. uint32_t sw_release_details_valid : 1, // [31:31]
  64. transmit_count : 7, // [30:24]
  65. tqm_status_number : 24; // [23:0]
  66. uint32_t buffer_timestamp : 19, // [31:13]
  67. fw_tx_notify_frame : 3, // [12:10]
  68. last_msdu : 1, // [9:9]
  69. first_msdu : 1, // [8:8]
  70. ack_frame_rssi : 8; // [7:0]
  71. struct tx_rate_stats_info tx_rate_stats;
  72. uint32_t looping_count : 4, // [31:28]
  73. tqm_status_number_31_24 : 8, // [27:20]
  74. tid : 4, // [19:16]
  75. sw_peer_id : 16; // [15:0]
  76. #endif
  77. };
  78. /* Description RELEASED_BUFF_OR_DESC_ADDR_INFO
  79. Consumer: WBM/SW/FW
  80. Producer: SW/TQM/RXDMA/REO/SWITCH
  81. Details of the physical address of the buffer or link descriptor
  82. that is being released. Note that within this descriptor,
  83. WBM will look at the 'owner' of the released buffer/descriptor
  84. and forward it to SW/FW is WBM is not the owner.
  85. */
  86. /* Description BUFFER_ADDR_31_0
  87. Address (lower 32 bits) of the MSDU buffer OR MSDU_EXTENSION
  88. descriptor OR Link Descriptor
  89. In case of 'NULL' pointer, this field is set to 0
  90. <legal all>
  91. */
  92. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_BUFFER_ADDR_31_0_OFFSET 0x00000000
  93. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_BUFFER_ADDR_31_0_LSB 0
  94. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_BUFFER_ADDR_31_0_MSB 31
  95. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_BUFFER_ADDR_31_0_MASK 0xffffffff
  96. /* Description BUFFER_ADDR_39_32
  97. Address (upper 8 bits) of the MSDU buffer OR MSDU_EXTENSION
  98. descriptor OR Link Descriptor
  99. In case of 'NULL' pointer, this field is set to 0
  100. <legal all>
  101. */
  102. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_BUFFER_ADDR_39_32_OFFSET 0x00000004
  103. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_BUFFER_ADDR_39_32_LSB 0
  104. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_BUFFER_ADDR_39_32_MSB 7
  105. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_BUFFER_ADDR_39_32_MASK 0x000000ff
  106. /* Description RETURN_BUFFER_MANAGER
  107. Consumer: WBM
  108. Producer: SW/FW
  109. In case of 'NULL' pointer, this field is set to 0
  110. Indicates to which buffer manager the buffer OR MSDU_EXTENSION
  111. descriptor OR link descriptor that is being pointed to
  112. shall be returned after the frame has been processed. It
  113. is used by WBM for routing purposes.
  114. <enum 0 WBM_IDLE_BUF_LIST> This buffer shall be returned
  115. to the WMB buffer idle list
  116. <enum 1 WBM_CHIP0_IDLE_DESC_LIST> This buffer shall be returned
  117. to the WBM idle link descriptor idle list, where the chip
  118. 0 WBM is chosen in case of a multi-chip config
  119. <enum 2 WBM_CHIP1_IDLE_DESC_LIST> This buffer shall be returned
  120. to the chip 1 WBM idle link descriptor idle list
  121. <enum 3 WBM_CHIP2_IDLE_DESC_LIST> This buffer shall be returned
  122. to the chip 2 WBM idle link descriptor idle list
  123. <enum 12 WBM_CHIP3_IDLE_DESC_LIST> This buffer shall be
  124. returned to chip 3 WBM idle link descriptor idle list
  125. <enum 4 FW_BM> This buffer shall be returned to the FW
  126. <enum 5 SW0_BM> This buffer shall be returned to the SW,
  127. ring 0
  128. <enum 6 SW1_BM> This buffer shall be returned to the SW,
  129. ring 1
  130. <enum 7 SW2_BM> This buffer shall be returned to the SW,
  131. ring 2
  132. <enum 8 SW3_BM> This buffer shall be returned to the SW,
  133. ring 3
  134. <enum 9 SW4_BM> This buffer shall be returned to the SW,
  135. ring 4
  136. <enum 10 SW5_BM> This buffer shall be returned to the SW,
  137. ring 5
  138. <enum 11 SW6_BM> This buffer shall be returned to the SW,
  139. ring 6
  140. <legal 0-12>
  141. */
  142. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_OFFSET 0x00000004
  143. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_LSB 8
  144. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_MSB 11
  145. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_MASK 0x00000f00
  146. /* Description SW_BUFFER_COOKIE
  147. Cookie field exclusively used by SW.
  148. In case of 'NULL' pointer, this field is set to 0
  149. HW ignores the contents, accept that it passes the programmed
  150. value on to other descriptors together with the physical
  151. address
  152. Field can be used by SW to for example associate the buffers
  153. physical address with the virtual address
  154. The bit definitions as used by SW are within SW HLD specification
  155. NOTE1:
  156. The three most significant bits can have a special meaning
  157. in case this struct is embedded in a TX_MPDU_DETAILS STRUCT,
  158. and field transmit_bw_restriction is set
  159. In case of NON punctured transmission:
  160. Sw_buffer_cookie[19:17] = 3'b000: 20 MHz TX only
  161. Sw_buffer_cookie[19:17] = 3'b001: 40 MHz TX only
  162. Sw_buffer_cookie[19:17] = 3'b010: 80 MHz TX only
  163. Sw_buffer_cookie[19:17] = 3'b011: 160 MHz TX only
  164. Sw_buffer_cookie[19:17] = 3'b101: 240 MHz TX only
  165. Sw_buffer_cookie[19:17] = 3'b100: 320 MHz TX only
  166. Sw_buffer_cookie[19:18] = 2'b11: reserved
  167. In case of punctured transmission:
  168. Sw_buffer_cookie[19:16] = 4'b0000: pattern 0 only
  169. Sw_buffer_cookie[19:16] = 4'b0001: pattern 1 only
  170. Sw_buffer_cookie[19:16] = 4'b0010: pattern 2 only
  171. Sw_buffer_cookie[19:16] = 4'b0011: pattern 3 only
  172. Sw_buffer_cookie[19:16] = 4'b0100: pattern 4 only
  173. Sw_buffer_cookie[19:16] = 4'b0101: pattern 5 only
  174. Sw_buffer_cookie[19:16] = 4'b0110: pattern 6 only
  175. Sw_buffer_cookie[19:16] = 4'b0111: pattern 7 only
  176. Sw_buffer_cookie[19:16] = 4'b1000: pattern 8 only
  177. Sw_buffer_cookie[19:16] = 4'b1001: pattern 9 only
  178. Sw_buffer_cookie[19:16] = 4'b1010: pattern 10 only
  179. Sw_buffer_cookie[19:16] = 4'b1011: pattern 11 only
  180. Sw_buffer_cookie[19:18] = 2'b11: reserved
  181. Note: a punctured transmission is indicated by the presence
  182. of TLV TX_PUNCTURE_SETUP embedded in the scheduler TLV
  183. <legal all>
  184. */
  185. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_SW_BUFFER_COOKIE_OFFSET 0x00000004
  186. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_SW_BUFFER_COOKIE_LSB 12
  187. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_SW_BUFFER_COOKIE_MSB 31
  188. #define WBM_RELEASE_RING_TX_RELEASED_BUFF_OR_DESC_ADDR_INFO_SW_BUFFER_COOKIE_MASK 0xfffff000
  189. /* Description RELEASE_SOURCE_MODULE
  190. Indicates which module initiated the release of this buffer
  191. or descriptor
  192. <enum 1 release_source_RXDMA> DO NOT USE
  193. <enum 2 release_source_REO> DO NOT USE
  194. <enum 5 release_source_FW_RX> DO NOT USE
  195. <enum 4 release_source_SW_RX> DO NOT USE
  196. <enum 0 release_source_TQM> TQM released this buffer or
  197. descriptor
  198. <enum 3 release_source_FW_TX> FW released this buffer or
  199. descriptor
  200. <enum 6 release_source_SW_TX> SW released this buffer or
  201. descriptor
  202. <legal 0-6>
  203. */
  204. #define WBM_RELEASE_RING_TX_RELEASE_SOURCE_MODULE_OFFSET 0x00000008
  205. #define WBM_RELEASE_RING_TX_RELEASE_SOURCE_MODULE_LSB 0
  206. #define WBM_RELEASE_RING_TX_RELEASE_SOURCE_MODULE_MSB 2
  207. #define WBM_RELEASE_RING_TX_RELEASE_SOURCE_MODULE_MASK 0x00000007
  208. /* Description BM_ACTION
  209. Consumer: WBM/SW/FW
  210. Producer: SW/TQM/RXDMA/REO/SWITCH
  211. Field only valid when the field return_buffer_manager in
  212. the Released_buff_or_desc_addr_info indicates:
  213. WBM_IDLE_BUF_LIST or
  214. WBM_IDLE_DESC_LIST
  215. An MSDU extension descriptor shall never be marked as WBM
  216. being the 'owner', and thus WBM will forward it to FW/SW
  217. <enum 0 Put_in_idle_list> Put the buffer or descriptor back
  218. in the idle list. In case of MSDU or MDPU link descriptor,
  219. BM does not need to check to release any individual MSDU
  220. buffers
  221. <enum 1 release_msdu_list > This BM action can only be used
  222. in combination with buffer_or_desc_type being msdu_link_descriptor.
  223. Field first_msdu_index points out which MSDU pointer in
  224. the MSDU link descriptor is the first of an MPDU that is
  225. released.
  226. BM shall release all the MSDU buffers linked to this first
  227. MSDU buffer pointer. All related MSDU buffer pointer entries
  228. shall be set to value 0, which represents the 'NULL" pointer.
  229. When all MSDU buffer pointers in the MSDU link descriptor
  230. are 'NULL', the MSDU link descriptor itself shall also
  231. be released.
  232. <enum 2 Put_in_idle_list_expanded> CURRENTLY NOT IMPLEMENTED....
  233. Put the buffer or descriptor back in the idle list. Only
  234. valid in combination with buffer_or_desc_type indicating
  235. MDPU_link_descriptor.
  236. BM shall release the MPDU link descriptor as well as all
  237. MSDUs that are linked to the MPDUs in this descriptor.
  238. <legal 0-2>
  239. */
  240. #define WBM_RELEASE_RING_TX_BM_ACTION_OFFSET 0x00000008
  241. #define WBM_RELEASE_RING_TX_BM_ACTION_LSB 3
  242. #define WBM_RELEASE_RING_TX_BM_ACTION_MSB 5
  243. #define WBM_RELEASE_RING_TX_BM_ACTION_MASK 0x00000038
  244. /* Description BUFFER_OR_DESC_TYPE
  245. Consumer: WBM/SW/FW
  246. Producer: SW/TQM/RXDMA/REO/SWITCH
  247. Field only valid when WBM is marked as the return_buffer_manager
  248. in the Released_Buffer_address_info
  249. Indicates that type of buffer or descriptor is being released
  250. <enum 0 MSDU_rel_buffer> The address points to an MSDU buffer
  251. <enum 1 msdu_link_descriptor> The address points to an TX
  252. MSDU link descriptor
  253. <enum 2 mpdu_link_descriptor> The address points to an MPDU
  254. link descriptor
  255. <enum 3 msdu_ext_descriptor > The address points to an MSDU
  256. extension descriptor.
  257. In case BM finds this one in a release ring, it passes it
  258. on to FW...
  259. <enum 4 queue_ext_descriptor> The address points to an TQM
  260. queue extension descriptor. WBM should treat this is the
  261. same way as a link descriptor. That is, put the 128 byte
  262. buffer back in the link buffer idle list.
  263. <legal 0-4>
  264. */
  265. #define WBM_RELEASE_RING_TX_BUFFER_OR_DESC_TYPE_OFFSET 0x00000008
  266. #define WBM_RELEASE_RING_TX_BUFFER_OR_DESC_TYPE_LSB 6
  267. #define WBM_RELEASE_RING_TX_BUFFER_OR_DESC_TYPE_MSB 8
  268. #define WBM_RELEASE_RING_TX_BUFFER_OR_DESC_TYPE_MASK 0x000001c0
  269. /* Description FIRST_MSDU_INDEX
  270. Consumer: WBM/SW/FW
  271. Producer: SW/TQM/RXDMA/REO/SWITCH
  272. Field only valid for the bm_action release_msdu_list.
  273. The index of the first MSDU in an MSDU link descriptor all
  274. belonging to the same MPDU.
  275. <legal 0-6>
  276. */
  277. #define WBM_RELEASE_RING_TX_FIRST_MSDU_INDEX_OFFSET 0x00000008
  278. #define WBM_RELEASE_RING_TX_FIRST_MSDU_INDEX_LSB 9
  279. #define WBM_RELEASE_RING_TX_FIRST_MSDU_INDEX_MSB 12
  280. #define WBM_RELEASE_RING_TX_FIRST_MSDU_INDEX_MASK 0x00001e00
  281. /* Description TQM_RELEASE_REASON
  282. Consumer: WBM/SW/FW
  283. Producer: TQM
  284. Field only valid when Release_source_module is set to release_source_TQM
  285. (rr = Release Reason)
  286. <enum 0 tqm_rr_frame_acked> frame is removed because an
  287. ACK of BA for it was received
  288. <enum 1 tqm_rr_rem_cmd_rem> frame is removed because a remove
  289. command of type "Remove_mpdus" initiated by SW
  290. <enum 2 tqm_rr_rem_cmd_tx> frame is removed because a remove
  291. command of type "Remove_transmitted_mpdus" initiated by
  292. SW
  293. <enum 3 tqm_rr_rem_cmd_notx> frame is removed because a
  294. remove command of type "Remove_untransmitted_mpdus" initiated
  295. by SW
  296. <enum 4 tqm_rr_rem_cmd_aged> frame is removed because a
  297. remove command of type "Remove_aged_mpdus" or "Remove_aged_msdus"
  298. initiated by SW
  299. <enum 5 tqm_fw_reason1> frame is removed because a remove
  300. command where fw indicated that remove reason is fw_reason1
  301. <enum 6 tqm_fw_reason2> frame is removed because a remove
  302. command where fw indicated that remove reason is fw_reason1
  303. <enum 7 tqm_fw_reason3> frame is removed because a remove
  304. command where fw indicated that remove reason is fw_reason1
  305. <enum 8 tqm_rr_rem_cmd_disable_queue> frame is removed because
  306. a remove command of type "remove_mpdus_and_disable_queue"
  307. or "remove_msdus_and_disable_flow" initiated by SW
  308. <enum 9 tqm_rr_rem_cmd_till_nonmatching> frame is removed
  309. because remove command of type "remove_till_nonmatching_mpdu"
  310. initiated by SW
  311. <enum 10 tqm_rr_drop_threshold> frame is dropped at TQM
  312. entrance due to one of slow/medium/hard drop threshold criteria
  313. <enum 11 tqm_rr_link_desc_unavailable> frame is dropped
  314. at TQM entrance due to the WBM2TQM_LINK_RING having fewer
  315. descriptors than a threshold programmed in TQM
  316. <enum 12 tqm_rr_drop_or_invalid_msdu> frame is dropped at
  317. TQM entrance due to 'TQM_Drop_frame' being set or "null"
  318. MSDU flow pointer or MSDU flow pointer 'Flow_valid' being
  319. zero or MSDU length being zero
  320. <enum 13 tqm_rr_multicast_drop> frame is dropped at TQM
  321. entrance due to 'TQM_Drop_frame' being set with 'TCL_drop_reason'
  322. set to TCL_multicast_drop_for_vdev.
  323. <enum 14 tqm_rr_vdev_mismatch_drop> frame is dropped at
  324. TQM entrance due to 'TQM_Drop_frame' being set with 'TCL_drop_reason'
  325. set to TCL_vdev_id_mismatch_drop.
  326. <legal 0-14>
  327. */
  328. #define WBM_RELEASE_RING_TX_TQM_RELEASE_REASON_OFFSET 0x00000008
  329. #define WBM_RELEASE_RING_TX_TQM_RELEASE_REASON_LSB 13
  330. #define WBM_RELEASE_RING_TX_TQM_RELEASE_REASON_MSB 16
  331. #define WBM_RELEASE_RING_TX_TQM_RELEASE_REASON_MASK 0x0001e000
  332. /* Description RBM_OVERRIDE_VALID
  333. This is set to 0 for Tx cases not involving reinjection,
  334. and set to 1 for TQM release cases requiring FW reinjection
  335. When set to 1, WBM releases the MSDU buffers to FW and overrides
  336. the tx_rate_stats field with words 2 and 3 of the 'TX_MSDU_DETAILS'
  337. structure, for FW reinjection of these MSDUs
  338. <legal 0-1>
  339. */
  340. #define WBM_RELEASE_RING_TX_RBM_OVERRIDE_VALID_OFFSET 0x00000008
  341. #define WBM_RELEASE_RING_TX_RBM_OVERRIDE_VALID_LSB 17
  342. #define WBM_RELEASE_RING_TX_RBM_OVERRIDE_VALID_MSB 17
  343. #define WBM_RELEASE_RING_TX_RBM_OVERRIDE_VALID_MASK 0x00020000
  344. /* Description RBM_OVERRIDE
  345. Field only valid when rbm_override_valid = 1
  346. WBM releases the MSDU buffers to FW and overrides the tx_rate_stats
  347. field with words 2 and 3 of the 'TX_MSDU_DETAILS' structure,
  348. for FW reinjection of these MSDUs.
  349. */
  350. #define WBM_RELEASE_RING_TX_RBM_OVERRIDE_OFFSET 0x00000008
  351. #define WBM_RELEASE_RING_TX_RBM_OVERRIDE_LSB 18
  352. #define WBM_RELEASE_RING_TX_RBM_OVERRIDE_MSB 21
  353. #define WBM_RELEASE_RING_TX_RBM_OVERRIDE_MASK 0x003c0000
  354. /* Description RESERVED_2A
  355. <legal 0>
  356. */
  357. #define WBM_RELEASE_RING_TX_RESERVED_2A_OFFSET 0x00000008
  358. #define WBM_RELEASE_RING_TX_RESERVED_2A_LSB 22
  359. #define WBM_RELEASE_RING_TX_RESERVED_2A_MSB 28
  360. #define WBM_RELEASE_RING_TX_RESERVED_2A_MASK 0x1fc00000
  361. /* Description CACHE_ID
  362. To improve WBM performance, out-of-order completions may
  363. be allowed to process multiple MPDUs in parallel.
  364. The MSDUs released from each cache would be in order so 'First_msdu'
  365. and this field together can be used by SW to reorder the
  366. completions back to the original order by keeping all MSDUs
  367. of an MPDU from one cache together before switching to
  368. the next MPDU (from either cache).
  369. <legal all>
  370. */
  371. #define WBM_RELEASE_RING_TX_CACHE_ID_OFFSET 0x00000008
  372. #define WBM_RELEASE_RING_TX_CACHE_ID_LSB 29
  373. #define WBM_RELEASE_RING_TX_CACHE_ID_MSB 29
  374. #define WBM_RELEASE_RING_TX_CACHE_ID_MASK 0x20000000
  375. /* Description COOKIE_CONVERSION_STATUS
  376. 0: 'Sw_buffer_cookie' not converted to 'Buffer_virt_addr'
  377. 1: 'Sw_buffer_cookie' coverted to 'Buffer_virt_addr'
  378. <legal 0>
  379. */
  380. #define WBM_RELEASE_RING_TX_COOKIE_CONVERSION_STATUS_OFFSET 0x00000008
  381. #define WBM_RELEASE_RING_TX_COOKIE_CONVERSION_STATUS_LSB 30
  382. #define WBM_RELEASE_RING_TX_COOKIE_CONVERSION_STATUS_MSB 30
  383. #define WBM_RELEASE_RING_TX_COOKIE_CONVERSION_STATUS_MASK 0x40000000
  384. /* Description WBM_INTERNAL_ERROR
  385. Can only be set by WBM.
  386. Is set when WBM got a buffer pointer but the action was
  387. to push it to the idle link descriptor ring or do link related
  388. activity
  389. OR
  390. Is set when WBM got a link buffer pointer but the action
  391. was to push it to the buffer descriptor ring
  392. <legal all>
  393. */
  394. #define WBM_RELEASE_RING_TX_WBM_INTERNAL_ERROR_OFFSET 0x00000008
  395. #define WBM_RELEASE_RING_TX_WBM_INTERNAL_ERROR_LSB 31
  396. #define WBM_RELEASE_RING_TX_WBM_INTERNAL_ERROR_MSB 31
  397. #define WBM_RELEASE_RING_TX_WBM_INTERNAL_ERROR_MASK 0x80000000
  398. /* Description TQM_STATUS_NUMBER
  399. Field only valid when Release_source_module is set to release_source_TQM
  400. The value in this field is equal to value of the 'TQM_CMD_Number'
  401. field from the TQM command or the 'TQM_add_cmd_Number' field
  402. from the TQM entrance ring descriptor LSB 24-bits.
  403. This field helps to correlate the statuses with the TQM
  404. commands.
  405. NOTE that SW could program this number to be equal to the
  406. PPDU_ID number in case direct correlation with the PPDU
  407. ID is desired
  408. <legal all>
  409. */
  410. #define WBM_RELEASE_RING_TX_TQM_STATUS_NUMBER_OFFSET 0x0000000c
  411. #define WBM_RELEASE_RING_TX_TQM_STATUS_NUMBER_LSB 0
  412. #define WBM_RELEASE_RING_TX_TQM_STATUS_NUMBER_MSB 23
  413. #define WBM_RELEASE_RING_TX_TQM_STATUS_NUMBER_MASK 0x00ffffff
  414. /* Description TRANSMIT_COUNT
  415. Field only valid when Release_source_module is set to release_source_TQM
  416. The number of times this frame has been transmitted
  417. */
  418. #define WBM_RELEASE_RING_TX_TRANSMIT_COUNT_OFFSET 0x0000000c
  419. #define WBM_RELEASE_RING_TX_TRANSMIT_COUNT_LSB 24
  420. #define WBM_RELEASE_RING_TX_TRANSMIT_COUNT_MSB 30
  421. #define WBM_RELEASE_RING_TX_TRANSMIT_COUNT_MASK 0x7f000000
  422. /* Description SW_RELEASE_DETAILS_VALID
  423. Consumer: SW
  424. Producer: WBM
  425. When set, some WBM specific release info for SW is valid.
  426. This is set when WMB got a 'release_msdu_list' command from
  427. TQM and the return buffer manager is not WMB. WBM will
  428. then de-aggregate all the MSDUs and pass them one at a time
  429. on to the 'buffer owner'
  430. <legal all>
  431. */
  432. #define WBM_RELEASE_RING_TX_SW_RELEASE_DETAILS_VALID_OFFSET 0x0000000c
  433. #define WBM_RELEASE_RING_TX_SW_RELEASE_DETAILS_VALID_LSB 31
  434. #define WBM_RELEASE_RING_TX_SW_RELEASE_DETAILS_VALID_MSB 31
  435. #define WBM_RELEASE_RING_TX_SW_RELEASE_DETAILS_VALID_MASK 0x80000000
  436. /* Description ACK_FRAME_RSSI
  437. This field is only valid when the source is TQM.
  438. If this frame is removed as the result of the reception
  439. of an ACK or BA, this field indicates the RSSI of the received
  440. ACK or BA frame.
  441. When the frame is removed as result of a direct remove command
  442. from the SW, this field is set to 0x0 (which is never
  443. a valid value when real RSSI is available)
  444. <legal all>
  445. */
  446. #define WBM_RELEASE_RING_TX_ACK_FRAME_RSSI_OFFSET 0x00000010
  447. #define WBM_RELEASE_RING_TX_ACK_FRAME_RSSI_LSB 0
  448. #define WBM_RELEASE_RING_TX_ACK_FRAME_RSSI_MSB 7
  449. #define WBM_RELEASE_RING_TX_ACK_FRAME_RSSI_MASK 0x000000ff
  450. /* Description FIRST_MSDU
  451. Field only valid when SW_release_details_valid is set.
  452. Consumer: SW
  453. Producer: WBM
  454. When set, this MSDU is the first MSDU pointed to in the 'release_msdu_list'
  455. command.
  456. First_msdu ≠ last_msdu indicates the MSDU was part of
  457. an A-MSDU.
  458. <legal all>
  459. */
  460. #define WBM_RELEASE_RING_TX_FIRST_MSDU_OFFSET 0x00000010
  461. #define WBM_RELEASE_RING_TX_FIRST_MSDU_LSB 8
  462. #define WBM_RELEASE_RING_TX_FIRST_MSDU_MSB 8
  463. #define WBM_RELEASE_RING_TX_FIRST_MSDU_MASK 0x00000100
  464. /* Description LAST_MSDU
  465. Field only valid when SW_release_details_valid is set.
  466. Consumer: SW
  467. Producer: WBM
  468. When set, this MSDU is the last MSDU pointed to in the 'release_msdu_list'
  469. command.
  470. First_msdu ≠ last_msdu indicates the MSDU was part of
  471. an A-MSDU.
  472. <legal all>
  473. */
  474. #define WBM_RELEASE_RING_TX_LAST_MSDU_OFFSET 0x00000010
  475. #define WBM_RELEASE_RING_TX_LAST_MSDU_LSB 9
  476. #define WBM_RELEASE_RING_TX_LAST_MSDU_MSB 9
  477. #define WBM_RELEASE_RING_TX_LAST_MSDU_MASK 0x00000200
  478. /* Description FW_TX_NOTIFY_FRAME
  479. Field only valid when SW_release_details_valid is set.
  480. Consumer: SW
  481. Producer: WBM
  482. This is the FW_tx_notify_frame field from the TX_MSDU_DETAILS
  483. for this frame from the MSDU link descriptor
  484. <legal all>
  485. */
  486. #define WBM_RELEASE_RING_TX_FW_TX_NOTIFY_FRAME_OFFSET 0x00000010
  487. #define WBM_RELEASE_RING_TX_FW_TX_NOTIFY_FRAME_LSB 10
  488. #define WBM_RELEASE_RING_TX_FW_TX_NOTIFY_FRAME_MSB 12
  489. #define WBM_RELEASE_RING_TX_FW_TX_NOTIFY_FRAME_MASK 0x00001c00
  490. /* Description BUFFER_TIMESTAMP
  491. Field only valid when SW_release_details_valid is set.
  492. Consumer: SW
  493. Producer: WBM
  494. This is the Buffer_timestamp field from the TX_MSDU_DETAILS
  495. for this frame from the MSDU link descriptor.
  496. Timestamp in units determined by the UMCMN 'TX_TIMESTAMP_RESOLUTION_SELECT'
  497. register
  498. <legal all>
  499. */
  500. #define WBM_RELEASE_RING_TX_BUFFER_TIMESTAMP_OFFSET 0x00000010
  501. #define WBM_RELEASE_RING_TX_BUFFER_TIMESTAMP_LSB 13
  502. #define WBM_RELEASE_RING_TX_BUFFER_TIMESTAMP_MSB 31
  503. #define WBM_RELEASE_RING_TX_BUFFER_TIMESTAMP_MASK 0xffffe000
  504. /* Description TX_RATE_STATS
  505. Consumer: TQM/SW
  506. Producer: SW/SCH(from TXPCU, PDG) /WBM (from RXDMA)
  507. Details for command execution tracking purposes.
  508. */
  509. /* Description TX_RATE_STATS_INFO_VALID
  510. When set all other fields in this STRUCT contain valid info.
  511. When clear, none of the other fields contain valid info.
  512. <legal all>
  513. */
  514. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TX_RATE_STATS_INFO_VALID_OFFSET 0x00000014
  515. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TX_RATE_STATS_INFO_VALID_LSB 0
  516. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TX_RATE_STATS_INFO_VALID_MSB 0
  517. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TX_RATE_STATS_INFO_VALID_MASK 0x00000001
  518. /* Description TRANSMIT_BW
  519. Field only valid when Tx_rate_stats_info_valid is set
  520. Indicates the BW of the upcoming transmission that shall
  521. likely start in about 3 -4 us on the medium
  522. <enum 0 20_mhz>20 Mhz BW
  523. <enum 1 40_mhz>40 Mhz BW
  524. <enum 2 80_mhz>80 Mhz BW
  525. <enum 3 160_mhz>160 Mhz BW
  526. <enum 4 320_mhz>320 Mhz BW
  527. <enum 5 240_mhz>240 Mhz BW
  528. */
  529. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_BW_OFFSET 0x00000014
  530. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_BW_LSB 1
  531. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_BW_MSB 3
  532. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_BW_MASK 0x0000000e
  533. /* Description TRANSMIT_PKT_TYPE
  534. Field only valid when Tx_rate_stats_info_valid is set
  535. Field filled in by PDG.
  536. Not valid when in SW transmit mode
  537. The packet type
  538. <enum 0 dot11a>802.11a PPDU type
  539. <enum 1 dot11b>802.11b PPDU type
  540. <enum 2 dot11n_mm>802.11n Mixed Mode PPDU type
  541. <enum 3 dot11ac>802.11ac PPDU type
  542. <enum 4 dot11ax>802.11ax PPDU type
  543. <enum 5 dot11ba>802.11ba (WUR) PPDU type
  544. <enum 6 dot11be>802.11be PPDU type
  545. <enum 7 dot11az>802.11az (ranging) PPDU type
  546. <enum 8 dot11n_gf>802.11n Green Field PPDU type (unsupported
  547. & aborted)
  548. */
  549. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_PKT_TYPE_OFFSET 0x00000014
  550. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_PKT_TYPE_LSB 4
  551. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_PKT_TYPE_MSB 7
  552. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_PKT_TYPE_MASK 0x000000f0
  553. /* Description TRANSMIT_STBC
  554. Field only valid when Tx_rate_stats_info_valid is set
  555. Field filled in by PDG.
  556. Not valid when in SW transmit mode
  557. When set, STBC transmission rate was used.
  558. */
  559. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_STBC_OFFSET 0x00000014
  560. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_STBC_LSB 8
  561. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_STBC_MSB 8
  562. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_STBC_MASK 0x00000100
  563. /* Description TRANSMIT_LDPC
  564. Field only valid when Tx_rate_stats_info_valid is set
  565. Field filled in by PDG.
  566. Not valid when in SW transmit mode
  567. When set, use LDPC transmission rates
  568. */
  569. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_LDPC_OFFSET 0x00000014
  570. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_LDPC_LSB 9
  571. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_LDPC_MSB 9
  572. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_LDPC_MASK 0x00000200
  573. /* Description TRANSMIT_SGI
  574. Field only valid when Tx_rate_stats_info_valid is set
  575. Field filled in by PDG.
  576. Not valid when in SW transmit mode
  577. Specify the right GI for HE-Ranging NDPs (11az)/Short NDP.
  578. <enum 0 0_8_us_sgi > Legacy normal GI. Can also be used
  579. for HE
  580. <enum 1 0_4_us_sgi > Legacy short GI. Can also be used
  581. for HE
  582. <enum 2 1_6_us_sgi > HE related GI
  583. <enum 3 3_2_us_sgi > HE related GI
  584. <legal 0 - 3>
  585. */
  586. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_SGI_OFFSET 0x00000014
  587. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_SGI_LSB 10
  588. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_SGI_MSB 11
  589. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_SGI_MASK 0x00000c00
  590. /* Description TRANSMIT_MCS
  591. Field only valid when Tx_rate_stats_info_valid is set
  592. Field filled in by PDG.
  593. Not valid when in SW transmit mode
  594. For details, refer to MCS_TYPE description
  595. <legal all>
  596. */
  597. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_MCS_OFFSET 0x00000014
  598. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_MCS_LSB 12
  599. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_MCS_MSB 15
  600. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_MCS_MASK 0x0000f000
  601. /* Description OFDMA_TRANSMISSION
  602. Field only valid when Tx_rate_stats_info_valid is set
  603. Field filled in by PDG.
  604. Set when the transmission was an OFDMA transmission (DL
  605. or UL).
  606. <legal all>
  607. */
  608. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_OFDMA_TRANSMISSION_OFFSET 0x00000014
  609. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_OFDMA_TRANSMISSION_LSB 16
  610. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_OFDMA_TRANSMISSION_MSB 16
  611. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_OFDMA_TRANSMISSION_MASK 0x00010000
  612. /* Description TONES_IN_RU
  613. Field only valid when Tx_rate_stats_info_valid is set
  614. Field filled in by PDG.
  615. Not valid when in SW transmit mode
  616. The number of tones in the RU used.
  617. <legal all>
  618. */
  619. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TONES_IN_RU_OFFSET 0x00000014
  620. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TONES_IN_RU_LSB 17
  621. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TONES_IN_RU_MSB 28
  622. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TONES_IN_RU_MASK 0x1ffe0000
  623. /* Description TRANSMIT_NSS
  624. Field only valid when Tx_rate_stats_info_valid is set
  625. Field filled in by PDG
  626. Not valid when in SW transmit mode
  627. The number of spatial streams used in the transmission
  628. <enum 0 1_spatial_stream>Single spatial stream
  629. <enum 1 2_spatial_streams>2 spatial streams
  630. <enum 2 3_spatial_streams>3 spatial streams
  631. <enum 3 4_spatial_streams>4 spatial streams
  632. <enum 4 5_spatial_streams>5 spatial streams
  633. <enum 5 6_spatial_streams>6 spatial streams
  634. <enum 6 7_spatial_streams>7 spatial streams
  635. <enum 7 8_spatial_streams>8 spatial streams
  636. */
  637. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_NSS_OFFSET 0x00000014
  638. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_NSS_LSB 29
  639. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_NSS_MSB 31
  640. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_TRANSMIT_NSS_MASK 0xe0000000
  641. /* Description PPDU_TRANSMISSION_TSF
  642. Field only valid when Tx_rate_stats_info_valid is set
  643. Based on a HWSCH configuration register setting, this field
  644. either contains:
  645. Lower 32 bits of the TSF, snapshot of this value when transmission
  646. of the PPDU containing the frame finished.
  647. OR
  648. Lower 32 bits of the TSF, snapshot of this value when transmission
  649. of the PPDU containing the frame started
  650. <legal all>
  651. */
  652. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_PPDU_TRANSMISSION_TSF_OFFSET 0x00000018
  653. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_PPDU_TRANSMISSION_TSF_LSB 0
  654. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_PPDU_TRANSMISSION_TSF_MSB 31
  655. #define WBM_RELEASE_RING_TX_TX_RATE_STATS_PPDU_TRANSMISSION_TSF_MASK 0xffffffff
  656. /* Description SW_PEER_ID
  657. Field only valid when Release_source_module is set to release_source_TQM
  658. 1) Release of msdu buffer due to drop_frame = 1. Flow is
  659. not fetched and hence sw_peer_id and tid = 0
  660. buffer_or_desc_type = e_num 0 MSDU_rel_buffertqm_release_reason
  661. = e_num 1 tqm_rr_rem_cmd_rem
  662. 2) Release of msdu buffer due to Flow is not fetched and
  663. hence sw_peer_id and tid = 0
  664. buffer_or_desc_type = e_num 0 MSDU_rel_buffertqm_release_reason
  665. = e_num 1 tqm_rr_rem_cmd_rem
  666. 3) Release of msdu link due to remove_mpdu or acked_mpdu
  667. command.
  668. buffer_or_desc_type = e_num1 msdu_link_descriptortqm_release_reason
  669. can be:e_num 1 tqm_rr_rem_cmd_reme_num 2 tqm_rr_rem_cmd_tx
  670. e_num 3 tqm_rr_rem_cmd_notxe_num 4 tqm_rr_rem_cmd_aged (this
  671. e_num is used for REMOVE_MPDU as well as REMOVE_MSDU).
  672. Sw_peer_id from the TX_MSDU_FLOW descriptor or TX_MPDU_QUEUE
  673. descriptor
  674. <legal all>
  675. */
  676. #define WBM_RELEASE_RING_TX_SW_PEER_ID_OFFSET 0x0000001c
  677. #define WBM_RELEASE_RING_TX_SW_PEER_ID_LSB 0
  678. #define WBM_RELEASE_RING_TX_SW_PEER_ID_MSB 15
  679. #define WBM_RELEASE_RING_TX_SW_PEER_ID_MASK 0x0000ffff
  680. /* Description TID
  681. Field only valid when Release_source_module is set to release_source_TQM
  682. 1) Release of msdu buffer due to drop_frame = 1. Flow is
  683. not fetched and hence sw_peer_id and tid = 0
  684. buffer_or_desc_type = e_num 0 MSDU_rel_buffertqm_release_reason
  685. = e_num 1 tqm_rr_rem_cmd_rem
  686. 2) Release of msdu buffer due to Flow is not fetched and
  687. hence sw_peer_id and tid = 0
  688. buffer_or_desc_type = e_num 0 MSDU_rel_buffertqm_release_reason
  689. = e_num 1 tqm_rr_rem_cmd_rem
  690. 3) Release of msdu link due to remove_mpdu or acked_mpdu
  691. command.
  692. buffer_or_desc_type = e_num1 msdu_link_descriptortqm_release_reason
  693. can be:e_num 1 tqm_rr_rem_cmd_reme_num 2 tqm_rr_rem_cmd_tx
  694. e_num 3 tqm_rr_rem_cmd_notxe_num 4 tqm_rr_rem_cmd_aged (this
  695. e_num is used for REMOVE_MPDU as well as REMOVE_MSDU).
  696. This field represents the TID from the TX_MSDU_FLOW descriptor
  697. or TX_MPDU_QUEUE descriptor
  698. <legal all>
  699. */
  700. #define WBM_RELEASE_RING_TX_TID_OFFSET 0x0000001c
  701. #define WBM_RELEASE_RING_TX_TID_LSB 16
  702. #define WBM_RELEASE_RING_TX_TID_MSB 19
  703. #define WBM_RELEASE_RING_TX_TID_MASK 0x000f0000
  704. /* Description TQM_STATUS_NUMBER_31_24
  705. Field only valid when Release_source_module is set to release_source_TQM
  706. The value in this field is equal to value of the 'TQM_CMD_Number'
  707. field from the TQM command or the 'TQM_add_cmd_Number' field
  708. from the TQM entrance ring descriptor MSB 8-bits.
  709. This field helps to correlate the statuses with the TQM
  710. commands.
  711. <legal all>
  712. */
  713. #define WBM_RELEASE_RING_TX_TQM_STATUS_NUMBER_31_24_OFFSET 0x0000001c
  714. #define WBM_RELEASE_RING_TX_TQM_STATUS_NUMBER_31_24_LSB 20
  715. #define WBM_RELEASE_RING_TX_TQM_STATUS_NUMBER_31_24_MSB 27
  716. #define WBM_RELEASE_RING_TX_TQM_STATUS_NUMBER_31_24_MASK 0x0ff00000
  717. /* Description LOOPING_COUNT
  718. Consumer: WBM/SW/FW
  719. Producer: SW/TQM/RXDMA/REO/SWITCH
  720. If WBM_internal_error is set, this descriptor is sent to
  721. the dedicated 'WBM_ERROR_RELEASE' ring and Looping_count
  722. is used to indicate an error code.
  723. The values reported are documented further in the WBM MLD
  724. doc.
  725. If WBM_internal_error is not set, the following holds.
  726. A count value that indicates the number of times the producer
  727. of entries into the Buffer Manager Ring has looped around
  728. the ring.
  729. At initialization time, this value is set to 0. On the first
  730. loop, this value is set to 1. After the max value is reached
  731. allowed by the number of bits for this field, the count
  732. value continues with 0 again.
  733. In case SW is the consumer of the ring entries, it can use
  734. this field to figure out up to where the producer of entries
  735. has created new entries. This eliminates the need to check
  736. where the "head pointer' of the ring is located once the
  737. SW starts processing an interrupt indicating that new entries
  738. have been put into this ring...
  739. Also note that SW if it wants only needs to look at the
  740. LSB bit of this count value.
  741. <legal all>
  742. */
  743. #define WBM_RELEASE_RING_TX_LOOPING_COUNT_OFFSET 0x0000001c
  744. #define WBM_RELEASE_RING_TX_LOOPING_COUNT_LSB 28
  745. #define WBM_RELEASE_RING_TX_LOOPING_COUNT_MSB 31
  746. #define WBM_RELEASE_RING_TX_LOOPING_COUNT_MASK 0xf0000000
  747. #endif // WBM_RELEASE_RING_TX