xref: /wlan-driver/fw-api/hw/qca5332/vht_sig_b_mu160_info.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
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 _VHT_SIG_B_MU160_INFO_H_
27 #define _VHT_SIG_B_MU160_INFO_H_
28 #if !defined(__ASSEMBLER__)
29 #endif
30 
31 #define NUM_OF_DWORDS_VHT_SIG_B_MU160_INFO 8
32 
33 
34 struct vht_sig_b_mu160_info {
35 #ifndef WIFI_BIT_ORDER_BIG_ENDIAN
36              uint32_t length                                                  : 19, // [18:0]
37                       mcs                                                     :  4, // [22:19]
38                       tail                                                    :  6, // [28:23]
39                       reserved_0                                              :  3; // [31:29]
40              uint32_t length_copy_a                                           : 19, // [18:0]
41                       mcs_copy_a                                              :  4, // [22:19]
42                       tail_copy_a                                             :  6, // [28:23]
43                       reserved_1                                              :  3; // [31:29]
44              uint32_t length_copy_b                                           : 19, // [18:0]
45                       mcs_copy_b                                              :  4, // [22:19]
46                       tail_copy_b                                             :  6, // [28:23]
47                       reserved_2                                              :  3; // [31:29]
48              uint32_t length_copy_c                                           : 19, // [18:0]
49                       mcs_copy_c                                              :  4, // [22:19]
50                       tail_copy_c                                             :  6, // [28:23]
51                       reserved_3                                              :  3; // [31:29]
52              uint32_t length_copy_d                                           : 19, // [18:0]
53                       mcs_copy_d                                              :  4, // [22:19]
54                       tail_copy_d                                             :  6, // [28:23]
55                       reserved_4                                              :  3; // [31:29]
56              uint32_t length_copy_e                                           : 19, // [18:0]
57                       mcs_copy_e                                              :  4, // [22:19]
58                       tail_copy_e                                             :  6, // [28:23]
59                       reserved_5                                              :  3; // [31:29]
60              uint32_t length_copy_f                                           : 19, // [18:0]
61                       mcs_copy_f                                              :  4, // [22:19]
62                       tail_copy_f                                             :  6, // [28:23]
63                       mu_user_number                                          :  3; // [31:29]
64              uint32_t length_copy_g                                           : 19, // [18:0]
65                       mcs_copy_g                                              :  4, // [22:19]
66                       tail_copy_g                                             :  6, // [28:23]
67                       reserved_7                                              :  3; // [31:29]
68 #else
69              uint32_t reserved_0                                              :  3, // [31:29]
70                       tail                                                    :  6, // [28:23]
71                       mcs                                                     :  4, // [22:19]
72                       length                                                  : 19; // [18:0]
73              uint32_t reserved_1                                              :  3, // [31:29]
74                       tail_copy_a                                             :  6, // [28:23]
75                       mcs_copy_a                                              :  4, // [22:19]
76                       length_copy_a                                           : 19; // [18:0]
77              uint32_t reserved_2                                              :  3, // [31:29]
78                       tail_copy_b                                             :  6, // [28:23]
79                       mcs_copy_b                                              :  4, // [22:19]
80                       length_copy_b                                           : 19; // [18:0]
81              uint32_t reserved_3                                              :  3, // [31:29]
82                       tail_copy_c                                             :  6, // [28:23]
83                       mcs_copy_c                                              :  4, // [22:19]
84                       length_copy_c                                           : 19; // [18:0]
85              uint32_t reserved_4                                              :  3, // [31:29]
86                       tail_copy_d                                             :  6, // [28:23]
87                       mcs_copy_d                                              :  4, // [22:19]
88                       length_copy_d                                           : 19; // [18:0]
89              uint32_t reserved_5                                              :  3, // [31:29]
90                       tail_copy_e                                             :  6, // [28:23]
91                       mcs_copy_e                                              :  4, // [22:19]
92                       length_copy_e                                           : 19; // [18:0]
93              uint32_t mu_user_number                                          :  3, // [31:29]
94                       tail_copy_f                                             :  6, // [28:23]
95                       mcs_copy_f                                              :  4, // [22:19]
96                       length_copy_f                                           : 19; // [18:0]
97              uint32_t reserved_7                                              :  3, // [31:29]
98                       tail_copy_g                                             :  6, // [28:23]
99                       mcs_copy_g                                              :  4, // [22:19]
100                       length_copy_g                                           : 19; // [18:0]
101 #endif
102 };
103 
104 
105 /* Description		LENGTH
106 
107 			VHT-SIG-B Length (in units of 4 octets) = ceiling (LENGTH/4)
108 			 <legal all>
109 */
110 
111 #define VHT_SIG_B_MU160_INFO_LENGTH_OFFSET                                          0x00000000
112 #define VHT_SIG_B_MU160_INFO_LENGTH_LSB                                             0
113 #define VHT_SIG_B_MU160_INFO_LENGTH_MSB                                             18
114 #define VHT_SIG_B_MU160_INFO_LENGTH_MASK                                            0x0007ffff
115 
116 
117 /* Description		MCS
118 
119 			Modulation as described in vht_sig_a mcs field  <legal 0-11>
120 
121 */
122 
123 #define VHT_SIG_B_MU160_INFO_MCS_OFFSET                                             0x00000000
124 #define VHT_SIG_B_MU160_INFO_MCS_LSB                                                19
125 #define VHT_SIG_B_MU160_INFO_MCS_MSB                                                22
126 #define VHT_SIG_B_MU160_INFO_MCS_MASK                                               0x00780000
127 
128 
129 /* Description		TAIL
130 
131 			Used to terminate the trellis of the convolutional decoder.
132 
133 			Set to 0.  <legal 0>
134 */
135 
136 #define VHT_SIG_B_MU160_INFO_TAIL_OFFSET                                            0x00000000
137 #define VHT_SIG_B_MU160_INFO_TAIL_LSB                                               23
138 #define VHT_SIG_B_MU160_INFO_TAIL_MSB                                               28
139 #define VHT_SIG_B_MU160_INFO_TAIL_MASK                                              0x1f800000
140 
141 
142 /* Description		RESERVED_0
143 
144 			Not part of VHT-SIG-B.
145 			Reserved: Set to 0 and ignored on receive  <legal 0>
146 */
147 
148 #define VHT_SIG_B_MU160_INFO_RESERVED_0_OFFSET                                      0x00000000
149 #define VHT_SIG_B_MU160_INFO_RESERVED_0_LSB                                         29
150 #define VHT_SIG_B_MU160_INFO_RESERVED_0_MSB                                         31
151 #define VHT_SIG_B_MU160_INFO_RESERVED_0_MASK                                        0xe0000000
152 
153 
154 /* Description		LENGTH_COPY_A
155 
156 			Same as "length". This field is not valid for RX packets
157 			 <legal all>
158 */
159 
160 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_A_OFFSET                                   0x00000004
161 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_A_LSB                                      0
162 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_A_MSB                                      18
163 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_A_MASK                                     0x0007ffff
164 
165 
166 /* Description		MCS_COPY_A
167 
168 			Same as "mcs". This field is not valid for RX packets  <legal
169 			 0-11>
170 */
171 
172 #define VHT_SIG_B_MU160_INFO_MCS_COPY_A_OFFSET                                      0x00000004
173 #define VHT_SIG_B_MU160_INFO_MCS_COPY_A_LSB                                         19
174 #define VHT_SIG_B_MU160_INFO_MCS_COPY_A_MSB                                         22
175 #define VHT_SIG_B_MU160_INFO_MCS_COPY_A_MASK                                        0x00780000
176 
177 
178 /* Description		TAIL_COPY_A
179 
180 			Same as "tail". This field is not valid for RX packets  <legal
181 			 0>
182 */
183 
184 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_A_OFFSET                                     0x00000004
185 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_A_LSB                                        23
186 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_A_MSB                                        28
187 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_A_MASK                                       0x1f800000
188 
189 
190 /* Description		RESERVED_1
191 
192 			Not part of VHT-SIG-B.
193 			Reserved: Set to 0 and ignored on receive  <legal 0>
194 */
195 
196 #define VHT_SIG_B_MU160_INFO_RESERVED_1_OFFSET                                      0x00000004
197 #define VHT_SIG_B_MU160_INFO_RESERVED_1_LSB                                         29
198 #define VHT_SIG_B_MU160_INFO_RESERVED_1_MSB                                         31
199 #define VHT_SIG_B_MU160_INFO_RESERVED_1_MASK                                        0xe0000000
200 
201 
202 /* Description		LENGTH_COPY_B
203 
204 			Same as "length". This field is not valid for RX packets. <legal
205 			 all>
206 */
207 
208 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_B_OFFSET                                   0x00000008
209 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_B_LSB                                      0
210 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_B_MSB                                      18
211 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_B_MASK                                     0x0007ffff
212 
213 
214 /* Description		MCS_COPY_B
215 
216 			Same as "mcs". This field is not valid for RX packets.
217 
218 			<legal 0-11>
219 */
220 
221 #define VHT_SIG_B_MU160_INFO_MCS_COPY_B_OFFSET                                      0x00000008
222 #define VHT_SIG_B_MU160_INFO_MCS_COPY_B_LSB                                         19
223 #define VHT_SIG_B_MU160_INFO_MCS_COPY_B_MSB                                         22
224 #define VHT_SIG_B_MU160_INFO_MCS_COPY_B_MASK                                        0x00780000
225 
226 
227 /* Description		TAIL_COPY_B
228 
229 			Same as "tail". This field is not valid for RX packets.
230 			 <legal 0>
231 */
232 
233 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_B_OFFSET                                     0x00000008
234 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_B_LSB                                        23
235 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_B_MSB                                        28
236 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_B_MASK                                       0x1f800000
237 
238 
239 /* Description		RESERVED_2
240 
241 			Not part of VHT-SIG-B.
242 			Reserved: Set to 0 and ignored on receive  <legal 0>
243 */
244 
245 #define VHT_SIG_B_MU160_INFO_RESERVED_2_OFFSET                                      0x00000008
246 #define VHT_SIG_B_MU160_INFO_RESERVED_2_LSB                                         29
247 #define VHT_SIG_B_MU160_INFO_RESERVED_2_MSB                                         31
248 #define VHT_SIG_B_MU160_INFO_RESERVED_2_MASK                                        0xe0000000
249 
250 
251 /* Description		LENGTH_COPY_C
252 
253 			Same as "length". This field is not valid for RX packets. <legal
254 			 all>
255 */
256 
257 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_C_OFFSET                                   0x0000000c
258 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_C_LSB                                      0
259 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_C_MSB                                      18
260 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_C_MASK                                     0x0007ffff
261 
262 
263 /* Description		MCS_COPY_C
264 
265 			Same as "mcs". This field is not valid for RX packets.
266 
267 			<legal 0-11>
268 */
269 
270 #define VHT_SIG_B_MU160_INFO_MCS_COPY_C_OFFSET                                      0x0000000c
271 #define VHT_SIG_B_MU160_INFO_MCS_COPY_C_LSB                                         19
272 #define VHT_SIG_B_MU160_INFO_MCS_COPY_C_MSB                                         22
273 #define VHT_SIG_B_MU160_INFO_MCS_COPY_C_MASK                                        0x00780000
274 
275 
276 /* Description		TAIL_COPY_C
277 
278 			Same as "tail". This field is not valid for RX packets.
279 			 <legal 0>
280 */
281 
282 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_C_OFFSET                                     0x0000000c
283 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_C_LSB                                        23
284 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_C_MSB                                        28
285 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_C_MASK                                       0x1f800000
286 
287 
288 /* Description		RESERVED_3
289 
290 			Not part of VHT-SIG-B.
291 			Reserved: Set to 0 and ignored on receive  <legal 0>
292 */
293 
294 #define VHT_SIG_B_MU160_INFO_RESERVED_3_OFFSET                                      0x0000000c
295 #define VHT_SIG_B_MU160_INFO_RESERVED_3_LSB                                         29
296 #define VHT_SIG_B_MU160_INFO_RESERVED_3_MSB                                         31
297 #define VHT_SIG_B_MU160_INFO_RESERVED_3_MASK                                        0xe0000000
298 
299 
300 /* Description		LENGTH_COPY_D
301 
302 			Same as "length". This field is not valid for RX packets. <legal
303 			 all>
304 */
305 
306 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_D_OFFSET                                   0x00000010
307 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_D_LSB                                      0
308 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_D_MSB                                      18
309 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_D_MASK                                     0x0007ffff
310 
311 
312 /* Description		MCS_COPY_D
313 
314 			Same as "mcs". This field is not valid for RX packets.
315 
316 			<legal 0-11>
317 */
318 
319 #define VHT_SIG_B_MU160_INFO_MCS_COPY_D_OFFSET                                      0x00000010
320 #define VHT_SIG_B_MU160_INFO_MCS_COPY_D_LSB                                         19
321 #define VHT_SIG_B_MU160_INFO_MCS_COPY_D_MSB                                         22
322 #define VHT_SIG_B_MU160_INFO_MCS_COPY_D_MASK                                        0x00780000
323 
324 
325 /* Description		TAIL_COPY_D
326 
327 			Same as "tail". This field is not valid for RX packets.
328 			 <legal 0>
329 */
330 
331 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_D_OFFSET                                     0x00000010
332 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_D_LSB                                        23
333 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_D_MSB                                        28
334 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_D_MASK                                       0x1f800000
335 
336 
337 /* Description		RESERVED_4
338 
339 			Not part of VHT-SIG-B.
340 			Reserved: Set to 0 and ignored on receive  <legal 0>
341 */
342 
343 #define VHT_SIG_B_MU160_INFO_RESERVED_4_OFFSET                                      0x00000010
344 #define VHT_SIG_B_MU160_INFO_RESERVED_4_LSB                                         29
345 #define VHT_SIG_B_MU160_INFO_RESERVED_4_MSB                                         31
346 #define VHT_SIG_B_MU160_INFO_RESERVED_4_MASK                                        0xe0000000
347 
348 
349 /* Description		LENGTH_COPY_E
350 
351 			Same as "length". This field is not valid for RX packets. <legal
352 			 all>
353 */
354 
355 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_E_OFFSET                                   0x00000014
356 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_E_LSB                                      0
357 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_E_MSB                                      18
358 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_E_MASK                                     0x0007ffff
359 
360 
361 /* Description		MCS_COPY_E
362 
363 			Same as "mcs". This field is not valid for RX packets.
364 
365 			<legal 0-11>
366 */
367 
368 #define VHT_SIG_B_MU160_INFO_MCS_COPY_E_OFFSET                                      0x00000014
369 #define VHT_SIG_B_MU160_INFO_MCS_COPY_E_LSB                                         19
370 #define VHT_SIG_B_MU160_INFO_MCS_COPY_E_MSB                                         22
371 #define VHT_SIG_B_MU160_INFO_MCS_COPY_E_MASK                                        0x00780000
372 
373 
374 /* Description		TAIL_COPY_E
375 
376 			Same as "tail". This field is not valid for RX packets.
377 			 <legal 0>
378 */
379 
380 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_E_OFFSET                                     0x00000014
381 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_E_LSB                                        23
382 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_E_MSB                                        28
383 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_E_MASK                                       0x1f800000
384 
385 
386 /* Description		RESERVED_5
387 
388 			Not part of VHT-SIG-B.
389 			Reserved: Set to 0 and ignored on receive  <legal 0>
390 */
391 
392 #define VHT_SIG_B_MU160_INFO_RESERVED_5_OFFSET                                      0x00000014
393 #define VHT_SIG_B_MU160_INFO_RESERVED_5_LSB                                         29
394 #define VHT_SIG_B_MU160_INFO_RESERVED_5_MSB                                         31
395 #define VHT_SIG_B_MU160_INFO_RESERVED_5_MASK                                        0xe0000000
396 
397 
398 /* Description		LENGTH_COPY_F
399 
400 			Same as "length". This field is not valid for RX packets. <legal
401 			 all>
402 */
403 
404 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_F_OFFSET                                   0x00000018
405 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_F_LSB                                      0
406 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_F_MSB                                      18
407 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_F_MASK                                     0x0007ffff
408 
409 
410 /* Description		MCS_COPY_F
411 
412 			Same as "mcs". This field is not valid for RX packets.
413 
414 			<legal 0-11>
415 */
416 
417 #define VHT_SIG_B_MU160_INFO_MCS_COPY_F_OFFSET                                      0x00000018
418 #define VHT_SIG_B_MU160_INFO_MCS_COPY_F_LSB                                         19
419 #define VHT_SIG_B_MU160_INFO_MCS_COPY_F_MSB                                         22
420 #define VHT_SIG_B_MU160_INFO_MCS_COPY_F_MASK                                        0x00780000
421 
422 
423 /* Description		TAIL_COPY_F
424 
425 			Same as "tail". This field is not valid for RX packets.
426 			 <legal 0>
427 */
428 
429 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_F_OFFSET                                     0x00000018
430 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_F_LSB                                        23
431 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_F_MSB                                        28
432 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_F_MASK                                       0x1f800000
433 
434 
435 /* Description		MU_USER_NUMBER
436 
437 			Not part of VHT-SIG-B.
438 			Mapping from user number (BFer hardware specific) to mu_user_number.
439 			The reader is directed to the previous chapter (User Number)
440 			for a definition of the terms user and mu_user.   <legal
441 			 0-3>
442 */
443 
444 #define VHT_SIG_B_MU160_INFO_MU_USER_NUMBER_OFFSET                                  0x00000018
445 #define VHT_SIG_B_MU160_INFO_MU_USER_NUMBER_LSB                                     29
446 #define VHT_SIG_B_MU160_INFO_MU_USER_NUMBER_MSB                                     31
447 #define VHT_SIG_B_MU160_INFO_MU_USER_NUMBER_MASK                                    0xe0000000
448 
449 
450 /* Description		LENGTH_COPY_G
451 
452 			Same as "length". This field is not valid for RX packets. <legal
453 			 all>
454 */
455 
456 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_G_OFFSET                                   0x0000001c
457 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_G_LSB                                      0
458 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_G_MSB                                      18
459 #define VHT_SIG_B_MU160_INFO_LENGTH_COPY_G_MASK                                     0x0007ffff
460 
461 
462 /* Description		MCS_COPY_G
463 
464 			Same as "mcs". This field is not valid for RX packets.
465 
466 			<legal 0-11>
467 */
468 
469 #define VHT_SIG_B_MU160_INFO_MCS_COPY_G_OFFSET                                      0x0000001c
470 #define VHT_SIG_B_MU160_INFO_MCS_COPY_G_LSB                                         19
471 #define VHT_SIG_B_MU160_INFO_MCS_COPY_G_MSB                                         22
472 #define VHT_SIG_B_MU160_INFO_MCS_COPY_G_MASK                                        0x00780000
473 
474 
475 /* Description		TAIL_COPY_G
476 
477 			Same as "tail". This field is not valid for RX packets.
478 			 <legal 0>
479 */
480 
481 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_G_OFFSET                                     0x0000001c
482 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_G_LSB                                        23
483 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_G_MSB                                        28
484 #define VHT_SIG_B_MU160_INFO_TAIL_COPY_G_MASK                                       0x1f800000
485 
486 
487 /* Description		RESERVED_7
488 
489 			<legal 0>
490 */
491 
492 #define VHT_SIG_B_MU160_INFO_RESERVED_7_OFFSET                                      0x0000001c
493 #define VHT_SIG_B_MU160_INFO_RESERVED_7_LSB                                         29
494 #define VHT_SIG_B_MU160_INFO_RESERVED_7_MSB                                         31
495 #define VHT_SIG_B_MU160_INFO_RESERVED_7_MASK                                        0xe0000000
496 
497 
498 
499 #endif   // VHT_SIG_B_MU160_INFO
500