wbm_release_ring.h 41 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568
  1. /*
  2. * Copyright (c) 2016-2017 The Linux Foundation. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for
  5. * any purpose with or without fee is hereby granted, provided that the
  6. * above copyright notice and this permission notice appear in all
  7. * copies.
  8. *
  9. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
  10. * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
  11. * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
  12. * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
  13. * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
  14. * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  15. * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  16. * PERFORMANCE OF THIS SOFTWARE.
  17. */
  18. #ifndef _WBM_RELEASE_RING_H_
  19. #define _WBM_RELEASE_RING_H_
  20. #if !defined(__ASSEMBLER__)
  21. #endif
  22. #include "buffer_addr_info.h"
  23. #include "tx_rate_stats_info.h"
  24. // ################ START SUMMARY #################
  25. //
  26. // Dword Fields
  27. // 0-1 struct buffer_addr_info released_buff_or_desc_addr_info;
  28. // 2 release_source_module[2:0], bm_action[5:3], buffer_or_desc_type[8:6], first_msdu_index[12:9], tqm_release_reason[15:13], rxdma_push_reason[17:16], rxdma_error_code[22:18], reo_push_reason[24:23], reo_error_code[29:25], wbm_internal_error[30], reserved_2[31]
  29. // 3 tqm_status_number[23:0], transmit_count[30:24], reserved_3a[31]
  30. // 4 ack_frame_rssi[7:0], sw_release_details_valid[8], first_msdu[9], last_msdu[10], msdu_part_of_amsdu[11], fw_tx_notify_frame[12], buffer_timestamp[31:13]
  31. // 5-6 struct tx_rate_stats_info tx_rate_stats;
  32. // 7 sw_peer_id[15:0], tid[19:16], ring_id[27:20], looping_count[31:28]
  33. //
  34. // ################ END SUMMARY #################
  35. #define NUM_OF_DWORDS_WBM_RELEASE_RING 8
  36. struct wbm_release_ring {
  37. struct buffer_addr_info released_buff_or_desc_addr_info;
  38. uint32_t release_source_module : 3, //[2:0]
  39. bm_action : 3, //[5:3]
  40. buffer_or_desc_type : 3, //[8:6]
  41. first_msdu_index : 4, //[12:9]
  42. tqm_release_reason : 3, //[15:13]
  43. rxdma_push_reason : 2, //[17:16]
  44. rxdma_error_code : 5, //[22:18]
  45. reo_push_reason : 2, //[24:23]
  46. reo_error_code : 5, //[29:25]
  47. wbm_internal_error : 1, //[30]
  48. reserved_2 : 1; //[31]
  49. uint32_t tqm_status_number : 24, //[23:0]
  50. transmit_count : 7, //[30:24]
  51. reserved_3a : 1; //[31]
  52. uint32_t ack_frame_rssi : 8, //[7:0]
  53. sw_release_details_valid : 1, //[8]
  54. first_msdu : 1, //[9]
  55. last_msdu : 1, //[10]
  56. msdu_part_of_amsdu : 1, //[11]
  57. fw_tx_notify_frame : 1, //[12]
  58. buffer_timestamp : 19; //[31:13]
  59. struct tx_rate_stats_info tx_rate_stats;
  60. uint32_t sw_peer_id : 16, //[15:0]
  61. tid : 4, //[19:16]
  62. ring_id : 8, //[27:20]
  63. looping_count : 4; //[31:28]
  64. };
  65. /*
  66. struct buffer_addr_info released_buff_or_desc_addr_info
  67. Consumer: WBM/SW/FW
  68. Producer: SW/TQM/RXDMA/REO/SWITCH
  69. Details of the physical address of the buffer or link
  70. descriptor that is being released. Note that within this
  71. descriptor, WBM will look at the 'owner' of the released
  72. buffer/descriptor and forward it to SW/FW is WBM is not the
  73. owner.
  74. release_source_module
  75. Indicates which module initiated the release of this
  76. buffer or descriptor
  77. <enum 0 release_source_TQM> TQM released this buffer or
  78. descriptor
  79. <enum 1 release_source_RXDMA> RXDMA released this buffer
  80. or descriptor
  81. <enum 2 release_source_REO> REO released this buffer or
  82. descriptor
  83. <enum 3 release_source_FW> FW released this buffer or
  84. descriptor
  85. <enum 4 release_source_SW> SW released this buffer or
  86. descriptor
  87. <legal 0-4>
  88. bm_action
  89. Consumer: WBM/SW/FW
  90. Producer: SW/TQM/RXDMA/REO/SWITCH
  91. Field only valid when the field return_buffer_manager in
  92. the Released_buff_or_desc_addr_info indicates:
  93. WBM_IDLE_BUF_LIST or
  94. WBM_IDLE_DESC_LIST
  95. An MSDU extension descriptor shall never be marked as
  96. <enum 0 Put_in_idle_list> Put the buffer or descriptor
  97. back in the idle list. In case of MSDU or MDPU link
  98. descriptor, BM does not need to check to release any
  99. individual MSDU buffers
  100. <enum 1 release_msdu_list > This BM action can only be
  101. used in combination with buffer_or_desc_type being
  102. msdu_link_descriptor. Field first_msdu_index points out
  103. which MSDU pointer in the MSDU link descriptor is the first
  104. of an MPDU that is released.
  105. BM shall release all the MSDU buffers linked to this
  106. first MSDU buffer pointer. All related MSDU buffer pointer
  107. entries shall be set to value 0, which represents the 'NULL
  108. pointer. When all MSDU buffer pointers in the MSDU link
  109. descriptor are 'NULL', the MSDU link descriptor itself shall
  110. also be released.
  111. <enum 2 Put_in_idle_list_expanded> CURRENTLY NOT
  112. IMPLEMENTED....
  113. Put the buffer or descriptor back in the idle list. Only
  114. valid in combination with buffer_or_desc_type indicating
  115. MDPU_link_descriptor.
  116. BM shall release the MPDU link descriptor as well as all
  117. MSDUs that are linked to the MPDUs in this descriptor.
  118. <legal 0-2>
  119. buffer_or_desc_type
  120. Consumer: WBM/SW/FW
  121. Producer: SW/TQM/RXDMA/REO/SWITCH
  122. Field only valid when WBM is marked as the
  123. return_buffer_manager in the Released_Buffer_address_info
  124. Indicates that type of buffer or descriptor is being
  125. released
  126. <enum 0 MSDU_rel_buffer> The address points to an MSDU
  127. buffer
  128. <enum 1 msdu_link_descriptor> The address points to an
  129. TX MSDU link descriptor
  130. <enum 2 mpdu_link_descriptor> The address points to an
  131. MPDU link descriptor
  132. <enum 3 msdu_ext_descriptor > The address points to an
  133. MSDU extension descriptor.
  134. In case BM finds this one in a release ring, it passes
  135. it on to FW...
  136. <enum 4 queue_ext_descriptor> The address points to an
  137. TQM queue extension descriptor. WBM should treat this is the
  138. same way as a link descriptor. That is, put the 128 byte
  139. buffer back in the link buffer idle list.
  140. <legal 0-4>
  141. first_msdu_index
  142. Consumer: WBM/SW/FW
  143. Producer: SW/TQM/RXDMA/REO/SWITCH
  144. Field only valid for the bm_action release_msdu_list.
  145. The index of the first MSDU in an MSDU link descriptor
  146. all belonging to the same MPDU.
  147. <legal 0-6>
  148. tqm_release_reason
  149. Consumer: WBM/SW/FW
  150. Producer: TQM
  151. Field only valid when Release_source_module is set to
  152. release_source_TQM
  153. (rr = Release Reason)
  154. <enum 0 tqm_rr_frame_acked> frame is removed because an
  155. ACK of BA for it was received
  156. <enum 1 tqm_rr_rem_cmd_rem> frame is removed because a
  157. remove command of type Remove_mpdus initiated by SW
  158. <enum 2 tqm_rr_rem_cmd_tx> frame is removed because a
  159. remove command of type Remove_transmitted_mpdus initiated by
  160. SW
  161. <enum 3 tqm_rr_rem_cmd_notx> frame is removed because a
  162. remove command of type Remove_untransmitted_mpdus initiated
  163. by SW
  164. <enum 4 tqm_rr_rem_cmd_aged> frame is removed because a
  165. remove command of type Remove_aged_mpdus or
  166. Remove_aged_msdus initiated by SW
  167. <enum 5 tqm_fw_reason1> frame is removed because a
  168. remove command where fw indicated that remove reason is
  169. fw_reason1
  170. <enum 6 tqm_fw_reason2> frame is removed because a
  171. remove command where fw indicated that remove reason is
  172. fw_reason1
  173. <enum 7 tqm_fw_reason3> frame is removed because a
  174. remove command where fw indicated that remove reason is
  175. fw_reason1
  176. <legal 0-7>
  177. rxdma_push_reason
  178. Field only valid when Release_source_module is set to
  179. release_source_RXDMA
  180. Indicates why rxdma pushed the frame to this ring
  181. <enum 0 rxdma_error_detected> RXDMA detected an error an
  182. pushed this frame to this queue
  183. <enum 1 rxdma_routing_instruction> RXDMA pushed the
  184. frame to this queue per received routing instructions. No
  185. error within RXDMA was detected
  186. <enum 2 rxdma_rx_flush> RXDMA received an RX_FLUSH. As a
  187. result the MSDU link descriptor might not have the
  188. last_msdu_in_mpdu_flag set, but instead WBM might just see a
  189. NULL pointer in the MSDU link descriptor. This is to be
  190. considered a normal condition for this scenario.
  191. <legal 0 - 2>
  192. rxdma_error_code
  193. Field only valid when 'rxdma_push_reason' set to
  194. 'rxdma_error_detected'.
  195. <enum 0 rxdma_overflow_err>MPDU frame is not complete
  196. due to a FIFO overflow error in RXPCU.
  197. <enum 1 rxdma_mpdu_length_err>MPDU frame is not complete
  198. due to receiving incomplete MPDU from the PHY
  199. <enum 3 rxdma_decrypt_err>CRYPTO reported a decryption
  200. error or CRYPTO received an encrypted frame, but did not get
  201. a valid corresponding key id in the peer entry.
  202. <enum 4 rxdma_tkip_mic_err>CRYPTO reported a TKIP MIC
  203. error
  204. <enum 5 rxdma_unecrypted_err>CRYPTO reported an
  205. unencrypted frame error when encrypted was expected
  206. <enum 6 rxdma_msdu_len_err>RX OLE reported an MSDU
  207. length error
  208. <enum 7 rxdma_msdu_limit_err>RX OLE reported that max
  209. number of MSDUs allowed in an MPDU got exceeded
  210. <enum 8 rxdma_wifi_parse_err>RX OLE reported a parsing
  211. error
  212. <enum 9 rxdma_amsdu_parse_err>RX OLE reported an A-MSDU
  213. parsing error
  214. <enum 10 rxdma_sa_timeout_err>RX OLE reported a timeout
  215. during SA search
  216. <enum 11 rxdma_da_timeout_err>RX OLE reported a timeout
  217. during DA search
  218. <enum 12 rxdma_flow_timeout_err>RX OLE reported a
  219. timeout during flow search
  220. <enum 13 Rxdma_flush_request>RXDMA received a flush
  221. request
  222. reo_push_reason
  223. Field only valid when Release_source_module is set to
  224. release_source_REO
  225. Indicates why REO pushed the frame to this release ring
  226. <enum 0 reo_error_detected> Reo detected an error an
  227. pushed this frame to this queue
  228. <enum 1 reo_routing_instruction> Reo pushed the frame to
  229. this queue per received routing instructions. No error
  230. within REO was detected
  231. <legal 0 - 1>
  232. reo_error_code
  233. Field only valid when 'Reo_push_reason' set to
  234. 'reo_error_detected'.
  235. <enum 0 reo_queue_desc_addr_zero> Reo queue descriptor
  236. provided in the REO_ENTRANCE ring is set to 0
  237. <enum 1 reo_queue_desc_not_valid> Reo queue descriptor
  238. valid bit is NOT set
  239. <enum 2 ampdu_in_non_ba> AMPDU frame received without BA
  240. session having been setup.
  241. <enum 3 non_ba_duplicate> Non-BA session, SN equal to
  242. SSN, Retry bit set: duplicate frame
  243. <enum 4 ba_duplicate> BA session, duplicate frame
  244. <enum 5 regular_frame_2k_jump> A normal (management/data
  245. frame) received with 2K jump in SN
  246. <enum 6 bar_frame_2k_jump> A bar received with 2K jump
  247. in SSN
  248. <enum 7 regular_frame_OOR> A normal (management/data
  249. frame) received with SN falling within the OOR window
  250. <enum 8 bar_frame_OOR> A bar received with SSN falling
  251. within the OOR window
  252. <enum 9 bar_frame_no_ba_session> A bar received without
  253. a BA session
  254. <enum 10 bar_frame_sn_equals_ssn> A bar received with
  255. SSN equal to SN
  256. <enum 11 pn_check_failed> PN Check Failed packet.
  257. <enum 12 2k_error_handling_flag_set> Frame is forwarded
  258. as a result of the 'Seq_2k_error_detected_flag' been set in
  259. the REO Queue descriptor
  260. <enum 13 pn_error_handling_flag_set> Frame is forwarded
  261. as a result of the 'pn_error_detected_flag' been set in the
  262. REO Queue descriptor
  263. <enum 14 queue_descriptor_blocked_set> Frame is
  264. forwarded as a result of the queue descriptor(address) being
  265. blocked as SW/FW seems to be currently in the process of
  266. making updates to this descriptor...
  267. <legal 0-14>
  268. wbm_internal_error
  269. Can only be set by WBM.
  270. Is set when WBM got a buffer pointer but the action was
  271. to push it to the idle link descriptor ring or do link
  272. related activity
  273. OR
  274. Is set when WBM got a link buffer pointer but the action
  275. was to push it to the buffer descriptor ring
  276. <legal all>
  277. reserved_2
  278. <legal 0>
  279. tqm_status_number
  280. Field only valid when Release_source_module is set to
  281. release_source_TQM
  282. The value in this field is equal to value of the
  283. 'TQM_CMD_Number' field the TQM command or the
  284. 'TQM_add_cmd_Number' field from the TQM entrance ring
  285. descriptor
  286. This field helps to correlate the statuses with the TQM
  287. commands.
  288. NOTE that SW could program this number to be equal to
  289. the PPDU_ID number in case direct correlation with the PPDU
  290. ID is desired
  291. <legal all>
  292. transmit_count
  293. Field only valid when Release_source_module is set to
  294. release_source_TQM
  295. The number of times this frame has been transmitted
  296. reserved_3a
  297. <legal 0>
  298. ack_frame_rssi
  299. This field is only valid when the source is TQM.
  300. If this frame is removed as the result of the reception
  301. of an ACK or BA, this field indicates the RSSI of the
  302. received ACK or BA frame.
  303. When the frame is removed as result of a direct remove
  304. command from the SW, this field is set to 0x0 (which is
  305. never a valid value when real RSSI is available)
  306. <legal all>
  307. sw_release_details_valid
  308. Consumer: SW
  309. Producer: WBM
  310. When set, some WBM specific release info for SW is
  311. valid.
  312. This is set when WMB got a 'release_msdu_list' command
  313. from TQM and the return buffer manager is not WMB. WBM will
  314. then de-aggregate all the MSDUs and pass them one at a time
  315. on to the 'buffer owner'
  316. <legal all>
  317. first_msdu
  318. Field only valid when SW_release_details_valid is set.
  319. Consumer: SW
  320. Producer: WBM
  321. When set, this MSDU is the first MSDU pointed to in the
  322. 'release_msdu_list' command.
  323. <legal all>
  324. last_msdu
  325. Field only valid when SW_release_details_valid is set.
  326. Consumer: SW
  327. Producer: WBM
  328. When set, this MSDU is the last MSDU pointed to in the
  329. 'release_msdu_list' command.
  330. <legal all>
  331. msdu_part_of_amsdu
  332. Field only valid when SW_release_details_valid is set.
  333. Consumer: SW
  334. Producer: WBM
  335. When set, this MSDU was part of an A-MSDU in MPDU
  336. <legal all>
  337. fw_tx_notify_frame
  338. Field only valid when SW_release_details_valid is set.
  339. Consumer: SW
  340. Producer: WBM
  341. This is the FW_tx_notify_frame field from the
  342. <legal all>
  343. buffer_timestamp
  344. Field only valid when SW_release_details_valid is set.
  345. Consumer: SW
  346. Producer: WBM
  347. This is the Buffer_timestamp field from the
  348. <legal all>
  349. struct tx_rate_stats_info tx_rate_stats
  350. Consumer: TQM
  351. Producer: SW/SCH(from TXPCU, PDG)
  352. Details for command execution tracking purposes.
  353. sw_peer_id
  354. Field only valid when Release_source_module is set to
  355. release_source_TQM
  356. 1) Release of msdu buffer due to drop_frame = 1. Flow is
  357. not fetched and hence sw_peer_id and tid = 0
  358. buffer_or_desc_type = e_num 0
  359. MSDU_rel_buffertqm_release_reason = e_num 1
  360. tqm_rr_rem_cmd_rem
  361. 2) Release of msdu buffer due to Flow is not fetched and
  362. hence sw_peer_id and tid = 0
  363. buffer_or_desc_type = e_num 0
  364. MSDU_rel_buffertqm_release_reason = e_num 1
  365. tqm_rr_rem_cmd_rem
  366. 3) Release of msdu link due to remove_mpdu or acked_mpdu
  367. command.
  368. buffer_or_desc_type = e_num1
  369. msdu_link_descriptortqm_release_reason can be:e_num 1
  370. tqm_rr_rem_cmd_reme_num 2 tqm_rr_rem_cmd_tx
  371. e_num 3 tqm_rr_rem_cmd_notxe_num 4 tqm_rr_rem_cmd_aged
  372. Sw_peer_id from the TX_MSDU_FLOW descriptor or
  373. TX_MPDU_QUEUE descriptor
  374. <legal all>
  375. tid
  376. Field only valid when Release_source_module is set to
  377. release_source_TQM
  378. 1) Release of msdu buffer due to drop_frame = 1. Flow is
  379. not fetched and hence sw_peer_id and tid = 0
  380. buffer_or_desc_type = e_num 0
  381. MSDU_rel_buffertqm_release_reason = e_num 1
  382. tqm_rr_rem_cmd_rem
  383. 2) Release of msdu buffer due to Flow is not fetched and
  384. hence sw_peer_id and tid = 0
  385. buffer_or_desc_type = e_num 0
  386. MSDU_rel_buffertqm_release_reason = e_num 1
  387. tqm_rr_rem_cmd_rem
  388. 3) Release of msdu link due to remove_mpdu or acked_mpdu
  389. command.
  390. buffer_or_desc_type = e_num1
  391. msdu_link_descriptortqm_release_reason can be:e_num 1
  392. tqm_rr_rem_cmd_reme_num 2 tqm_rr_rem_cmd_tx
  393. e_num 3 tqm_rr_rem_cmd_notxe_num 4 tqm_rr_rem_cmd_aged
  394. This field represents the TID from the TX_MSDU_FLOW
  395. descriptor or TX_MPDU_QUEUE descriptor
  396. <legal all>
  397. ring_id
  398. Consumer: TQM/REO/RXDMA/SW
  399. Producer: SRNG (of RXDMA)
  400. For debugging.
  401. This field is filled in by the SRNG module.
  402. It help to identify the ring that is being looked <legal
  403. all>
  404. looping_count
  405. Consumer: WBM/SW/FW
  406. Producer: SW/TQM/RXDMA/REO/SWITCH
  407. A count value that indicates the number of times the
  408. producer of entries into the Buffer Manager Ring has looped
  409. around the ring.
  410. At initialization time, this value is set to 0. On the
  411. first loop, this value is set to 1. After the max value is
  412. reached allowed by the number of bits for this field, the
  413. count value continues with 0 again.
  414. In case SW is the consumer of the ring entries, it can
  415. use this field to figure out up to where the producer of
  416. entries has created new entries. This eliminates the need to
  417. check where the head pointer' of the ring is located once
  418. the SW starts processing an interrupt indicating that new
  419. entries have been put into this ring...
  420. Also note that SW if it wants only needs to look at the
  421. LSB bit of this count value.
  422. <legal all>
  423. */
  424. #define WBM_RELEASE_RING_0_BUFFER_ADDR_INFO_RELEASED_BUFF_OR_DESC_ADDR_INFO_OFFSET 0x00000000
  425. #define WBM_RELEASE_RING_0_BUFFER_ADDR_INFO_RELEASED_BUFF_OR_DESC_ADDR_INFO_LSB 28
  426. #define WBM_RELEASE_RING_0_BUFFER_ADDR_INFO_RELEASED_BUFF_OR_DESC_ADDR_INFO_MASK 0xffffffff
  427. #define WBM_RELEASE_RING_1_BUFFER_ADDR_INFO_RELEASED_BUFF_OR_DESC_ADDR_INFO_OFFSET 0x00000004
  428. #define WBM_RELEASE_RING_1_BUFFER_ADDR_INFO_RELEASED_BUFF_OR_DESC_ADDR_INFO_LSB 28
  429. #define WBM_RELEASE_RING_1_BUFFER_ADDR_INFO_RELEASED_BUFF_OR_DESC_ADDR_INFO_MASK 0xffffffff
  430. /* Description WBM_RELEASE_RING_2_RELEASE_SOURCE_MODULE
  431. Indicates which module initiated the release of this
  432. buffer or descriptor
  433. <enum 0 release_source_TQM> TQM released this buffer or
  434. descriptor
  435. <enum 1 release_source_RXDMA> RXDMA released this buffer
  436. or descriptor
  437. <enum 2 release_source_REO> REO released this buffer or
  438. descriptor
  439. <enum 3 release_source_FW> FW released this buffer or
  440. descriptor
  441. <enum 4 release_source_SW> SW released this buffer or
  442. descriptor
  443. <legal 0-4>
  444. */
  445. #define WBM_RELEASE_RING_2_RELEASE_SOURCE_MODULE_OFFSET 0x00000008
  446. #define WBM_RELEASE_RING_2_RELEASE_SOURCE_MODULE_LSB 0
  447. #define WBM_RELEASE_RING_2_RELEASE_SOURCE_MODULE_MASK 0x00000007
  448. /* Description WBM_RELEASE_RING_2_BM_ACTION
  449. Consumer: WBM/SW/FW
  450. Producer: SW/TQM/RXDMA/REO/SWITCH
  451. Field only valid when the field return_buffer_manager in
  452. the Released_buff_or_desc_addr_info indicates:
  453. WBM_IDLE_BUF_LIST or
  454. WBM_IDLE_DESC_LIST
  455. An MSDU extension descriptor shall never be marked as
  456. <enum 0 Put_in_idle_list> Put the buffer or descriptor
  457. back in the idle list. In case of MSDU or MDPU link
  458. descriptor, BM does not need to check to release any
  459. individual MSDU buffers
  460. <enum 1 release_msdu_list > This BM action can only be
  461. used in combination with buffer_or_desc_type being
  462. msdu_link_descriptor. Field first_msdu_index points out
  463. which MSDU pointer in the MSDU link descriptor is the first
  464. of an MPDU that is released.
  465. BM shall release all the MSDU buffers linked to this
  466. first MSDU buffer pointer. All related MSDU buffer pointer
  467. entries shall be set to value 0, which represents the 'NULL
  468. pointer. When all MSDU buffer pointers in the MSDU link
  469. descriptor are 'NULL', the MSDU link descriptor itself shall
  470. also be released.
  471. <enum 2 Put_in_idle_list_expanded> CURRENTLY NOT
  472. IMPLEMENTED....
  473. Put the buffer or descriptor back in the idle list. Only
  474. valid in combination with buffer_or_desc_type indicating
  475. MDPU_link_descriptor.
  476. BM shall release the MPDU link descriptor as well as all
  477. MSDUs that are linked to the MPDUs in this descriptor.
  478. <legal 0-2>
  479. */
  480. #define WBM_RELEASE_RING_2_BM_ACTION_OFFSET 0x00000008
  481. #define WBM_RELEASE_RING_2_BM_ACTION_LSB 3
  482. #define WBM_RELEASE_RING_2_BM_ACTION_MASK 0x00000038
  483. /* Description WBM_RELEASE_RING_2_BUFFER_OR_DESC_TYPE
  484. Consumer: WBM/SW/FW
  485. Producer: SW/TQM/RXDMA/REO/SWITCH
  486. Field only valid when WBM is marked as the
  487. return_buffer_manager in the Released_Buffer_address_info
  488. Indicates that type of buffer or descriptor is being
  489. released
  490. <enum 0 MSDU_rel_buffer> The address points to an MSDU
  491. buffer
  492. <enum 1 msdu_link_descriptor> The address points to an
  493. TX MSDU link descriptor
  494. <enum 2 mpdu_link_descriptor> The address points to an
  495. MPDU link descriptor
  496. <enum 3 msdu_ext_descriptor > The address points to an
  497. MSDU extension descriptor.
  498. In case BM finds this one in a release ring, it passes
  499. it on to FW...
  500. <enum 4 queue_ext_descriptor> The address points to an
  501. TQM queue extension descriptor. WBM should treat this is the
  502. same way as a link descriptor. That is, put the 128 byte
  503. buffer back in the link buffer idle list.
  504. <legal 0-4>
  505. */
  506. #define WBM_RELEASE_RING_2_BUFFER_OR_DESC_TYPE_OFFSET 0x00000008
  507. #define WBM_RELEASE_RING_2_BUFFER_OR_DESC_TYPE_LSB 6
  508. #define WBM_RELEASE_RING_2_BUFFER_OR_DESC_TYPE_MASK 0x000001c0
  509. /* Description WBM_RELEASE_RING_2_FIRST_MSDU_INDEX
  510. Consumer: WBM/SW/FW
  511. Producer: SW/TQM/RXDMA/REO/SWITCH
  512. Field only valid for the bm_action release_msdu_list.
  513. The index of the first MSDU in an MSDU link descriptor
  514. all belonging to the same MPDU.
  515. <legal 0-6>
  516. */
  517. #define WBM_RELEASE_RING_2_FIRST_MSDU_INDEX_OFFSET 0x00000008
  518. #define WBM_RELEASE_RING_2_FIRST_MSDU_INDEX_LSB 9
  519. #define WBM_RELEASE_RING_2_FIRST_MSDU_INDEX_MASK 0x00001e00
  520. /* Description WBM_RELEASE_RING_2_TQM_RELEASE_REASON
  521. Consumer: WBM/SW/FW
  522. Producer: TQM
  523. Field only valid when Release_source_module is set to
  524. release_source_TQM
  525. (rr = Release Reason)
  526. <enum 0 tqm_rr_frame_acked> frame is removed because an
  527. ACK of BA for it was received
  528. <enum 1 tqm_rr_rem_cmd_rem> frame is removed because a
  529. remove command of type Remove_mpdus initiated by SW
  530. <enum 2 tqm_rr_rem_cmd_tx> frame is removed because a
  531. remove command of type Remove_transmitted_mpdus initiated by
  532. SW
  533. <enum 3 tqm_rr_rem_cmd_notx> frame is removed because a
  534. remove command of type Remove_untransmitted_mpdus initiated
  535. by SW
  536. <enum 4 tqm_rr_rem_cmd_aged> frame is removed because a
  537. remove command of type Remove_aged_mpdus or
  538. Remove_aged_msdus initiated by SW
  539. <enum 5 tqm_fw_reason1> frame is removed because a
  540. remove command where fw indicated that remove reason is
  541. fw_reason1
  542. <enum 6 tqm_fw_reason2> frame is removed because a
  543. remove command where fw indicated that remove reason is
  544. fw_reason1
  545. <enum 7 tqm_fw_reason3> frame is removed because a
  546. remove command where fw indicated that remove reason is
  547. fw_reason1
  548. <legal 0-7>
  549. */
  550. #define WBM_RELEASE_RING_2_TQM_RELEASE_REASON_OFFSET 0x00000008
  551. #define WBM_RELEASE_RING_2_TQM_RELEASE_REASON_LSB 13
  552. #define WBM_RELEASE_RING_2_TQM_RELEASE_REASON_MASK 0x0000e000
  553. /* Description WBM_RELEASE_RING_2_RXDMA_PUSH_REASON
  554. Field only valid when Release_source_module is set to
  555. release_source_RXDMA
  556. Indicates why rxdma pushed the frame to this ring
  557. <enum 0 rxdma_error_detected> RXDMA detected an error an
  558. pushed this frame to this queue
  559. <enum 1 rxdma_routing_instruction> RXDMA pushed the
  560. frame to this queue per received routing instructions. No
  561. error within RXDMA was detected
  562. <enum 2 rxdma_rx_flush> RXDMA received an RX_FLUSH. As a
  563. result the MSDU link descriptor might not have the
  564. last_msdu_in_mpdu_flag set, but instead WBM might just see a
  565. NULL pointer in the MSDU link descriptor. This is to be
  566. considered a normal condition for this scenario.
  567. <legal 0 - 2>
  568. */
  569. #define WBM_RELEASE_RING_2_RXDMA_PUSH_REASON_OFFSET 0x00000008
  570. #define WBM_RELEASE_RING_2_RXDMA_PUSH_REASON_LSB 16
  571. #define WBM_RELEASE_RING_2_RXDMA_PUSH_REASON_MASK 0x00030000
  572. /* Description WBM_RELEASE_RING_2_RXDMA_ERROR_CODE
  573. Field only valid when 'rxdma_push_reason' set to
  574. 'rxdma_error_detected'.
  575. <enum 0 rxdma_overflow_err>MPDU frame is not complete
  576. due to a FIFO overflow error in RXPCU.
  577. <enum 1 rxdma_mpdu_length_err>MPDU frame is not complete
  578. due to receiving incomplete MPDU from the PHY
  579. <enum 3 rxdma_decrypt_err>CRYPTO reported a decryption
  580. error or CRYPTO received an encrypted frame, but did not get
  581. a valid corresponding key id in the peer entry.
  582. <enum 4 rxdma_tkip_mic_err>CRYPTO reported a TKIP MIC
  583. error
  584. <enum 5 rxdma_unecrypted_err>CRYPTO reported an
  585. unencrypted frame error when encrypted was expected
  586. <enum 6 rxdma_msdu_len_err>RX OLE reported an MSDU
  587. length error
  588. <enum 7 rxdma_msdu_limit_err>RX OLE reported that max
  589. number of MSDUs allowed in an MPDU got exceeded
  590. <enum 8 rxdma_wifi_parse_err>RX OLE reported a parsing
  591. error
  592. <enum 9 rxdma_amsdu_parse_err>RX OLE reported an A-MSDU
  593. parsing error
  594. <enum 10 rxdma_sa_timeout_err>RX OLE reported a timeout
  595. during SA search
  596. <enum 11 rxdma_da_timeout_err>RX OLE reported a timeout
  597. during DA search
  598. <enum 12 rxdma_flow_timeout_err>RX OLE reported a
  599. timeout during flow search
  600. <enum 13 Rxdma_flush_request>RXDMA received a flush
  601. request
  602. */
  603. #define WBM_RELEASE_RING_2_RXDMA_ERROR_CODE_OFFSET 0x00000008
  604. #define WBM_RELEASE_RING_2_RXDMA_ERROR_CODE_LSB 18
  605. #define WBM_RELEASE_RING_2_RXDMA_ERROR_CODE_MASK 0x007c0000
  606. /* Description WBM_RELEASE_RING_2_REO_PUSH_REASON
  607. Field only valid when Release_source_module is set to
  608. release_source_REO
  609. Indicates why REO pushed the frame to this release ring
  610. <enum 0 reo_error_detected> Reo detected an error an
  611. pushed this frame to this queue
  612. <enum 1 reo_routing_instruction> Reo pushed the frame to
  613. this queue per received routing instructions. No error
  614. within REO was detected
  615. <legal 0 - 1>
  616. */
  617. #define WBM_RELEASE_RING_2_REO_PUSH_REASON_OFFSET 0x00000008
  618. #define WBM_RELEASE_RING_2_REO_PUSH_REASON_LSB 23
  619. #define WBM_RELEASE_RING_2_REO_PUSH_REASON_MASK 0x01800000
  620. /* Description WBM_RELEASE_RING_2_REO_ERROR_CODE
  621. Field only valid when 'Reo_push_reason' set to
  622. 'reo_error_detected'.
  623. <enum 0 reo_queue_desc_addr_zero> Reo queue descriptor
  624. provided in the REO_ENTRANCE ring is set to 0
  625. <enum 1 reo_queue_desc_not_valid> Reo queue descriptor
  626. valid bit is NOT set
  627. <enum 2 ampdu_in_non_ba> AMPDU frame received without BA
  628. session having been setup.
  629. <enum 3 non_ba_duplicate> Non-BA session, SN equal to
  630. SSN, Retry bit set: duplicate frame
  631. <enum 4 ba_duplicate> BA session, duplicate frame
  632. <enum 5 regular_frame_2k_jump> A normal (management/data
  633. frame) received with 2K jump in SN
  634. <enum 6 bar_frame_2k_jump> A bar received with 2K jump
  635. in SSN
  636. <enum 7 regular_frame_OOR> A normal (management/data
  637. frame) received with SN falling within the OOR window
  638. <enum 8 bar_frame_OOR> A bar received with SSN falling
  639. within the OOR window
  640. <enum 9 bar_frame_no_ba_session> A bar received without
  641. a BA session
  642. <enum 10 bar_frame_sn_equals_ssn> A bar received with
  643. SSN equal to SN
  644. <enum 11 pn_check_failed> PN Check Failed packet.
  645. <enum 12 2k_error_handling_flag_set> Frame is forwarded
  646. as a result of the 'Seq_2k_error_detected_flag' been set in
  647. the REO Queue descriptor
  648. <enum 13 pn_error_handling_flag_set> Frame is forwarded
  649. as a result of the 'pn_error_detected_flag' been set in the
  650. REO Queue descriptor
  651. <enum 14 queue_descriptor_blocked_set> Frame is
  652. forwarded as a result of the queue descriptor(address) being
  653. blocked as SW/FW seems to be currently in the process of
  654. making updates to this descriptor...
  655. <legal 0-14>
  656. */
  657. #define WBM_RELEASE_RING_2_REO_ERROR_CODE_OFFSET 0x00000008
  658. #define WBM_RELEASE_RING_2_REO_ERROR_CODE_LSB 25
  659. #define WBM_RELEASE_RING_2_REO_ERROR_CODE_MASK 0x3e000000
  660. /* Description WBM_RELEASE_RING_2_WBM_INTERNAL_ERROR
  661. Can only be set by WBM.
  662. Is set when WBM got a buffer pointer but the action was
  663. to push it to the idle link descriptor ring or do link
  664. related activity
  665. OR
  666. Is set when WBM got a link buffer pointer but the action
  667. was to push it to the buffer descriptor ring
  668. <legal all>
  669. */
  670. #define WBM_RELEASE_RING_2_WBM_INTERNAL_ERROR_OFFSET 0x00000008
  671. #define WBM_RELEASE_RING_2_WBM_INTERNAL_ERROR_LSB 30
  672. #define WBM_RELEASE_RING_2_WBM_INTERNAL_ERROR_MASK 0x40000000
  673. /* Description WBM_RELEASE_RING_2_RESERVED_2
  674. <legal 0>
  675. */
  676. #define WBM_RELEASE_RING_2_RESERVED_2_OFFSET 0x00000008
  677. #define WBM_RELEASE_RING_2_RESERVED_2_LSB 31
  678. #define WBM_RELEASE_RING_2_RESERVED_2_MASK 0x80000000
  679. /* Description WBM_RELEASE_RING_3_TQM_STATUS_NUMBER
  680. Field only valid when Release_source_module is set to
  681. release_source_TQM
  682. The value in this field is equal to value of the
  683. 'TQM_CMD_Number' field the TQM command or the
  684. 'TQM_add_cmd_Number' field from the TQM entrance ring
  685. descriptor
  686. This field helps to correlate the statuses with the TQM
  687. commands.
  688. NOTE that SW could program this number to be equal to
  689. the PPDU_ID number in case direct correlation with the PPDU
  690. ID is desired
  691. <legal all>
  692. */
  693. #define WBM_RELEASE_RING_3_TQM_STATUS_NUMBER_OFFSET 0x0000000c
  694. #define WBM_RELEASE_RING_3_TQM_STATUS_NUMBER_LSB 0
  695. #define WBM_RELEASE_RING_3_TQM_STATUS_NUMBER_MASK 0x00ffffff
  696. /* Description WBM_RELEASE_RING_3_TRANSMIT_COUNT
  697. Field only valid when Release_source_module is set to
  698. release_source_TQM
  699. The number of times this frame has been transmitted
  700. */
  701. #define WBM_RELEASE_RING_3_TRANSMIT_COUNT_OFFSET 0x0000000c
  702. #define WBM_RELEASE_RING_3_TRANSMIT_COUNT_LSB 24
  703. #define WBM_RELEASE_RING_3_TRANSMIT_COUNT_MASK 0x7f000000
  704. /* Description WBM_RELEASE_RING_3_RESERVED_3A
  705. <legal 0>
  706. */
  707. #define WBM_RELEASE_RING_3_RESERVED_3A_OFFSET 0x0000000c
  708. #define WBM_RELEASE_RING_3_RESERVED_3A_LSB 31
  709. #define WBM_RELEASE_RING_3_RESERVED_3A_MASK 0x80000000
  710. /* Description WBM_RELEASE_RING_4_ACK_FRAME_RSSI
  711. This field is only valid when the source is TQM.
  712. If this frame is removed as the result of the reception
  713. of an ACK or BA, this field indicates the RSSI of the
  714. received ACK or BA frame.
  715. When the frame is removed as result of a direct remove
  716. command from the SW, this field is set to 0x0 (which is
  717. never a valid value when real RSSI is available)
  718. <legal all>
  719. */
  720. #define WBM_RELEASE_RING_4_ACK_FRAME_RSSI_OFFSET 0x00000010
  721. #define WBM_RELEASE_RING_4_ACK_FRAME_RSSI_LSB 0
  722. #define WBM_RELEASE_RING_4_ACK_FRAME_RSSI_MASK 0x000000ff
  723. /* Description WBM_RELEASE_RING_4_SW_RELEASE_DETAILS_VALID
  724. Consumer: SW
  725. Producer: WBM
  726. When set, some WBM specific release info for SW is
  727. valid.
  728. This is set when WMB got a 'release_msdu_list' command
  729. from TQM and the return buffer manager is not WMB. WBM will
  730. then de-aggregate all the MSDUs and pass them one at a time
  731. on to the 'buffer owner'
  732. <legal all>
  733. */
  734. #define WBM_RELEASE_RING_4_SW_RELEASE_DETAILS_VALID_OFFSET 0x00000010
  735. #define WBM_RELEASE_RING_4_SW_RELEASE_DETAILS_VALID_LSB 8
  736. #define WBM_RELEASE_RING_4_SW_RELEASE_DETAILS_VALID_MASK 0x00000100
  737. /* Description WBM_RELEASE_RING_4_FIRST_MSDU
  738. Field only valid when SW_release_details_valid is set.
  739. Consumer: SW
  740. Producer: WBM
  741. When set, this MSDU is the first MSDU pointed to in the
  742. 'release_msdu_list' command.
  743. <legal all>
  744. */
  745. #define WBM_RELEASE_RING_4_FIRST_MSDU_OFFSET 0x00000010
  746. #define WBM_RELEASE_RING_4_FIRST_MSDU_LSB 9
  747. #define WBM_RELEASE_RING_4_FIRST_MSDU_MASK 0x00000200
  748. /* Description WBM_RELEASE_RING_4_LAST_MSDU
  749. Field only valid when SW_release_details_valid is set.
  750. Consumer: SW
  751. Producer: WBM
  752. When set, this MSDU is the last MSDU pointed to in the
  753. 'release_msdu_list' command.
  754. <legal all>
  755. */
  756. #define WBM_RELEASE_RING_4_LAST_MSDU_OFFSET 0x00000010
  757. #define WBM_RELEASE_RING_4_LAST_MSDU_LSB 10
  758. #define WBM_RELEASE_RING_4_LAST_MSDU_MASK 0x00000400
  759. /* Description WBM_RELEASE_RING_4_MSDU_PART_OF_AMSDU
  760. Field only valid when SW_release_details_valid is set.
  761. Consumer: SW
  762. Producer: WBM
  763. When set, this MSDU was part of an A-MSDU in MPDU
  764. <legal all>
  765. */
  766. #define WBM_RELEASE_RING_4_MSDU_PART_OF_AMSDU_OFFSET 0x00000010
  767. #define WBM_RELEASE_RING_4_MSDU_PART_OF_AMSDU_LSB 11
  768. #define WBM_RELEASE_RING_4_MSDU_PART_OF_AMSDU_MASK 0x00000800
  769. /* Description WBM_RELEASE_RING_4_FW_TX_NOTIFY_FRAME
  770. Field only valid when SW_release_details_valid is set.
  771. Consumer: SW
  772. Producer: WBM
  773. This is the FW_tx_notify_frame field from the
  774. <legal all>
  775. */
  776. #define WBM_RELEASE_RING_4_FW_TX_NOTIFY_FRAME_OFFSET 0x00000010
  777. #define WBM_RELEASE_RING_4_FW_TX_NOTIFY_FRAME_LSB 12
  778. #define WBM_RELEASE_RING_4_FW_TX_NOTIFY_FRAME_MASK 0x00001000
  779. /* Description WBM_RELEASE_RING_4_BUFFER_TIMESTAMP
  780. Field only valid when SW_release_details_valid is set.
  781. Consumer: SW
  782. Producer: WBM
  783. This is the Buffer_timestamp field from the
  784. <legal all>
  785. */
  786. #define WBM_RELEASE_RING_4_BUFFER_TIMESTAMP_OFFSET 0x00000010
  787. #define WBM_RELEASE_RING_4_BUFFER_TIMESTAMP_LSB 13
  788. #define WBM_RELEASE_RING_4_BUFFER_TIMESTAMP_MASK 0xffffe000
  789. #define WBM_RELEASE_RING_5_TX_RATE_STATS_INFO_TX_RATE_STATS_OFFSET 0x00000014
  790. #define WBM_RELEASE_RING_5_TX_RATE_STATS_INFO_TX_RATE_STATS_LSB 13
  791. #define WBM_RELEASE_RING_5_TX_RATE_STATS_INFO_TX_RATE_STATS_MASK 0xffffffff
  792. #define WBM_RELEASE_RING_6_TX_RATE_STATS_INFO_TX_RATE_STATS_OFFSET 0x00000018
  793. #define WBM_RELEASE_RING_6_TX_RATE_STATS_INFO_TX_RATE_STATS_LSB 13
  794. #define WBM_RELEASE_RING_6_TX_RATE_STATS_INFO_TX_RATE_STATS_MASK 0xffffffff
  795. /* Description WBM_RELEASE_RING_7_SW_PEER_ID
  796. Field only valid when Release_source_module is set to
  797. release_source_TQM
  798. 1) Release of msdu buffer due to drop_frame = 1. Flow is
  799. not fetched and hence sw_peer_id and tid = 0
  800. buffer_or_desc_type = e_num 0
  801. MSDU_rel_buffertqm_release_reason = e_num 1
  802. tqm_rr_rem_cmd_rem
  803. 2) Release of msdu buffer due to Flow is not fetched and
  804. hence sw_peer_id and tid = 0
  805. buffer_or_desc_type = e_num 0
  806. MSDU_rel_buffertqm_release_reason = e_num 1
  807. tqm_rr_rem_cmd_rem
  808. 3) Release of msdu link due to remove_mpdu or acked_mpdu
  809. command.
  810. buffer_or_desc_type = e_num1
  811. msdu_link_descriptortqm_release_reason can be:e_num 1
  812. tqm_rr_rem_cmd_reme_num 2 tqm_rr_rem_cmd_tx
  813. e_num 3 tqm_rr_rem_cmd_notxe_num 4 tqm_rr_rem_cmd_aged
  814. Sw_peer_id from the TX_MSDU_FLOW descriptor or
  815. TX_MPDU_QUEUE descriptor
  816. <legal all>
  817. */
  818. #define WBM_RELEASE_RING_7_SW_PEER_ID_OFFSET 0x0000001c
  819. #define WBM_RELEASE_RING_7_SW_PEER_ID_LSB 0
  820. #define WBM_RELEASE_RING_7_SW_PEER_ID_MASK 0x0000ffff
  821. /* Description WBM_RELEASE_RING_7_TID
  822. Field only valid when Release_source_module is set to
  823. release_source_TQM
  824. 1) Release of msdu buffer due to drop_frame = 1. Flow is
  825. not fetched and hence sw_peer_id and tid = 0
  826. buffer_or_desc_type = e_num 0
  827. MSDU_rel_buffertqm_release_reason = e_num 1
  828. tqm_rr_rem_cmd_rem
  829. 2) Release of msdu buffer due to Flow is not fetched and
  830. hence sw_peer_id and tid = 0
  831. buffer_or_desc_type = e_num 0
  832. MSDU_rel_buffertqm_release_reason = e_num 1
  833. tqm_rr_rem_cmd_rem
  834. 3) Release of msdu link due to remove_mpdu or acked_mpdu
  835. command.
  836. buffer_or_desc_type = e_num1
  837. msdu_link_descriptortqm_release_reason can be:e_num 1
  838. tqm_rr_rem_cmd_reme_num 2 tqm_rr_rem_cmd_tx
  839. e_num 3 tqm_rr_rem_cmd_notxe_num 4 tqm_rr_rem_cmd_aged
  840. This field represents the TID from the TX_MSDU_FLOW
  841. descriptor or TX_MPDU_QUEUE descriptor
  842. <legal all>
  843. */
  844. #define WBM_RELEASE_RING_7_TID_OFFSET 0x0000001c
  845. #define WBM_RELEASE_RING_7_TID_LSB 16
  846. #define WBM_RELEASE_RING_7_TID_MASK 0x000f0000
  847. /* Description WBM_RELEASE_RING_7_RING_ID
  848. Consumer: TQM/REO/RXDMA/SW
  849. Producer: SRNG (of RXDMA)
  850. For debugging.
  851. This field is filled in by the SRNG module.
  852. It help to identify the ring that is being looked <legal
  853. all>
  854. */
  855. #define WBM_RELEASE_RING_7_RING_ID_OFFSET 0x0000001c
  856. #define WBM_RELEASE_RING_7_RING_ID_LSB 20
  857. #define WBM_RELEASE_RING_7_RING_ID_MASK 0x0ff00000
  858. /* Description WBM_RELEASE_RING_7_LOOPING_COUNT
  859. Consumer: WBM/SW/FW
  860. Producer: SW/TQM/RXDMA/REO/SWITCH
  861. A count value that indicates the number of times the
  862. producer of entries into the Buffer Manager Ring has looped
  863. around the ring.
  864. At initialization time, this value is set to 0. On the
  865. first loop, this value is set to 1. After the max value is
  866. reached allowed by the number of bits for this field, the
  867. count value continues with 0 again.
  868. In case SW is the consumer of the ring entries, it can
  869. use this field to figure out up to where the producer of
  870. entries has created new entries. This eliminates the need to
  871. check where the head pointer' of the ring is located once
  872. the SW starts processing an interrupt indicating that new
  873. entries have been put into this ring...
  874. Also note that SW if it wants only needs to look at the
  875. LSB bit of this count value.
  876. <legal all>
  877. */
  878. #define WBM_RELEASE_RING_7_LOOPING_COUNT_OFFSET 0x0000001c
  879. #define WBM_RELEASE_RING_7_LOOPING_COUNT_LSB 28
  880. #define WBM_RELEASE_RING_7_LOOPING_COUNT_MASK 0xf0000000
  881. #endif // _WBM_RELEASE_RING_H_