rxpcu_early_rx_indication.h 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  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 _RXPCU_EARLY_RX_INDICATION_H_
  16. #define _RXPCU_EARLY_RX_INDICATION_H_
  17. #if !defined(__ASSEMBLER__)
  18. #endif
  19. #define NUM_OF_DWORDS_RXPCU_EARLY_RX_INDICATION 2
  20. #define NUM_OF_QWORDS_RXPCU_EARLY_RX_INDICATION 1
  21. struct rxpcu_early_rx_indication {
  22. #ifndef WIFI_BIT_ORDER_BIG_ENDIAN
  23. uint32_t pkt_type : 4, // [3:0]
  24. dot11ax_su_extended : 1, // [4:4]
  25. rate_mcs : 4, // [8:5]
  26. dot11ax_received_ext_ru_size : 4, // [12:9]
  27. reserved_0a : 19; // [31:13]
  28. uint32_t tlv64_padding : 32; // [31:0]
  29. #else
  30. uint32_t reserved_0a : 19, // [31:13]
  31. dot11ax_received_ext_ru_size : 4, // [12:9]
  32. rate_mcs : 4, // [8:5]
  33. dot11ax_su_extended : 1, // [4:4]
  34. pkt_type : 4; // [3:0]
  35. uint32_t tlv64_padding : 32; // [31:0]
  36. #endif
  37. };
  38. /* Description PKT_TYPE
  39. Packet type:
  40. <enum 0 dot11a>802.11a PPDU type
  41. <enum 1 dot11b>802.11b PPDU type
  42. <enum 2 dot11n_mm>802.11n Mixed Mode PPDU type
  43. <enum 3 dot11ac>802.11ac PPDU type
  44. <enum 4 dot11ax>802.11ax PPDU type
  45. <enum 5 dot11ba>802.11ba (WUR) PPDU type
  46. <enum 6 dot11be>802.11be PPDU type
  47. <enum 7 dot11az>802.11az (ranging) PPDU type
  48. <enum 8 dot11n_gf>802.11n Green Field PPDU type (unsupported
  49. & aborted)
  50. */
  51. #define RXPCU_EARLY_RX_INDICATION_PKT_TYPE_OFFSET 0x0000000000000000
  52. #define RXPCU_EARLY_RX_INDICATION_PKT_TYPE_LSB 0
  53. #define RXPCU_EARLY_RX_INDICATION_PKT_TYPE_MSB 3
  54. #define RXPCU_EARLY_RX_INDICATION_PKT_TYPE_MASK 0x000000000000000f
  55. /* Description DOT11AX_SU_EXTENDED
  56. This field is only valid for pkt_type == 11ax OR pkt_type
  57. == 11be
  58. When set, the 11ax or 11be reception was an extended range
  59. SU
  60. */
  61. #define RXPCU_EARLY_RX_INDICATION_DOT11AX_SU_EXTENDED_OFFSET 0x0000000000000000
  62. #define RXPCU_EARLY_RX_INDICATION_DOT11AX_SU_EXTENDED_LSB 4
  63. #define RXPCU_EARLY_RX_INDICATION_DOT11AX_SU_EXTENDED_MSB 4
  64. #define RXPCU_EARLY_RX_INDICATION_DOT11AX_SU_EXTENDED_MASK 0x0000000000000010
  65. /* Description RATE_MCS
  66. For details, refer to MCS_TYPE description
  67. Note: This is "rate" in case of 11a/11b
  68. <legal all>
  69. */
  70. #define RXPCU_EARLY_RX_INDICATION_RATE_MCS_OFFSET 0x0000000000000000
  71. #define RXPCU_EARLY_RX_INDICATION_RATE_MCS_LSB 5
  72. #define RXPCU_EARLY_RX_INDICATION_RATE_MCS_MSB 8
  73. #define RXPCU_EARLY_RX_INDICATION_RATE_MCS_MASK 0x00000000000001e0
  74. /* Description DOT11AX_RECEIVED_EXT_RU_SIZE
  75. Field only valid in case of SU_or_uplink_MU_reception =
  76. Reception_is_SU
  77. This field is only valid for pkt_type == 11ax OR pkt_type
  78. == 11be AND dot11ax_su_extended is set
  79. The number of (basic) RUs in this extended range reception
  80. RXPCU gets this from the received HE_SIG_A
  81. <legal all>
  82. */
  83. #define RXPCU_EARLY_RX_INDICATION_DOT11AX_RECEIVED_EXT_RU_SIZE_OFFSET 0x0000000000000000
  84. #define RXPCU_EARLY_RX_INDICATION_DOT11AX_RECEIVED_EXT_RU_SIZE_LSB 9
  85. #define RXPCU_EARLY_RX_INDICATION_DOT11AX_RECEIVED_EXT_RU_SIZE_MSB 12
  86. #define RXPCU_EARLY_RX_INDICATION_DOT11AX_RECEIVED_EXT_RU_SIZE_MASK 0x0000000000001e00
  87. /* Description RESERVED_0A
  88. <legal 0>
  89. */
  90. #define RXPCU_EARLY_RX_INDICATION_RESERVED_0A_OFFSET 0x0000000000000000
  91. #define RXPCU_EARLY_RX_INDICATION_RESERVED_0A_LSB 13
  92. #define RXPCU_EARLY_RX_INDICATION_RESERVED_0A_MSB 31
  93. #define RXPCU_EARLY_RX_INDICATION_RESERVED_0A_MASK 0x00000000ffffe000
  94. /* Description TLV64_PADDING
  95. Automatic DWORD padding inserted while converting TLV32
  96. to TLV64 for 64 bit ARCH
  97. <legal 0>
  98. */
  99. #define RXPCU_EARLY_RX_INDICATION_TLV64_PADDING_OFFSET 0x0000000000000000
  100. #define RXPCU_EARLY_RX_INDICATION_TLV64_PADDING_LSB 32
  101. #define RXPCU_EARLY_RX_INDICATION_TLV64_PADDING_MSB 63
  102. #define RXPCU_EARLY_RX_INDICATION_TLV64_PADDING_MASK 0xffffffff00000000
  103. #endif // RXPCU_EARLY_RX_INDICATION