tx_peer_entry.h 35 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868
  1. /* Copyright (c) 2022, Qualcomm Innovation Center, Inc. All rights reserved.
  2. *
  3. * Permission to use, copy, modify, and/or distribute this software for any
  4. * purpose with or without fee is hereby granted, provided that the above
  5. * copyright notice and this permission notice appear in all copies.
  6. *
  7. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  8. * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  9. * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  10. * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  11. * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  12. * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  13. * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  14. */
  15. #ifndef _TX_PEER_ENTRY_H_
  16. #define _TX_PEER_ENTRY_H_
  17. #if !defined(__ASSEMBLER__)
  18. #endif
  19. #define NUM_OF_DWORDS_TX_PEER_ENTRY 18
  20. #define NUM_OF_QWORDS_TX_PEER_ENTRY 9
  21. struct tx_peer_entry {
  22. #ifndef WIFI_BIT_ORDER_BIG_ENDIAN
  23. uint32_t mac_addr_a_31_0 : 32; // [31:0]
  24. uint32_t mac_addr_a_47_32 : 16, // [15:0]
  25. mac_addr_b_15_0 : 16; // [31:16]
  26. uint32_t mac_addr_b_47_16 : 32; // [31:0]
  27. uint32_t use_ad_b : 1, // [0:0]
  28. strip_insert_vlan_inner : 1, // [1:1]
  29. strip_insert_vlan_outer : 1, // [2:2]
  30. vlan_llc_mode : 1, // [3:3]
  31. key_type : 4, // [7:4]
  32. a_msdu_wds_ad3_ad4 : 3, // [10:8]
  33. ignore_hard_filters : 1, // [11:11]
  34. ignore_soft_filters : 1, // [12:12]
  35. epd_output : 1, // [13:13]
  36. wds : 1, // [14:14]
  37. insert_or_strip : 1, // [15:15]
  38. sw_filter_id : 16; // [31:16]
  39. uint32_t temporal_key_31_0 : 32; // [31:0]
  40. uint32_t temporal_key_63_32 : 32; // [31:0]
  41. uint32_t temporal_key_95_64 : 32; // [31:0]
  42. uint32_t temporal_key_127_96 : 32; // [31:0]
  43. uint32_t temporal_key_159_128 : 32; // [31:0]
  44. uint32_t temporal_key_191_160 : 32; // [31:0]
  45. uint32_t temporal_key_223_192 : 32; // [31:0]
  46. uint32_t temporal_key_255_224 : 32; // [31:0]
  47. uint32_t sta_partial_aid : 11, // [10:0]
  48. transmit_vif : 4, // [14:11]
  49. block_this_user : 1, // [15:15]
  50. mesh_amsdu_mode : 2, // [17:16]
  51. use_qos_alt_mute_mask : 1, // [18:18]
  52. dl_ul_direction : 1, // [19:19]
  53. reserved_12 : 12; // [31:20]
  54. uint32_t insert_vlan_outer_tci : 16, // [15:0]
  55. insert_vlan_inner_tci : 16; // [31:16]
  56. uint32_t multi_link_addr_ad1_31_0 : 32; // [31:0]
  57. uint32_t multi_link_addr_ad1_47_32 : 16, // [15:0]
  58. multi_link_addr_ad2_15_0 : 16; // [31:16]
  59. uint32_t multi_link_addr_ad2_47_16 : 32; // [31:0]
  60. uint32_t multi_link_addr_crypto_enable : 1, // [0:0]
  61. reserved_17a : 15, // [15:1]
  62. sw_peer_id : 16; // [31:16]
  63. #else
  64. uint32_t mac_addr_a_31_0 : 32; // [31:0]
  65. uint32_t mac_addr_b_15_0 : 16, // [31:16]
  66. mac_addr_a_47_32 : 16; // [15:0]
  67. uint32_t mac_addr_b_47_16 : 32; // [31:0]
  68. uint32_t sw_filter_id : 16, // [31:16]
  69. insert_or_strip : 1, // [15:15]
  70. wds : 1, // [14:14]
  71. epd_output : 1, // [13:13]
  72. ignore_soft_filters : 1, // [12:12]
  73. ignore_hard_filters : 1, // [11:11]
  74. a_msdu_wds_ad3_ad4 : 3, // [10:8]
  75. key_type : 4, // [7:4]
  76. vlan_llc_mode : 1, // [3:3]
  77. strip_insert_vlan_outer : 1, // [2:2]
  78. strip_insert_vlan_inner : 1, // [1:1]
  79. use_ad_b : 1; // [0:0]
  80. uint32_t temporal_key_31_0 : 32; // [31:0]
  81. uint32_t temporal_key_63_32 : 32; // [31:0]
  82. uint32_t temporal_key_95_64 : 32; // [31:0]
  83. uint32_t temporal_key_127_96 : 32; // [31:0]
  84. uint32_t temporal_key_159_128 : 32; // [31:0]
  85. uint32_t temporal_key_191_160 : 32; // [31:0]
  86. uint32_t temporal_key_223_192 : 32; // [31:0]
  87. uint32_t temporal_key_255_224 : 32; // [31:0]
  88. uint32_t reserved_12 : 12, // [31:20]
  89. dl_ul_direction : 1, // [19:19]
  90. use_qos_alt_mute_mask : 1, // [18:18]
  91. mesh_amsdu_mode : 2, // [17:16]
  92. block_this_user : 1, // [15:15]
  93. transmit_vif : 4, // [14:11]
  94. sta_partial_aid : 11; // [10:0]
  95. uint32_t insert_vlan_inner_tci : 16, // [31:16]
  96. insert_vlan_outer_tci : 16; // [15:0]
  97. uint32_t multi_link_addr_ad1_31_0 : 32; // [31:0]
  98. uint32_t multi_link_addr_ad2_15_0 : 16, // [31:16]
  99. multi_link_addr_ad1_47_32 : 16; // [15:0]
  100. uint32_t multi_link_addr_ad2_47_16 : 32; // [31:0]
  101. uint32_t sw_peer_id : 16, // [31:16]
  102. reserved_17a : 15, // [15:1]
  103. multi_link_addr_crypto_enable : 1; // [0:0]
  104. #endif
  105. };
  106. /* Description MAC_ADDR_A_31_0
  107. Consumer: TX OLE
  108. Producer: SW
  109. Lower 32 bits of the MAC address A used by HW for encapsulating
  110. 802.11
  111. <legal all>
  112. */
  113. #define TX_PEER_ENTRY_MAC_ADDR_A_31_0_OFFSET 0x0000000000000000
  114. #define TX_PEER_ENTRY_MAC_ADDR_A_31_0_LSB 0
  115. #define TX_PEER_ENTRY_MAC_ADDR_A_31_0_MSB 31
  116. #define TX_PEER_ENTRY_MAC_ADDR_A_31_0_MASK 0x00000000ffffffff
  117. /* Description MAC_ADDR_A_47_32
  118. Consumer: TX OLE
  119. Producer: SW
  120. Upper 16 bits of the MAC address A used by HW for encapsulating
  121. 802.11
  122. <legal all>
  123. */
  124. #define TX_PEER_ENTRY_MAC_ADDR_A_47_32_OFFSET 0x0000000000000000
  125. #define TX_PEER_ENTRY_MAC_ADDR_A_47_32_LSB 32
  126. #define TX_PEER_ENTRY_MAC_ADDR_A_47_32_MSB 47
  127. #define TX_PEER_ENTRY_MAC_ADDR_A_47_32_MASK 0x0000ffff00000000
  128. /* Description MAC_ADDR_B_15_0
  129. Consumer: TX OLE
  130. Producer: SW
  131. Lower 16 bits of the MAC address B used by HW for encapsulating
  132. 802.11
  133. <legal all>
  134. */
  135. #define TX_PEER_ENTRY_MAC_ADDR_B_15_0_OFFSET 0x0000000000000000
  136. #define TX_PEER_ENTRY_MAC_ADDR_B_15_0_LSB 48
  137. #define TX_PEER_ENTRY_MAC_ADDR_B_15_0_MSB 63
  138. #define TX_PEER_ENTRY_MAC_ADDR_B_15_0_MASK 0xffff000000000000
  139. /* Description MAC_ADDR_B_47_16
  140. Consumer: TX OLE
  141. Producer: SW
  142. Upper 32 bits of the MAC address B used by HW for encapsulating
  143. 802.11
  144. <legal all>
  145. */
  146. #define TX_PEER_ENTRY_MAC_ADDR_B_47_16_OFFSET 0x0000000000000008
  147. #define TX_PEER_ENTRY_MAC_ADDR_B_47_16_LSB 0
  148. #define TX_PEER_ENTRY_MAC_ADDR_B_47_16_MSB 31
  149. #define TX_PEER_ENTRY_MAC_ADDR_B_47_16_MASK 0x00000000ffffffff
  150. /* Description USE_AD_B
  151. Consumer: TX OLE
  152. Producer: SW
  153. The bit is only evaluated when this MSDU is the first MSDU
  154. in an MPDU. For other MSDUs this bit setting is ignored.
  155. It is part of the sw_msdu_param coming from the QM ADD frame
  156. command.
  157. Normally in AP mode the DA address is used as the RA. This
  158. is normally fine but the use_ad_b bit should be set when
  159. DA is a multicast/broadcast address but we want to send
  160. this packet using the destination STA address which will
  161. be held in the mac_addr_b field of the peer descriptor.
  162. <legal all>
  163. */
  164. #define TX_PEER_ENTRY_USE_AD_B_OFFSET 0x0000000000000008
  165. #define TX_PEER_ENTRY_USE_AD_B_LSB 32
  166. #define TX_PEER_ENTRY_USE_AD_B_MSB 32
  167. #define TX_PEER_ENTRY_USE_AD_B_MASK 0x0000000100000000
  168. /* Description STRIP_INSERT_VLAN_INNER
  169. Consumer: TX OLE
  170. Producer: SW
  171. Strip or insert C-VLAN during encapsulation.
  172. Insert_or_strip determines whether C-VLAN is to be stripped
  173. or inserted.
  174. <legal all>
  175. */
  176. #define TX_PEER_ENTRY_STRIP_INSERT_VLAN_INNER_OFFSET 0x0000000000000008
  177. #define TX_PEER_ENTRY_STRIP_INSERT_VLAN_INNER_LSB 33
  178. #define TX_PEER_ENTRY_STRIP_INSERT_VLAN_INNER_MSB 33
  179. #define TX_PEER_ENTRY_STRIP_INSERT_VLAN_INNER_MASK 0x0000000200000000
  180. /* Description STRIP_INSERT_VLAN_OUTER
  181. Consumer: TX OLE
  182. Producer: SW
  183. Strip or insert S-VLAN during encapsulation.
  184. Insert or strip determines whether S-VLAN is to be stripped
  185. or inserted.
  186. <legal all>
  187. */
  188. #define TX_PEER_ENTRY_STRIP_INSERT_VLAN_OUTER_OFFSET 0x0000000000000008
  189. #define TX_PEER_ENTRY_STRIP_INSERT_VLAN_OUTER_LSB 34
  190. #define TX_PEER_ENTRY_STRIP_INSERT_VLAN_OUTER_MSB 34
  191. #define TX_PEER_ENTRY_STRIP_INSERT_VLAN_OUTER_MASK 0x0000000400000000
  192. /* Description VLAN_LLC_MODE
  193. Consumer: TX OLE
  194. Producer: SW
  195. If set encapsulate/decapsulate using the Scorpion compatible
  196. VLAN LLC format
  197. */
  198. #define TX_PEER_ENTRY_VLAN_LLC_MODE_OFFSET 0x0000000000000008
  199. #define TX_PEER_ENTRY_VLAN_LLC_MODE_LSB 35
  200. #define TX_PEER_ENTRY_VLAN_LLC_MODE_MSB 35
  201. #define TX_PEER_ENTRY_VLAN_LLC_MODE_MASK 0x0000000800000000
  202. /* Description KEY_TYPE
  203. Consumer: TX OLE, TX CRYPTO
  204. Producer: SW
  205. The key_type indicates the cipher suite corresponding to
  206. this peer entry:
  207. <enum 0 wep_40> WEP 40-bit
  208. <enum 1 wep_104> WEP 104-bit
  209. <enum 2 tkip_no_mic> TKIP without MIC
  210. <enum 3 wep_128> WEP 128-bit
  211. <enum 4 tkip_with_mic> TKIP with MIC
  212. <enum 5 wapi> WAPI
  213. <enum 6 aes_ccmp_128> AES CCMP 128
  214. <enum 7 no_cipher> No crypto
  215. <enum 8 aes_ccmp_256> AES CCMP 256
  216. <enum 9 aes_gcmp_128> AES GCMP 128
  217. <enum 10 aes_gcmp_256> AES GCMP 256
  218. <enum 11 wapi_gcm_sm4> WAPI GCM SM4
  219. <enum 12 wep_varied_width> DO NOT USE. This Key type ONLY
  220. to be used for RX side
  221. <legal 0-12>
  222. */
  223. #define TX_PEER_ENTRY_KEY_TYPE_OFFSET 0x0000000000000008
  224. #define TX_PEER_ENTRY_KEY_TYPE_LSB 36
  225. #define TX_PEER_ENTRY_KEY_TYPE_MSB 39
  226. #define TX_PEER_ENTRY_KEY_TYPE_MASK 0x000000f000000000
  227. /* Description A_MSDU_WDS_AD3_AD4
  228. Consumer: TX OLE
  229. Producer: SW
  230. Determines the selection of AD3 and AD4 for A-MSDU 4 address
  231. frames (WDS):
  232. <enum 0 ad3_a__ad4_a> AD3 = AD_A, AD4 = AD_A
  233. <enum 1 ad3_a__ad4_b> AD3 = AD_A, AD4 = AD_B
  234. <enum 2 ad3_b__ad4_a> AD3 = AD_B, AD4 = AD_A
  235. <enum 3 ad3_b__ad4_b> AD3 = AD_B, AD4 = AD_B
  236. <enum 4 ad3_da__ad4_sa> AD3 = DA, AD4 = SA
  237. <legal 0-4>
  238. */
  239. #define TX_PEER_ENTRY_A_MSDU_WDS_AD3_AD4_OFFSET 0x0000000000000008
  240. #define TX_PEER_ENTRY_A_MSDU_WDS_AD3_AD4_LSB 40
  241. #define TX_PEER_ENTRY_A_MSDU_WDS_AD3_AD4_MSB 42
  242. #define TX_PEER_ENTRY_A_MSDU_WDS_AD3_AD4_MASK 0x0000070000000000
  243. /* Description IGNORE_HARD_FILTERS
  244. SW can program this bit to 0x1 to ignore HARD filter conditions
  245. and HWSCH will proceed with transmission, even if the HARD
  246. filter bit is set in Filter LUT.
  247. Note that SOFT filter conditions will filter the command,
  248. even if this bit is set and ignore_soft_filters is not set
  249. For filtering all frames marked in the Filter LUT, both
  250. ignore_soft_filters and ignore_hard_filters should be set
  251. <legal all>
  252. */
  253. #define TX_PEER_ENTRY_IGNORE_HARD_FILTERS_OFFSET 0x0000000000000008
  254. #define TX_PEER_ENTRY_IGNORE_HARD_FILTERS_LSB 43
  255. #define TX_PEER_ENTRY_IGNORE_HARD_FILTERS_MSB 43
  256. #define TX_PEER_ENTRY_IGNORE_HARD_FILTERS_MASK 0x0000080000000000
  257. /* Description IGNORE_SOFT_FILTERS
  258. SW can program this bit to 0x1 to ignore SOFT filter conditions
  259. and HWSCH will proceed with transmission, even if the SOFT
  260. filter bit is set in Filter LUT.
  261. Note that HARD filter conditions will filter the command,
  262. even if this bit is set and ignore_hard_filters is not set
  263. For filtering all frames marked in the Filter LUT, both
  264. ignore_soft_filters and ignore_hard_filters should be set
  265. <legal all>
  266. */
  267. #define TX_PEER_ENTRY_IGNORE_SOFT_FILTERS_OFFSET 0x0000000000000008
  268. #define TX_PEER_ENTRY_IGNORE_SOFT_FILTERS_LSB 44
  269. #define TX_PEER_ENTRY_IGNORE_SOFT_FILTERS_MSB 44
  270. #define TX_PEER_ENTRY_IGNORE_SOFT_FILTERS_MASK 0x0000100000000000
  271. /* Description EPD_OUTPUT
  272. Consumer: TX OLE
  273. Producer: SW
  274. If set use EPD instead of LPD
  275. */
  276. #define TX_PEER_ENTRY_EPD_OUTPUT_OFFSET 0x0000000000000008
  277. #define TX_PEER_ENTRY_EPD_OUTPUT_LSB 45
  278. #define TX_PEER_ENTRY_EPD_OUTPUT_MSB 45
  279. #define TX_PEER_ENTRY_EPD_OUTPUT_MASK 0x0000200000000000
  280. /* Description WDS
  281. If set all the frames in this transmission (for this user)
  282. are 4-address frame.
  283. If not all frames need to use 4 address format, SW has per
  284. frame 'wds' control, by using the 'wds' flag in the MSDU_EXTENSION
  285. descriptor
  286. Used by the OLE during encapsulation.
  287. <legal all>
  288. */
  289. #define TX_PEER_ENTRY_WDS_OFFSET 0x0000000000000008
  290. #define TX_PEER_ENTRY_WDS_LSB 46
  291. #define TX_PEER_ENTRY_WDS_MSB 46
  292. #define TX_PEER_ENTRY_WDS_MASK 0x0000400000000000
  293. /* Description INSERT_OR_STRIP
  294. <enum 0 TXOLE_STRIP_VLAN> TXOLE will strip inner or outer
  295. VLAN (if present in the frame) based on Strip_insert_vlan_{inner,
  296. outer}
  297. <enum 1 TXOLE_INSERT_VLAN> TXOLE will insert inner or outer
  298. VLAN (only if absent in the frame) based on Strip_insert_vlan_{inner,
  299. outer} with the TCI(s) given by Insert_vlan_{inner, outer}_tci
  300. NOTE: Strip VLAN is not supported by TCL.
  301. <legal all>
  302. */
  303. #define TX_PEER_ENTRY_INSERT_OR_STRIP_OFFSET 0x0000000000000008
  304. #define TX_PEER_ENTRY_INSERT_OR_STRIP_LSB 47
  305. #define TX_PEER_ENTRY_INSERT_OR_STRIP_MSB 47
  306. #define TX_PEER_ENTRY_INSERT_OR_STRIP_MASK 0x0000800000000000
  307. /* Description SW_FILTER_ID
  308. Consumer: SCH
  309. Producer: SW
  310. The full STA AID.
  311. Use by SCH to determine if transmission for this STA should
  312. be filtered as it just went into power save state.
  313. In case of MU transmission, it means only this STA needs
  314. to be removed from the transmission...
  315. <legal all>
  316. */
  317. #define TX_PEER_ENTRY_SW_FILTER_ID_OFFSET 0x0000000000000008
  318. #define TX_PEER_ENTRY_SW_FILTER_ID_LSB 48
  319. #define TX_PEER_ENTRY_SW_FILTER_ID_MSB 63
  320. #define TX_PEER_ENTRY_SW_FILTER_ID_MASK 0xffff000000000000
  321. /* Description TEMPORAL_KEY_31_0
  322. Consumer: TX CRYPTO
  323. Producer: SW
  324. First 32 bits of the temporal key material. The temporal
  325. key for WEP 40-bit uses the first 40 bits, WEP 104-bit
  326. uses the first 104 bits, WEP 128-bit uses all 128 bits,
  327. TKIP with/without MIC uses 128 bits, WAPI uses all 128 bits,
  328. and AES-CCM uses all 128 bits.
  329. Note that for TKIP, the 64 MIC bits are located in fields
  330. 'temporal_key[255:192]
  331. <legal all>
  332. */
  333. #define TX_PEER_ENTRY_TEMPORAL_KEY_31_0_OFFSET 0x0000000000000010
  334. #define TX_PEER_ENTRY_TEMPORAL_KEY_31_0_LSB 0
  335. #define TX_PEER_ENTRY_TEMPORAL_KEY_31_0_MSB 31
  336. #define TX_PEER_ENTRY_TEMPORAL_KEY_31_0_MASK 0x00000000ffffffff
  337. /* Description TEMPORAL_KEY_63_32
  338. Consumer: TX CRYPTO
  339. Producer: SW
  340. Second 32 bits of the temporal key material. See the description
  341. of temporal_key_31_0.
  342. <legal all>
  343. */
  344. #define TX_PEER_ENTRY_TEMPORAL_KEY_63_32_OFFSET 0x0000000000000010
  345. #define TX_PEER_ENTRY_TEMPORAL_KEY_63_32_LSB 32
  346. #define TX_PEER_ENTRY_TEMPORAL_KEY_63_32_MSB 63
  347. #define TX_PEER_ENTRY_TEMPORAL_KEY_63_32_MASK 0xffffffff00000000
  348. /* Description TEMPORAL_KEY_95_64
  349. Consumer: TX CRYPTO
  350. Producer: SW
  351. Third 32 bits of the temporal key material. See the description
  352. of temporal_key_31_0.
  353. <legal all>
  354. */
  355. #define TX_PEER_ENTRY_TEMPORAL_KEY_95_64_OFFSET 0x0000000000000018
  356. #define TX_PEER_ENTRY_TEMPORAL_KEY_95_64_LSB 0
  357. #define TX_PEER_ENTRY_TEMPORAL_KEY_95_64_MSB 31
  358. #define TX_PEER_ENTRY_TEMPORAL_KEY_95_64_MASK 0x00000000ffffffff
  359. /* Description TEMPORAL_KEY_127_96
  360. Consumer: TX CRYPTO
  361. Producer: SW
  362. Fourth 32 bits of the temporal key material. See the description
  363. of temporal_key_31_0.
  364. <legal all>
  365. */
  366. #define TX_PEER_ENTRY_TEMPORAL_KEY_127_96_OFFSET 0x0000000000000018
  367. #define TX_PEER_ENTRY_TEMPORAL_KEY_127_96_LSB 32
  368. #define TX_PEER_ENTRY_TEMPORAL_KEY_127_96_MSB 63
  369. #define TX_PEER_ENTRY_TEMPORAL_KEY_127_96_MASK 0xffffffff00000000
  370. /* Description TEMPORAL_KEY_159_128
  371. Consumer: TX CRYPTO
  372. Producer: SW
  373. Fifth 32 bits of the temporal key material. See the description
  374. of temporal_key_31_0.
  375. <legal all>
  376. */
  377. #define TX_PEER_ENTRY_TEMPORAL_KEY_159_128_OFFSET 0x0000000000000020
  378. #define TX_PEER_ENTRY_TEMPORAL_KEY_159_128_LSB 0
  379. #define TX_PEER_ENTRY_TEMPORAL_KEY_159_128_MSB 31
  380. #define TX_PEER_ENTRY_TEMPORAL_KEY_159_128_MASK 0x00000000ffffffff
  381. /* Description TEMPORAL_KEY_191_160
  382. Consumer: TX CRYPTO
  383. Producer: SW
  384. Final 32 bits of the temporal key material. See the description
  385. of temporal_key_31_0.
  386. <legal all>
  387. */
  388. #define TX_PEER_ENTRY_TEMPORAL_KEY_191_160_OFFSET 0x0000000000000020
  389. #define TX_PEER_ENTRY_TEMPORAL_KEY_191_160_LSB 32
  390. #define TX_PEER_ENTRY_TEMPORAL_KEY_191_160_MSB 63
  391. #define TX_PEER_ENTRY_TEMPORAL_KEY_191_160_MASK 0xffffffff00000000
  392. /* Description TEMPORAL_KEY_223_192
  393. Consumer: TX CRYPTO
  394. Producer: SW
  395. Final 32 bits of the temporal key material. See the description
  396. of temporal_key_31_0.
  397. For TKIP this is the TX MIC key[31:0].
  398. <legal all>
  399. */
  400. #define TX_PEER_ENTRY_TEMPORAL_KEY_223_192_OFFSET 0x0000000000000028
  401. #define TX_PEER_ENTRY_TEMPORAL_KEY_223_192_LSB 0
  402. #define TX_PEER_ENTRY_TEMPORAL_KEY_223_192_MSB 31
  403. #define TX_PEER_ENTRY_TEMPORAL_KEY_223_192_MASK 0x00000000ffffffff
  404. /* Description TEMPORAL_KEY_255_224
  405. Consumer: TX CRYPTO
  406. Producer: SW
  407. Final 32 bits of the temporal key material. See the description
  408. of temporal_key_31_0.
  409. For TKIP this is the TX MIC key[63:32].
  410. <legal all>
  411. */
  412. #define TX_PEER_ENTRY_TEMPORAL_KEY_255_224_OFFSET 0x0000000000000028
  413. #define TX_PEER_ENTRY_TEMPORAL_KEY_255_224_LSB 32
  414. #define TX_PEER_ENTRY_TEMPORAL_KEY_255_224_MSB 63
  415. #define TX_PEER_ENTRY_TEMPORAL_KEY_255_224_MASK 0xffffffff00000000
  416. /* Description STA_PARTIAL_AID
  417. This field in only used by the PDG. All other modules should
  418. ignore this field.
  419. This field is only valid in case of a transmission at VHT
  420. rates or HE rates.
  421. For VHT:
  422. This field is the Partial AID to be filled in to the VHT
  423. preamble.
  424. For HE:
  425. This field is the sta_aid to be filled into the SIG B field.
  426. In 11ah mode of operation, this field is provided by SW
  427. to populate the the ID value of the SIG preamble of the
  428. PPDU
  429. */
  430. #define TX_PEER_ENTRY_STA_PARTIAL_AID_OFFSET 0x0000000000000030
  431. #define TX_PEER_ENTRY_STA_PARTIAL_AID_LSB 0
  432. #define TX_PEER_ENTRY_STA_PARTIAL_AID_MSB 10
  433. #define TX_PEER_ENTRY_STA_PARTIAL_AID_MASK 0x00000000000007ff
  434. /* Description TRANSMIT_VIF
  435. Consumer: TXOLE
  436. Producer: SW
  437. The VIF for this transmission. Used in MCC mode to control/overwrite
  438. the PM bit settings.
  439. <legal all>
  440. */
  441. #define TX_PEER_ENTRY_TRANSMIT_VIF_OFFSET 0x0000000000000030
  442. #define TX_PEER_ENTRY_TRANSMIT_VIF_LSB 11
  443. #define TX_PEER_ENTRY_TRANSMIT_VIF_MSB 14
  444. #define TX_PEER_ENTRY_TRANSMIT_VIF_MASK 0x0000000000007800
  445. /* Description BLOCK_THIS_USER
  446. Consumer: PDG
  447. Producer: SCH
  448. Set by SCH when a MU transmission is started and this STA
  449. has (just) entered or is in power save mode.
  450. Due to the MU transmission SCH shall not terminate this
  451. MU transmission (as is done with SU transmission), but continue
  452. with the transmissions for all other STAs.
  453. As a result of this bit being set, PDG will at certain moment
  454. generate the MPDU limit TLV with field Num_mpdu_user set
  455. to 0
  456. PDG shall treat this user as a user without any data. All
  457. rules related to terminating MU transmissions when too
  458. many users do not have any data shall include this user
  459. as a user having zero data.
  460. When clear, PDG can ignore this bit
  461. <legal all>
  462. */
  463. #define TX_PEER_ENTRY_BLOCK_THIS_USER_OFFSET 0x0000000000000030
  464. #define TX_PEER_ENTRY_BLOCK_THIS_USER_LSB 15
  465. #define TX_PEER_ENTRY_BLOCK_THIS_USER_MSB 15
  466. #define TX_PEER_ENTRY_BLOCK_THIS_USER_MASK 0x0000000000008000
  467. /* Description MESH_AMSDU_MODE
  468. Consumer: TX OLE
  469. Producer: SW
  470. This field is used only when the first MSDU of any MPDU
  471. that TX OLE encounters is in Native WiFi format and includes
  472. a 'Mesh Control' field between the header and the LLC.
  473. The creation of the A-MSDU 'Length' field in the MPDU (if
  474. aggregating multiple MSDUs) is decided by the value of
  475. this field.
  476. <enum 0 MESH_MODE_0> DO NOT USE
  477. <enum 1 MESH_MODE_Q2Q> A-MSDU 'Length' is big endian and
  478. includes the length of Mesh Control.
  479. <enum 2 MESH_MODE_11S_BE> A-MSDU 'Length' is big endian
  480. and excludes the length of Mesh Control.
  481. <enum 3 MESH_MODE_11S_LE> A-MSDU 'Length' is little endian
  482. and excludes the length of Mesh Control. This is 802.11s-compliant.
  483. NOTE 1: For compatibility TXOLE treats MESH_MODE_0 identically
  484. to MESH_MODE_Q2Q.
  485. NOTE 2: This e-numeration is different from other fields
  486. named Mesh_sta or mesh_enable where the value zero disables
  487. mesh processing.
  488. <legal 0-3>
  489. */
  490. #define TX_PEER_ENTRY_MESH_AMSDU_MODE_OFFSET 0x0000000000000030
  491. #define TX_PEER_ENTRY_MESH_AMSDU_MODE_LSB 16
  492. #define TX_PEER_ENTRY_MESH_AMSDU_MODE_MSB 17
  493. #define TX_PEER_ENTRY_MESH_AMSDU_MODE_MASK 0x0000000000030000
  494. /* Description USE_QOS_ALT_MUTE_MASK
  495. Lithium and prior generation WAPI implementations did not
  496. mute any QoS Control bits when generating the AAD. Setting
  497. this bit chooses an alternative configurable QoS Control
  498. mute mask in Crypto for compatibility with those chips.
  499. For AES, alternative configurable QoS Control mute mask
  500. is required in Crypto to support SPP A-MSDUs for increased
  501. security.
  502. <legal all>
  503. */
  504. #define TX_PEER_ENTRY_USE_QOS_ALT_MUTE_MASK_OFFSET 0x0000000000000030
  505. #define TX_PEER_ENTRY_USE_QOS_ALT_MUTE_MASK_LSB 18
  506. #define TX_PEER_ENTRY_USE_QOS_ALT_MUTE_MASK_MSB 18
  507. #define TX_PEER_ENTRY_USE_QOS_ALT_MUTE_MASK_MASK 0x0000000000040000
  508. /* Description DL_UL_DIRECTION
  509. 'Direction' to be inferred for raw WiFi esp. management
  510. frames sent to a multi-link peer, for translating RA and/or
  511. TA.
  512. <enum 0 DL_UL_FLAG_IS_DL_OR_TDLS>
  513. <enum 1 DL_UL_FLAG_IS_UL>
  514. <legal all>
  515. */
  516. #define TX_PEER_ENTRY_DL_UL_DIRECTION_OFFSET 0x0000000000000030
  517. #define TX_PEER_ENTRY_DL_UL_DIRECTION_LSB 19
  518. #define TX_PEER_ENTRY_DL_UL_DIRECTION_MSB 19
  519. #define TX_PEER_ENTRY_DL_UL_DIRECTION_MASK 0x0000000000080000
  520. /* Description RESERVED_12
  521. <legal 0>
  522. */
  523. #define TX_PEER_ENTRY_RESERVED_12_OFFSET 0x0000000000000030
  524. #define TX_PEER_ENTRY_RESERVED_12_LSB 20
  525. #define TX_PEER_ENTRY_RESERVED_12_MSB 31
  526. #define TX_PEER_ENTRY_RESERVED_12_MASK 0x00000000fff00000
  527. /* Description INSERT_VLAN_OUTER_TCI
  528. The tag control info to use when TXOLE inserts outer VLAN
  529. if enabled by Strip_insert_vlan_outer and Insert_or_strip
  530. */
  531. #define TX_PEER_ENTRY_INSERT_VLAN_OUTER_TCI_OFFSET 0x0000000000000030
  532. #define TX_PEER_ENTRY_INSERT_VLAN_OUTER_TCI_LSB 32
  533. #define TX_PEER_ENTRY_INSERT_VLAN_OUTER_TCI_MSB 47
  534. #define TX_PEER_ENTRY_INSERT_VLAN_OUTER_TCI_MASK 0x0000ffff00000000
  535. /* Description INSERT_VLAN_INNER_TCI
  536. The tag control info to use when TXOLE inserts inner VLAN
  537. if enabled by Strip_insert_vlan_inner and Insert_or_strip
  538. */
  539. #define TX_PEER_ENTRY_INSERT_VLAN_INNER_TCI_OFFSET 0x0000000000000030
  540. #define TX_PEER_ENTRY_INSERT_VLAN_INNER_TCI_LSB 48
  541. #define TX_PEER_ENTRY_INSERT_VLAN_INNER_TCI_MSB 63
  542. #define TX_PEER_ENTRY_INSERT_VLAN_INNER_TCI_MASK 0xffff000000000000
  543. /* Description MULTI_LINK_ADDR_AD1_31_0
  544. Consumer: TX CRYPTO
  545. Producer: FW
  546. Field only valid if Multi_link_addr_crypto_enable is set
  547. Multi-link receiver address (address1) for transmissions
  548. matching this peer entry, bits [31:0]
  549. */
  550. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD1_31_0_OFFSET 0x0000000000000038
  551. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD1_31_0_LSB 0
  552. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD1_31_0_MSB 31
  553. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD1_31_0_MASK 0x00000000ffffffff
  554. /* Description MULTI_LINK_ADDR_AD1_47_32
  555. Consumer: TX CRYPTO
  556. Producer: FW
  557. Field only valid if Multi_link_addr_crypto_enable is set
  558. Multi-link receiver address (address1) for transmissions
  559. matching this peer entry, bits [47:32]
  560. */
  561. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD1_47_32_OFFSET 0x0000000000000038
  562. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD1_47_32_LSB 32
  563. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD1_47_32_MSB 47
  564. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD1_47_32_MASK 0x0000ffff00000000
  565. /* Description MULTI_LINK_ADDR_AD2_15_0
  566. Consumer: TX CRYPTO
  567. Producer: FW
  568. Field only valid if Multi_link_addr_crypto_enable is set
  569. Multi-link transmitter address (address2) for transmissions
  570. matching this peer entry, bits [15:0]
  571. */
  572. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD2_15_0_OFFSET 0x0000000000000038
  573. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD2_15_0_LSB 48
  574. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD2_15_0_MSB 63
  575. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD2_15_0_MASK 0xffff000000000000
  576. /* Description MULTI_LINK_ADDR_AD2_47_16
  577. Consumer: TX CRYPTO
  578. Producer: FW
  579. Field only valid if Multi_link_addr_crypto_enable is set
  580. Multi-link transmitter address (address2) for transmissions
  581. matching this peer entry, bits [47:16]
  582. */
  583. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD2_47_16_OFFSET 0x0000000000000040
  584. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD2_47_16_LSB 0
  585. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD2_47_16_MSB 31
  586. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_AD2_47_16_MASK 0x00000000ffffffff
  587. /* Description MULTI_LINK_ADDR_CRYPTO_ENABLE
  588. Consumer: TX CRYPTO
  589. Producer: FW
  590. If set, TX CRYPTO shall convert Address1, Address2 and BSSID
  591. of received data frames to multi-link addresses for the
  592. AAD and Nonce during encryption.
  593. <legal all>
  594. */
  595. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_CRYPTO_ENABLE_OFFSET 0x0000000000000040
  596. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_CRYPTO_ENABLE_LSB 32
  597. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_CRYPTO_ENABLE_MSB 32
  598. #define TX_PEER_ENTRY_MULTI_LINK_ADDR_CRYPTO_ENABLE_MASK 0x0000000100000000
  599. /* Description RESERVED_17A
  600. <legal 0>
  601. */
  602. #define TX_PEER_ENTRY_RESERVED_17A_OFFSET 0x0000000000000040
  603. #define TX_PEER_ENTRY_RESERVED_17A_LSB 33
  604. #define TX_PEER_ENTRY_RESERVED_17A_MSB 47
  605. #define TX_PEER_ENTRY_RESERVED_17A_MASK 0x0000fffe00000000
  606. /* Description SW_PEER_ID
  607. This field indicates a unique peer identifier provided by
  608. FW, to be logged via TXMON to host SW.
  609. <legal all>
  610. */
  611. #define TX_PEER_ENTRY_SW_PEER_ID_OFFSET 0x0000000000000040
  612. #define TX_PEER_ENTRY_SW_PEER_ID_LSB 48
  613. #define TX_PEER_ENTRY_SW_PEER_ID_MSB 63
  614. #define TX_PEER_ENTRY_SW_PEER_ID_MASK 0xffff000000000000
  615. #endif // TX_PEER_ENTRY