rx_mpdu_desc_info.h 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475
  1. /*
  2. * Copyright (c) 2019 The Linux Foundation. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for
  5. * any purpose with or without fee is hereby granted, provided that the
  6. * above copyright notice and this permission notice appear in all
  7. * copies.
  8. *
  9. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
  10. * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
  11. * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
  12. * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
  13. * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
  14. * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  15. * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  16. * PERFORMANCE OF THIS SOFTWARE.
  17. */
  18. //
  19. // DO NOT EDIT! This file is automatically generated
  20. // These definitions are tied to a particular hardware layout
  21. #ifndef _RX_MPDU_DESC_INFO_H_
  22. #define _RX_MPDU_DESC_INFO_H_
  23. #if !defined(__ASSEMBLER__)
  24. #endif
  25. // ################ START SUMMARY #################
  26. //
  27. // Dword Fields
  28. // 0 msdu_count[7:0], mpdu_sequence_number[19:8], fragment_flag[20], mpdu_retry_bit[21], ampdu_flag[22], bar_frame[23], pn_fields_contain_valid_info[24], sa_is_valid[25], sa_idx_timeout[26], da_is_valid[27], da_is_mcbc[28], da_idx_timeout[29], raw_mpdu[30], more_fragment_flag[31]
  29. // 1 peer_meta_data[31:0]
  30. //
  31. // ################ END SUMMARY #################
  32. #define NUM_OF_DWORDS_RX_MPDU_DESC_INFO 2
  33. struct rx_mpdu_desc_info {
  34. uint32_t msdu_count : 8, //[7:0]
  35. mpdu_sequence_number : 12, //[19:8]
  36. fragment_flag : 1, //[20]
  37. mpdu_retry_bit : 1, //[21]
  38. ampdu_flag : 1, //[22]
  39. bar_frame : 1, //[23]
  40. pn_fields_contain_valid_info : 1, //[24]
  41. sa_is_valid : 1, //[25]
  42. sa_idx_timeout : 1, //[26]
  43. da_is_valid : 1, //[27]
  44. da_is_mcbc : 1, //[28]
  45. da_idx_timeout : 1, //[29]
  46. raw_mpdu : 1, //[30]
  47. more_fragment_flag : 1; //[31]
  48. uint32_t peer_meta_data : 32; //[31:0]
  49. };
  50. /*
  51. msdu_count
  52. Consumer: REO/SW/FW
  53. Producer: RXDMA
  54. The number of MSDUs within the MPDU
  55. <legal all>
  56. mpdu_sequence_number
  57. Consumer: REO/SW/FW
  58. Producer: RXDMA
  59. The field can have two different meanings based on the
  60. setting of field 'BAR_frame':
  61. 'BAR_frame' is NOT set:
  62. The MPDU sequence number of the received frame.
  63. 'BAR_frame' is set.
  64. The MPDU Start sequence number from the BAR frame
  65. <legal all>
  66. fragment_flag
  67. Consumer: REO/SW/FW
  68. Producer: RXDMA
  69. When set, this MPDU is a fragment and REO should forward
  70. this fragment MPDU to the REO destination ring without any
  71. reorder checks, pn checks or bitmap update. This implies
  72. that REO is forwarding the pointer to the MSDU link
  73. descriptor. The destination ring is coming from a
  74. programmable register setting in REO
  75. <legal all>
  76. mpdu_retry_bit
  77. Consumer: REO/SW/FW
  78. Producer: RXDMA
  79. The retry bit setting from the MPDU header of the
  80. received frame
  81. <legal all>
  82. ampdu_flag
  83. Consumer: REO/SW/FW
  84. Producer: RXDMA
  85. When set, the MPDU was received as part of an A-MPDU.
  86. <legal all>
  87. bar_frame
  88. Consumer: REO/SW/FW
  89. Producer: RXDMA
  90. When set, the received frame is a BAR frame. After
  91. processing, this frame shall be pushed to SW or deleted.
  92. <legal all>
  93. pn_fields_contain_valid_info
  94. Consumer: REO/SW/FW
  95. Producer: RXDMA
  96. Copied here by RXDMA from RX_MPDU_END
  97. When not set, REO will Not perform a PN sequence number
  98. check
  99. sa_is_valid
  100. When set, OLE found a valid SA entry for all MSDUs in
  101. this MPDU
  102. <legal all>
  103. sa_idx_timeout
  104. When set, at least 1 MSDU within the MPDU has an
  105. unsuccessful MAC source address search due to the expiration
  106. of the search timer.
  107. <legal all>
  108. da_is_valid
  109. When set, OLE found a valid DA entry for all MSDUs in
  110. this MPDU
  111. <legal all>
  112. da_is_mcbc
  113. Field Only valid if da_is_valid is set
  114. When set, at least one of the DA addresses is a
  115. Multicast or Broadcast address.
  116. <legal all>
  117. da_idx_timeout
  118. When set, at least 1 MSDU within the MPDU has an
  119. unsuccessful MAC destination address search due to the
  120. expiration of the search timer.
  121. <legal all>
  122. raw_mpdu
  123. Field only valid when first_msdu_in_mpdu_flag is set.
  124. When set, the contents in the MSDU buffer contains a
  125. 'RAW' MPDU. This 'RAW' MPDU might be spread out over
  126. multiple MSDU buffers.
  127. <legal all>
  128. more_fragment_flag
  129. The More Fragment bit setting from the MPDU header of
  130. the received frame
  131. <legal all>
  132. peer_meta_data
  133. Meta data that SW has programmed in the Peer table entry
  134. of the transmitting STA.
  135. <legal all>
  136. */
  137. /* Description RX_MPDU_DESC_INFO_0_MSDU_COUNT
  138. Consumer: REO/SW/FW
  139. Producer: RXDMA
  140. The number of MSDUs within the MPDU
  141. <legal all>
  142. */
  143. #define RX_MPDU_DESC_INFO_0_MSDU_COUNT_OFFSET 0x00000000
  144. #define RX_MPDU_DESC_INFO_0_MSDU_COUNT_LSB 0
  145. #define RX_MPDU_DESC_INFO_0_MSDU_COUNT_MASK 0x000000ff
  146. /* Description RX_MPDU_DESC_INFO_0_MPDU_SEQUENCE_NUMBER
  147. Consumer: REO/SW/FW
  148. Producer: RXDMA
  149. The field can have two different meanings based on the
  150. setting of field 'BAR_frame':
  151. 'BAR_frame' is NOT set:
  152. The MPDU sequence number of the received frame.
  153. 'BAR_frame' is set.
  154. The MPDU Start sequence number from the BAR frame
  155. <legal all>
  156. */
  157. #define RX_MPDU_DESC_INFO_0_MPDU_SEQUENCE_NUMBER_OFFSET 0x00000000
  158. #define RX_MPDU_DESC_INFO_0_MPDU_SEQUENCE_NUMBER_LSB 8
  159. #define RX_MPDU_DESC_INFO_0_MPDU_SEQUENCE_NUMBER_MASK 0x000fff00
  160. /* Description RX_MPDU_DESC_INFO_0_FRAGMENT_FLAG
  161. Consumer: REO/SW/FW
  162. Producer: RXDMA
  163. When set, this MPDU is a fragment and REO should forward
  164. this fragment MPDU to the REO destination ring without any
  165. reorder checks, pn checks or bitmap update. This implies
  166. that REO is forwarding the pointer to the MSDU link
  167. descriptor. The destination ring is coming from a
  168. programmable register setting in REO
  169. <legal all>
  170. */
  171. #define RX_MPDU_DESC_INFO_0_FRAGMENT_FLAG_OFFSET 0x00000000
  172. #define RX_MPDU_DESC_INFO_0_FRAGMENT_FLAG_LSB 20
  173. #define RX_MPDU_DESC_INFO_0_FRAGMENT_FLAG_MASK 0x00100000
  174. /* Description RX_MPDU_DESC_INFO_0_MPDU_RETRY_BIT
  175. Consumer: REO/SW/FW
  176. Producer: RXDMA
  177. The retry bit setting from the MPDU header of the
  178. received frame
  179. <legal all>
  180. */
  181. #define RX_MPDU_DESC_INFO_0_MPDU_RETRY_BIT_OFFSET 0x00000000
  182. #define RX_MPDU_DESC_INFO_0_MPDU_RETRY_BIT_LSB 21
  183. #define RX_MPDU_DESC_INFO_0_MPDU_RETRY_BIT_MASK 0x00200000
  184. /* Description RX_MPDU_DESC_INFO_0_AMPDU_FLAG
  185. Consumer: REO/SW/FW
  186. Producer: RXDMA
  187. When set, the MPDU was received as part of an A-MPDU.
  188. <legal all>
  189. */
  190. #define RX_MPDU_DESC_INFO_0_AMPDU_FLAG_OFFSET 0x00000000
  191. #define RX_MPDU_DESC_INFO_0_AMPDU_FLAG_LSB 22
  192. #define RX_MPDU_DESC_INFO_0_AMPDU_FLAG_MASK 0x00400000
  193. /* Description RX_MPDU_DESC_INFO_0_BAR_FRAME
  194. Consumer: REO/SW/FW
  195. Producer: RXDMA
  196. When set, the received frame is a BAR frame. After
  197. processing, this frame shall be pushed to SW or deleted.
  198. <legal all>
  199. */
  200. #define RX_MPDU_DESC_INFO_0_BAR_FRAME_OFFSET 0x00000000
  201. #define RX_MPDU_DESC_INFO_0_BAR_FRAME_LSB 23
  202. #define RX_MPDU_DESC_INFO_0_BAR_FRAME_MASK 0x00800000
  203. /* Description RX_MPDU_DESC_INFO_0_PN_FIELDS_CONTAIN_VALID_INFO
  204. Consumer: REO/SW/FW
  205. Producer: RXDMA
  206. Copied here by RXDMA from RX_MPDU_END
  207. When not set, REO will Not perform a PN sequence number
  208. check
  209. */
  210. #define RX_MPDU_DESC_INFO_0_PN_FIELDS_CONTAIN_VALID_INFO_OFFSET 0x00000000
  211. #define RX_MPDU_DESC_INFO_0_PN_FIELDS_CONTAIN_VALID_INFO_LSB 24
  212. #define RX_MPDU_DESC_INFO_0_PN_FIELDS_CONTAIN_VALID_INFO_MASK 0x01000000
  213. /* Description RX_MPDU_DESC_INFO_0_SA_IS_VALID
  214. When set, OLE found a valid SA entry for all MSDUs in
  215. this MPDU
  216. <legal all>
  217. */
  218. #define RX_MPDU_DESC_INFO_0_SA_IS_VALID_OFFSET 0x00000000
  219. #define RX_MPDU_DESC_INFO_0_SA_IS_VALID_LSB 25
  220. #define RX_MPDU_DESC_INFO_0_SA_IS_VALID_MASK 0x02000000
  221. /* Description RX_MPDU_DESC_INFO_0_SA_IDX_TIMEOUT
  222. When set, at least 1 MSDU within the MPDU has an
  223. unsuccessful MAC source address search due to the expiration
  224. of the search timer.
  225. <legal all>
  226. */
  227. #define RX_MPDU_DESC_INFO_0_SA_IDX_TIMEOUT_OFFSET 0x00000000
  228. #define RX_MPDU_DESC_INFO_0_SA_IDX_TIMEOUT_LSB 26
  229. #define RX_MPDU_DESC_INFO_0_SA_IDX_TIMEOUT_MASK 0x04000000
  230. /* Description RX_MPDU_DESC_INFO_0_DA_IS_VALID
  231. When set, OLE found a valid DA entry for all MSDUs in
  232. this MPDU
  233. <legal all>
  234. */
  235. #define RX_MPDU_DESC_INFO_0_DA_IS_VALID_OFFSET 0x00000000
  236. #define RX_MPDU_DESC_INFO_0_DA_IS_VALID_LSB 27
  237. #define RX_MPDU_DESC_INFO_0_DA_IS_VALID_MASK 0x08000000
  238. /* Description RX_MPDU_DESC_INFO_0_DA_IS_MCBC
  239. Field Only valid if da_is_valid is set
  240. When set, at least one of the DA addresses is a
  241. Multicast or Broadcast address.
  242. <legal all>
  243. */
  244. #define RX_MPDU_DESC_INFO_0_DA_IS_MCBC_OFFSET 0x00000000
  245. #define RX_MPDU_DESC_INFO_0_DA_IS_MCBC_LSB 28
  246. #define RX_MPDU_DESC_INFO_0_DA_IS_MCBC_MASK 0x10000000
  247. /* Description RX_MPDU_DESC_INFO_0_DA_IDX_TIMEOUT
  248. When set, at least 1 MSDU within the MPDU has an
  249. unsuccessful MAC destination address search due to the
  250. expiration of the search timer.
  251. <legal all>
  252. */
  253. #define RX_MPDU_DESC_INFO_0_DA_IDX_TIMEOUT_OFFSET 0x00000000
  254. #define RX_MPDU_DESC_INFO_0_DA_IDX_TIMEOUT_LSB 29
  255. #define RX_MPDU_DESC_INFO_0_DA_IDX_TIMEOUT_MASK 0x20000000
  256. /* Description RX_MPDU_DESC_INFO_0_RAW_MPDU
  257. Field only valid when first_msdu_in_mpdu_flag is set.
  258. When set, the contents in the MSDU buffer contains a
  259. 'RAW' MPDU. This 'RAW' MPDU might be spread out over
  260. multiple MSDU buffers.
  261. <legal all>
  262. */
  263. #define RX_MPDU_DESC_INFO_0_RAW_MPDU_OFFSET 0x00000000
  264. #define RX_MPDU_DESC_INFO_0_RAW_MPDU_LSB 30
  265. #define RX_MPDU_DESC_INFO_0_RAW_MPDU_MASK 0x40000000
  266. /* Description RX_MPDU_DESC_INFO_0_MORE_FRAGMENT_FLAG
  267. The More Fragment bit setting from the MPDU header of
  268. the received frame
  269. <legal all>
  270. */
  271. #define RX_MPDU_DESC_INFO_0_MORE_FRAGMENT_FLAG_OFFSET 0x00000000
  272. #define RX_MPDU_DESC_INFO_0_MORE_FRAGMENT_FLAG_LSB 31
  273. #define RX_MPDU_DESC_INFO_0_MORE_FRAGMENT_FLAG_MASK 0x80000000
  274. /* Description RX_MPDU_DESC_INFO_1_PEER_META_DATA
  275. Meta data that SW has programmed in the Peer table entry
  276. of the transmitting STA.
  277. <legal all>
  278. */
  279. #define RX_MPDU_DESC_INFO_1_PEER_META_DATA_OFFSET 0x00000004
  280. #define RX_MPDU_DESC_INFO_1_PEER_META_DATA_LSB 0
  281. #define RX_MPDU_DESC_INFO_1_PEER_META_DATA_MASK 0xffffffff
  282. #endif // _RX_MPDU_DESC_INFO_H_