1 2 /* Copyright (c) 2022, Qualcomm Innovation Center, Inc. All rights reserved. 3 * 4 * Permission to use, copy, modify, and/or distribute this software for any 5 * purpose with or without fee is hereby granted, provided that the above 6 * copyright notice and this permission notice appear in all copies. 7 * 8 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 9 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 10 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 11 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 12 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 13 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 14 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 15 */ 16 17 18 19 20 21 22 23 24 25 26 #ifndef _HE_SIG_B2_OFDMA_INFO_H_ 27 #define _HE_SIG_B2_OFDMA_INFO_H_ 28 #if !defined(__ASSEMBLER__) 29 #endif 30 31 #define NUM_OF_DWORDS_HE_SIG_B2_OFDMA_INFO 2 32 33 34 struct he_sig_b2_ofdma_info { 35 #ifndef WIFI_BIT_ORDER_BIG_ENDIAN 36 uint32_t sta_id : 11, // [10:0] 37 nsts : 3, // [13:11] 38 txbf : 1, // [14:14] 39 sta_mcs : 4, // [18:15] 40 sta_dcm : 1, // [19:19] 41 sta_coding : 1, // [20:20] 42 reserved_0 : 10, // [30:21] 43 rx_integrity_check_passed : 1; // [31:31] 44 uint32_t user_order : 8, // [7:0] 45 cc_mask : 8, // [15:8] 46 reserved_1a : 16; // [31:16] 47 #else 48 uint32_t rx_integrity_check_passed : 1, // [31:31] 49 reserved_0 : 10, // [30:21] 50 sta_coding : 1, // [20:20] 51 sta_dcm : 1, // [19:19] 52 sta_mcs : 4, // [18:15] 53 txbf : 1, // [14:14] 54 nsts : 3, // [13:11] 55 sta_id : 11; // [10:0] 56 uint32_t reserved_1a : 16, // [31:16] 57 cc_mask : 8, // [15:8] 58 user_order : 8; // [7:0] 59 #endif 60 }; 61 62 63 /* Description STA_ID 64 65 Identifies the STA that is addressed. Details of STA ID 66 are TBD 67 */ 68 69 #define HE_SIG_B2_OFDMA_INFO_STA_ID_OFFSET 0x00000000 70 #define HE_SIG_B2_OFDMA_INFO_STA_ID_LSB 0 71 #define HE_SIG_B2_OFDMA_INFO_STA_ID_MSB 10 72 #define HE_SIG_B2_OFDMA_INFO_STA_ID_MASK 0x000007ff 73 74 75 /* Description NSTS 76 77 MAC RX side usage only: 78 79 Number of spatial streams for this user 80 81 <enum 0 1_spatial_stream>Single spatial stream 82 <enum 1 2_spatial_streams>2 spatial streams 83 <enum 2 3_spatial_streams>3 spatial streams 84 <enum 3 4_spatial_streams>4 spatial streams 85 <enum 4 5_spatial_streams>5 spatial streams 86 <enum 5 6_spatial_streams>6 spatial streams 87 <enum 6 7_spatial_streams>7 spatial streams 88 <enum 7 8_spatial_streams>8 spatial streams 89 */ 90 91 #define HE_SIG_B2_OFDMA_INFO_NSTS_OFFSET 0x00000000 92 #define HE_SIG_B2_OFDMA_INFO_NSTS_LSB 11 93 #define HE_SIG_B2_OFDMA_INFO_NSTS_MSB 13 94 #define HE_SIG_B2_OFDMA_INFO_NSTS_MASK 0x00003800 95 96 97 /* Description TXBF 98 99 Indicates whether beamforming is applied 100 0: No beamforming 101 1: beamforming 102 <legal all> 103 */ 104 105 #define HE_SIG_B2_OFDMA_INFO_TXBF_OFFSET 0x00000000 106 #define HE_SIG_B2_OFDMA_INFO_TXBF_LSB 14 107 #define HE_SIG_B2_OFDMA_INFO_TXBF_MSB 14 108 #define HE_SIG_B2_OFDMA_INFO_TXBF_MASK 0x00004000 109 110 111 /* Description STA_MCS 112 113 Indicates the data MCS 114 */ 115 116 #define HE_SIG_B2_OFDMA_INFO_STA_MCS_OFFSET 0x00000000 117 #define HE_SIG_B2_OFDMA_INFO_STA_MCS_LSB 15 118 #define HE_SIG_B2_OFDMA_INFO_STA_MCS_MSB 18 119 #define HE_SIG_B2_OFDMA_INFO_STA_MCS_MASK 0x00078000 120 121 122 /* Description STA_DCM 123 124 Indicates whether dual sub-carrier modulation is applied 125 126 0: No DCM 127 1:DCM 128 <legal all> 129 */ 130 131 #define HE_SIG_B2_OFDMA_INFO_STA_DCM_OFFSET 0x00000000 132 #define HE_SIG_B2_OFDMA_INFO_STA_DCM_LSB 19 133 #define HE_SIG_B2_OFDMA_INFO_STA_DCM_MSB 19 134 #define HE_SIG_B2_OFDMA_INFO_STA_DCM_MASK 0x00080000 135 136 137 /* Description STA_CODING 138 139 Distinguishes between BCC/LDPC 140 141 0: BCC 142 1: LDPC 143 <legal all> 144 */ 145 146 #define HE_SIG_B2_OFDMA_INFO_STA_CODING_OFFSET 0x00000000 147 #define HE_SIG_B2_OFDMA_INFO_STA_CODING_LSB 20 148 #define HE_SIG_B2_OFDMA_INFO_STA_CODING_MSB 20 149 #define HE_SIG_B2_OFDMA_INFO_STA_CODING_MASK 0x00100000 150 151 152 /* Description RESERVED_0 153 154 <legal 0> 155 */ 156 157 #define HE_SIG_B2_OFDMA_INFO_RESERVED_0_OFFSET 0x00000000 158 #define HE_SIG_B2_OFDMA_INFO_RESERVED_0_LSB 21 159 #define HE_SIG_B2_OFDMA_INFO_RESERVED_0_MSB 30 160 #define HE_SIG_B2_OFDMA_INFO_RESERVED_0_MASK 0x7fe00000 161 162 163 /* Description RX_INTEGRITY_CHECK_PASSED 164 165 TX side: Set to 0 166 RX side: Set to 1 if PHY determines the CRC check of the 167 codeblock containing this HE-SIG-B user info has passed, 168 else set to 0 169 170 <legal all> 171 */ 172 173 #define HE_SIG_B2_OFDMA_INFO_RX_INTEGRITY_CHECK_PASSED_OFFSET 0x00000000 174 #define HE_SIG_B2_OFDMA_INFO_RX_INTEGRITY_CHECK_PASSED_LSB 31 175 #define HE_SIG_B2_OFDMA_INFO_RX_INTEGRITY_CHECK_PASSED_MSB 31 176 #define HE_SIG_B2_OFDMA_INFO_RX_INTEGRITY_CHECK_PASSED_MASK 0x80000000 177 178 179 /* Description USER_ORDER 180 181 RX side: Set to 0 182 TX side: Ordering index of the User field 183 Gaps between the ordering indices of User fields indicate 184 that the microcode shall generate "unallocated RU" User 185 fields (STAID=2046) to fill the gaps. 186 <legal all> 187 */ 188 189 #define HE_SIG_B2_OFDMA_INFO_USER_ORDER_OFFSET 0x00000004 190 #define HE_SIG_B2_OFDMA_INFO_USER_ORDER_LSB 0 191 #define HE_SIG_B2_OFDMA_INFO_USER_ORDER_MSB 7 192 #define HE_SIG_B2_OFDMA_INFO_USER_ORDER_MASK 0x000000ff 193 194 195 /* Description CC_MASK 196 197 RX side: Set to 0 198 TX side: Indicates what content channel this User field 199 can go to 200 Bit 0: content channel 0 201 Bit 1: content channel 1 202 The other bits are unused, but could repeat the above pattern 203 for compatibility with 'EHT_SIG_USR_OFDMA_INFO.' 204 <legal all> 205 */ 206 207 #define HE_SIG_B2_OFDMA_INFO_CC_MASK_OFFSET 0x00000004 208 #define HE_SIG_B2_OFDMA_INFO_CC_MASK_LSB 8 209 #define HE_SIG_B2_OFDMA_INFO_CC_MASK_MSB 15 210 #define HE_SIG_B2_OFDMA_INFO_CC_MASK_MASK 0x0000ff00 211 212 213 /* Description RESERVED_1A 214 215 <legal 0> 216 */ 217 218 #define HE_SIG_B2_OFDMA_INFO_RESERVED_1A_OFFSET 0x00000004 219 #define HE_SIG_B2_OFDMA_INFO_RESERVED_1A_LSB 16 220 #define HE_SIG_B2_OFDMA_INFO_RESERVED_1A_MSB 31 221 #define HE_SIG_B2_OFDMA_INFO_RESERVED_1A_MASK 0xffff0000 222 223 224 225 #endif // HE_SIG_B2_OFDMA_INFO 226