xref: /wlan-driver/fw-api/hw/qca6290/11ax/v2/he_sig_b2_ofdma_info.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
1 /*
2  * Copyright (c) 2016-2018 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 #ifndef _HE_SIG_B2_OFDMA_INFO_H_
20 #define _HE_SIG_B2_OFDMA_INFO_H_
21 #if !defined(__ASSEMBLER__)
22 #endif
23 
24 
25 // ################ START SUMMARY #################
26 //
27 //	Dword	Fields
28 //	0	sta_id[10:0], nsts[13:11], txbf[14], sta_mcs[18:15], sta_dcm[19], sta_coding[20], reserved_0[31:21]
29 //
30 // ################ END SUMMARY #################
31 
32 #define NUM_OF_DWORDS_HE_SIG_B2_OFDMA_INFO 1
33 
34 struct he_sig_b2_ofdma_info {
35              uint32_t sta_id                          : 11, //[10:0]
36                       nsts                            :  3, //[13:11]
37                       txbf                            :  1, //[14]
38                       sta_mcs                         :  4, //[18:15]
39                       sta_dcm                         :  1, //[19]
40                       sta_coding                      :  1, //[20]
41                       reserved_0                      : 11; //[31:21]
42 };
43 
44 /*
45 
46 sta_id
47 
48 			Identifies the STA that is addressed. Details of STA ID
49 			are TBD
50 
51 nsts
52 
53 			MAC RX side usage only:
54 
55 
56 
57 			Number of spatial streams for this user
58 
59 
60 
61 			<enum 0 1_spatial_stream>Single spatial stream
62 
63 			<enum 1 2_spatial_streams>2 spatial streams
64 
65 			<enum 2 3_spatial_streams>3 spatial streams
66 
67 			<enum 3 4_spatial_streams>4 spatial streams
68 
69 			<enum 4 5_spatial_streams>5 spatial streams
70 
71 			<enum 5 6_spatial_streams>6 spatial streams
72 
73 			<enum 6 7_spatial_streams>7 spatial streams
74 
75 			<enum 7 8_spatial_streams>8 spatial streams
76 
77 txbf
78 
79 			Indicates whether beamforming is applied
80 
81 			0: No beamforming
82 
83 			1: beamforming
84 
85 			<legal all>
86 
87 sta_mcs
88 
89 			Indicates the data MCS
90 
91 sta_dcm
92 
93 
94 			0: No DCM
95 
96 			1:DCM
97 
98 			<legal all>
99 
100 sta_coding
101 
102 			Distinguishes between BCC/LDPC
103 
104 
105 
106 			0: BCC
107 
108 			1: LDPC
109 
110 			<legal all>
111 
112 reserved_0
113 
114 			<legal 0>
115 */
116 
117 
118 /* Description		HE_SIG_B2_OFDMA_INFO_0_STA_ID
119 
120 			Identifies the STA that is addressed. Details of STA ID
121 			are TBD
122 */
123 #define HE_SIG_B2_OFDMA_INFO_0_STA_ID_OFFSET                         0x00000000
124 #define HE_SIG_B2_OFDMA_INFO_0_STA_ID_LSB                            0
125 #define HE_SIG_B2_OFDMA_INFO_0_STA_ID_MASK                           0x000007ff
126 
127 /* Description		HE_SIG_B2_OFDMA_INFO_0_NSTS
128 
129 			MAC RX side usage only:
130 
131 
132 
133 			Number of spatial streams for this user
134 
135 
136 
137 			<enum 0 1_spatial_stream>Single spatial stream
138 
139 			<enum 1 2_spatial_streams>2 spatial streams
140 
141 			<enum 2 3_spatial_streams>3 spatial streams
142 
143 			<enum 3 4_spatial_streams>4 spatial streams
144 
145 			<enum 4 5_spatial_streams>5 spatial streams
146 
147 			<enum 5 6_spatial_streams>6 spatial streams
148 
149 			<enum 6 7_spatial_streams>7 spatial streams
150 
151 			<enum 7 8_spatial_streams>8 spatial streams
152 */
153 #define HE_SIG_B2_OFDMA_INFO_0_NSTS_OFFSET                           0x00000000
154 #define HE_SIG_B2_OFDMA_INFO_0_NSTS_LSB                              11
155 #define HE_SIG_B2_OFDMA_INFO_0_NSTS_MASK                             0x00003800
156 
157 /* Description		HE_SIG_B2_OFDMA_INFO_0_TXBF
158 
159 			Indicates whether beamforming is applied
160 
161 			0: No beamforming
162 
163 			1: beamforming
164 
165 			<legal all>
166 */
167 #define HE_SIG_B2_OFDMA_INFO_0_TXBF_OFFSET                           0x00000000
168 #define HE_SIG_B2_OFDMA_INFO_0_TXBF_LSB                              14
169 #define HE_SIG_B2_OFDMA_INFO_0_TXBF_MASK                             0x00004000
170 
171 /* Description		HE_SIG_B2_OFDMA_INFO_0_STA_MCS
172 
173 			Indicates the data MCS
174 */
175 #define HE_SIG_B2_OFDMA_INFO_0_STA_MCS_OFFSET                        0x00000000
176 #define HE_SIG_B2_OFDMA_INFO_0_STA_MCS_LSB                           15
177 #define HE_SIG_B2_OFDMA_INFO_0_STA_MCS_MASK                          0x00078000
178 
179 /* Description		HE_SIG_B2_OFDMA_INFO_0_STA_DCM
180 
181 
182 			0: No DCM
183 
184 			1:DCM
185 
186 			<legal all>
187 */
188 #define HE_SIG_B2_OFDMA_INFO_0_STA_DCM_OFFSET                        0x00000000
189 #define HE_SIG_B2_OFDMA_INFO_0_STA_DCM_LSB                           19
190 #define HE_SIG_B2_OFDMA_INFO_0_STA_DCM_MASK                          0x00080000
191 
192 /* Description		HE_SIG_B2_OFDMA_INFO_0_STA_CODING
193 
194 			Distinguishes between BCC/LDPC
195 
196 
197 
198 			0: BCC
199 
200 			1: LDPC
201 
202 			<legal all>
203 */
204 #define HE_SIG_B2_OFDMA_INFO_0_STA_CODING_OFFSET                     0x00000000
205 #define HE_SIG_B2_OFDMA_INFO_0_STA_CODING_LSB                        20
206 #define HE_SIG_B2_OFDMA_INFO_0_STA_CODING_MASK                       0x00100000
207 
208 /* Description		HE_SIG_B2_OFDMA_INFO_0_RESERVED_0
209 
210 			<legal 0>
211 */
212 #define HE_SIG_B2_OFDMA_INFO_0_RESERVED_0_OFFSET                     0x00000000
213 #define HE_SIG_B2_OFDMA_INFO_0_RESERVED_0_LSB                        21
214 #define HE_SIG_B2_OFDMA_INFO_0_RESERVED_0_MASK                       0xffe00000
215 
216 
217 #endif // _HE_SIG_B2_OFDMA_INFO_H_
218