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 _RX_LOCATION_INFO_H_ 27 #define _RX_LOCATION_INFO_H_ 28 #if !defined(__ASSEMBLER__) 29 #endif 30 31 #define NUM_OF_DWORDS_RX_LOCATION_INFO 28 32 33 34 struct rx_location_info { 35 #ifndef WIFI_BIT_ORDER_BIG_ENDIAN 36 uint32_t rx_location_info_valid : 1, // [0:0] 37 rtt_hw_ifft_mode : 1, // [1:1] 38 rtt_11az_mode : 2, // [3:2] 39 reserved_0 : 4, // [7:4] 40 rtt_num_fac : 8, // [15:8] 41 rtt_rx_chain_mask : 8, // [23:16] 42 rtt_num_streams : 8; // [31:24] 43 uint32_t rtt_first_selected_chain : 8, // [7:0] 44 rtt_second_selected_chain : 8, // [15:8] 45 rtt_cfr_status : 8, // [23:16] 46 rtt_cir_status : 8; // [31:24] 47 uint32_t rtt_che_buffer_pointer_low32 : 32; // [31:0] 48 uint32_t rtt_che_buffer_pointer_high8 : 8, // [7:0] 49 reserved_3 : 8, // [15:8] 50 rtt_pkt_bw_vht : 4, // [19:16] 51 rtt_pkt_bw_leg : 4, // [23:20] 52 rtt_mcs_rate : 8; // [31:24] 53 uint32_t rtt_cfo_measurement : 16, // [15:0] 54 rtt_preamble_type : 8, // [23:16] 55 rtt_gi_type : 8; // [31:24] 56 uint32_t rx_start_ts : 32; // [31:0] 57 uint32_t rx_start_ts_upper : 32; // [31:0] 58 uint32_t rx_end_ts : 32; // [31:0] 59 uint32_t gain_chain0 : 16, // [15:0] 60 gain_chain1 : 16; // [31:16] 61 uint32_t gain_chain2 : 16, // [15:0] 62 gain_chain3 : 16; // [31:16] 63 uint32_t gain_report_status : 8, // [7:0] 64 rtt_timing_backoff_sel : 8, // [15:8] 65 rtt_fac_combined : 16; // [31:16] 66 uint32_t rtt_fac_0 : 16, // [15:0] 67 rtt_fac_1 : 16; // [31:16] 68 uint32_t rtt_fac_2 : 16, // [15:0] 69 rtt_fac_3 : 16; // [31:16] 70 uint32_t rtt_fac_4 : 16, // [15:0] 71 rtt_fac_5 : 16; // [31:16] 72 uint32_t rtt_fac_6 : 16, // [15:0] 73 rtt_fac_7 : 16; // [31:16] 74 uint32_t rtt_fac_8 : 16, // [15:0] 75 rtt_fac_9 : 16; // [31:16] 76 uint32_t rtt_fac_10 : 16, // [15:0] 77 rtt_fac_11 : 16; // [31:16] 78 uint32_t rtt_fac_12 : 16, // [15:0] 79 rtt_fac_13 : 16; // [31:16] 80 uint32_t rtt_fac_14 : 16, // [15:0] 81 rtt_fac_15 : 16; // [31:16] 82 uint32_t rtt_fac_16 : 16, // [15:0] 83 rtt_fac_17 : 16; // [31:16] 84 uint32_t rtt_fac_18 : 16, // [15:0] 85 rtt_fac_19 : 16; // [31:16] 86 uint32_t rtt_fac_20 : 16, // [15:0] 87 rtt_fac_21 : 16; // [31:16] 88 uint32_t rtt_fac_22 : 16, // [15:0] 89 rtt_fac_23 : 16; // [31:16] 90 uint32_t rtt_fac_24 : 16, // [15:0] 91 rtt_fac_25 : 16; // [31:16] 92 uint32_t rtt_fac_26 : 16, // [15:0] 93 rtt_fac_27 : 16; // [31:16] 94 uint32_t rtt_fac_28 : 16, // [15:0] 95 rtt_fac_29 : 16; // [31:16] 96 uint32_t rtt_fac_30 : 16, // [15:0] 97 rtt_fac_31 : 16; // [31:16] 98 uint32_t reserved_27a : 32; // [31:0] 99 #else 100 uint32_t rtt_num_streams : 8, // [31:24] 101 rtt_rx_chain_mask : 8, // [23:16] 102 rtt_num_fac : 8, // [15:8] 103 reserved_0 : 4, // [7:4] 104 rtt_11az_mode : 2, // [3:2] 105 rtt_hw_ifft_mode : 1, // [1:1] 106 rx_location_info_valid : 1; // [0:0] 107 uint32_t rtt_cir_status : 8, // [31:24] 108 rtt_cfr_status : 8, // [23:16] 109 rtt_second_selected_chain : 8, // [15:8] 110 rtt_first_selected_chain : 8; // [7:0] 111 uint32_t rtt_che_buffer_pointer_low32 : 32; // [31:0] 112 uint32_t rtt_mcs_rate : 8, // [31:24] 113 rtt_pkt_bw_leg : 4, // [23:20] 114 rtt_pkt_bw_vht : 4, // [19:16] 115 reserved_3 : 8, // [15:8] 116 rtt_che_buffer_pointer_high8 : 8; // [7:0] 117 uint32_t rtt_gi_type : 8, // [31:24] 118 rtt_preamble_type : 8, // [23:16] 119 rtt_cfo_measurement : 16; // [15:0] 120 uint32_t rx_start_ts : 32; // [31:0] 121 uint32_t rx_start_ts_upper : 32; // [31:0] 122 uint32_t rx_end_ts : 32; // [31:0] 123 uint32_t gain_chain1 : 16, // [31:16] 124 gain_chain0 : 16; // [15:0] 125 uint32_t gain_chain3 : 16, // [31:16] 126 gain_chain2 : 16; // [15:0] 127 uint32_t rtt_fac_combined : 16, // [31:16] 128 rtt_timing_backoff_sel : 8, // [15:8] 129 gain_report_status : 8; // [7:0] 130 uint32_t rtt_fac_1 : 16, // [31:16] 131 rtt_fac_0 : 16; // [15:0] 132 uint32_t rtt_fac_3 : 16, // [31:16] 133 rtt_fac_2 : 16; // [15:0] 134 uint32_t rtt_fac_5 : 16, // [31:16] 135 rtt_fac_4 : 16; // [15:0] 136 uint32_t rtt_fac_7 : 16, // [31:16] 137 rtt_fac_6 : 16; // [15:0] 138 uint32_t rtt_fac_9 : 16, // [31:16] 139 rtt_fac_8 : 16; // [15:0] 140 uint32_t rtt_fac_11 : 16, // [31:16] 141 rtt_fac_10 : 16; // [15:0] 142 uint32_t rtt_fac_13 : 16, // [31:16] 143 rtt_fac_12 : 16; // [15:0] 144 uint32_t rtt_fac_15 : 16, // [31:16] 145 rtt_fac_14 : 16; // [15:0] 146 uint32_t rtt_fac_17 : 16, // [31:16] 147 rtt_fac_16 : 16; // [15:0] 148 uint32_t rtt_fac_19 : 16, // [31:16] 149 rtt_fac_18 : 16; // [15:0] 150 uint32_t rtt_fac_21 : 16, // [31:16] 151 rtt_fac_20 : 16; // [15:0] 152 uint32_t rtt_fac_23 : 16, // [31:16] 153 rtt_fac_22 : 16; // [15:0] 154 uint32_t rtt_fac_25 : 16, // [31:16] 155 rtt_fac_24 : 16; // [15:0] 156 uint32_t rtt_fac_27 : 16, // [31:16] 157 rtt_fac_26 : 16; // [15:0] 158 uint32_t rtt_fac_29 : 16, // [31:16] 159 rtt_fac_28 : 16; // [15:0] 160 uint32_t rtt_fac_31 : 16, // [31:16] 161 rtt_fac_30 : 16; // [15:0] 162 uint32_t reserved_27a : 32; // [31:0] 163 #endif 164 }; 165 166 167 /* Description RX_LOCATION_INFO_VALID 168 169 <enum 0 rx_location_info_is_not_valid> 170 <enum 1 rx_location_info_is_valid> 171 <legal all> 172 */ 173 174 #define RX_LOCATION_INFO_RX_LOCATION_INFO_VALID_OFFSET 0x00000000 175 #define RX_LOCATION_INFO_RX_LOCATION_INFO_VALID_LSB 0 176 #define RX_LOCATION_INFO_RX_LOCATION_INFO_VALID_MSB 0 177 #define RX_LOCATION_INFO_RX_LOCATION_INFO_VALID_MASK 0x00000001 178 179 180 /* Description RTT_HW_IFFT_MODE 181 182 Indicator showing if HW IFFT mode or SW IFFT mode 183 184 <enum 0 location_sw_ifft_mode> 185 <enum 1 location_hw_ifft_mode> 186 <legal all> 187 */ 188 189 #define RX_LOCATION_INFO_RTT_HW_IFFT_MODE_OFFSET 0x00000000 190 #define RX_LOCATION_INFO_RTT_HW_IFFT_MODE_LSB 1 191 #define RX_LOCATION_INFO_RTT_HW_IFFT_MODE_MSB 1 192 #define RX_LOCATION_INFO_RTT_HW_IFFT_MODE_MASK 0x00000002 193 194 195 /* Description RTT_11AZ_MODE 196 197 Indicator showing RTT5/.11mc or .11az mode for debug 198 199 <enum 0 location_rtt5_mode> legacy RTT5/.11mc mode 200 <enum 1 location_11az_ISTA> .11az ISTA location info. sent 201 on Rx path after receiving R2I LMR 202 <enum 2 location_RSVD> 203 <enum 3 location_11az_RSTA> .11az RSTA location info. sent 204 on Tx path after transmitting R2I LMR 205 <legal all> 206 */ 207 208 #define RX_LOCATION_INFO_RTT_11AZ_MODE_OFFSET 0x00000000 209 #define RX_LOCATION_INFO_RTT_11AZ_MODE_LSB 2 210 #define RX_LOCATION_INFO_RTT_11AZ_MODE_MSB 3 211 #define RX_LOCATION_INFO_RTT_11AZ_MODE_MASK 0x0000000c 212 213 214 /* Description RESERVED_0 215 216 <legal 0> 217 */ 218 219 #define RX_LOCATION_INFO_RESERVED_0_OFFSET 0x00000000 220 #define RX_LOCATION_INFO_RESERVED_0_LSB 4 221 #define RX_LOCATION_INFO_RESERVED_0_MSB 7 222 #define RX_LOCATION_INFO_RESERVED_0_MASK 0x000000f0 223 224 225 /* Description RTT_NUM_FAC 226 227 Number of valid first arrival correction (FAC) values (in 228 fields rtt_fac_0 - rtt_fac_31) 229 <legal 0-32> 230 */ 231 232 #define RX_LOCATION_INFO_RTT_NUM_FAC_OFFSET 0x00000000 233 #define RX_LOCATION_INFO_RTT_NUM_FAC_LSB 8 234 #define RX_LOCATION_INFO_RTT_NUM_FAC_MSB 15 235 #define RX_LOCATION_INFO_RTT_NUM_FAC_MASK 0x0000ff00 236 237 238 /* Description RTT_RX_CHAIN_MASK 239 240 Rx chain mask, each bit is a Rx chain 241 0: the Rx chain is not used 242 1: the Rx chain is used 243 244 Up to 4 Rx chains are supported. 245 246 <legal all> 247 */ 248 249 #define RX_LOCATION_INFO_RTT_RX_CHAIN_MASK_OFFSET 0x00000000 250 #define RX_LOCATION_INFO_RTT_RX_CHAIN_MASK_LSB 16 251 #define RX_LOCATION_INFO_RTT_RX_CHAIN_MASK_MSB 23 252 #define RX_LOCATION_INFO_RTT_RX_CHAIN_MASK_MASK 0x00ff0000 253 254 255 /* Description RTT_NUM_STREAMS 256 257 Number of streams used 258 259 Up to 8 streams are supported. 260 261 <legal 0-8> 262 */ 263 264 #define RX_LOCATION_INFO_RTT_NUM_STREAMS_OFFSET 0x00000000 265 #define RX_LOCATION_INFO_RTT_NUM_STREAMS_LSB 24 266 #define RX_LOCATION_INFO_RTT_NUM_STREAMS_MSB 31 267 #define RX_LOCATION_INFO_RTT_NUM_STREAMS_MASK 0xff000000 268 269 270 /* Description RTT_FIRST_SELECTED_CHAIN 271 272 For legacy RTT5/.11mc mode, this field shows the first selected 273 Rx chain that is used for FAC calculations, when forced 274 by a virtual register. 275 276 <enum 0 location_selected_chain_is_0> 277 <enum 1 location_selected_chain_is_1> 278 <enum 2 location_selected_chain_is_2> 279 <enum 3 location_selected_chain_is_3> 280 <legal 0-3> 281 */ 282 283 #define RX_LOCATION_INFO_RTT_FIRST_SELECTED_CHAIN_OFFSET 0x00000004 284 #define RX_LOCATION_INFO_RTT_FIRST_SELECTED_CHAIN_LSB 0 285 #define RX_LOCATION_INFO_RTT_FIRST_SELECTED_CHAIN_MSB 7 286 #define RX_LOCATION_INFO_RTT_FIRST_SELECTED_CHAIN_MASK 0x000000ff 287 288 289 /* Description RTT_SECOND_SELECTED_CHAIN 290 291 For legacy RTT5/.11mc mode, this field shows the second 292 selected Rx chain that is used for FAC calculations, when 293 forced by a virtual register. 294 295 <enum 0 location_selected_chain_is_0> 296 <enum 1 location_selected_chain_is_1> 297 <enum 2 location_selected_chain_is_2> 298 <enum 3 location_selected_chain_is_3> 299 <legal 0-3> 300 */ 301 302 #define RX_LOCATION_INFO_RTT_SECOND_SELECTED_CHAIN_OFFSET 0x00000004 303 #define RX_LOCATION_INFO_RTT_SECOND_SELECTED_CHAIN_LSB 8 304 #define RX_LOCATION_INFO_RTT_SECOND_SELECTED_CHAIN_MSB 15 305 #define RX_LOCATION_INFO_RTT_SECOND_SELECTED_CHAIN_MASK 0x0000ff00 306 307 308 /* Description RTT_CFR_STATUS 309 310 Status of channel frequency response dump 311 312 <enum 0 location_CFR_dump_not_valid> 313 <enum 1 location_CFR_dump_valid> 314 <legal 0-1> 315 */ 316 317 #define RX_LOCATION_INFO_RTT_CFR_STATUS_OFFSET 0x00000004 318 #define RX_LOCATION_INFO_RTT_CFR_STATUS_LSB 16 319 #define RX_LOCATION_INFO_RTT_CFR_STATUS_MSB 23 320 #define RX_LOCATION_INFO_RTT_CFR_STATUS_MASK 0x00ff0000 321 322 323 /* Description RTT_CIR_STATUS 324 325 Status of channel impulse response dump 326 327 <enum 0 location_CIR_dump_not_valid> 328 <enum 1 location_CIR_dump_valid> 329 <legal 0-1> 330 */ 331 332 #define RX_LOCATION_INFO_RTT_CIR_STATUS_OFFSET 0x00000004 333 #define RX_LOCATION_INFO_RTT_CIR_STATUS_LSB 24 334 #define RX_LOCATION_INFO_RTT_CIR_STATUS_MSB 31 335 #define RX_LOCATION_INFO_RTT_CIR_STATUS_MASK 0xff000000 336 337 338 /* Description RTT_CHE_BUFFER_POINTER_LOW32 339 340 The low 32 bits of the 40 bits pointer pointed to the external 341 RTT channel information buffer 342 <legal all> 343 */ 344 345 #define RX_LOCATION_INFO_RTT_CHE_BUFFER_POINTER_LOW32_OFFSET 0x00000008 346 #define RX_LOCATION_INFO_RTT_CHE_BUFFER_POINTER_LOW32_LSB 0 347 #define RX_LOCATION_INFO_RTT_CHE_BUFFER_POINTER_LOW32_MSB 31 348 #define RX_LOCATION_INFO_RTT_CHE_BUFFER_POINTER_LOW32_MASK 0xffffffff 349 350 351 /* Description RTT_CHE_BUFFER_POINTER_HIGH8 352 353 The high 8 bits of the 40 bits pointer pointed to the external 354 RTT channel information buffer 355 <legal all> 356 */ 357 358 #define RX_LOCATION_INFO_RTT_CHE_BUFFER_POINTER_HIGH8_OFFSET 0x0000000c 359 #define RX_LOCATION_INFO_RTT_CHE_BUFFER_POINTER_HIGH8_LSB 0 360 #define RX_LOCATION_INFO_RTT_CHE_BUFFER_POINTER_HIGH8_MSB 7 361 #define RX_LOCATION_INFO_RTT_CHE_BUFFER_POINTER_HIGH8_MASK 0x000000ff 362 363 364 /* Description RESERVED_3 365 366 <legal 0> 367 */ 368 369 #define RX_LOCATION_INFO_RESERVED_3_OFFSET 0x0000000c 370 #define RX_LOCATION_INFO_RESERVED_3_LSB 8 371 #define RX_LOCATION_INFO_RESERVED_3_MSB 15 372 #define RX_LOCATION_INFO_RESERVED_3_MASK 0x0000ff00 373 374 375 /* Description RTT_PKT_BW_VHT 376 377 Indicate the bandwidth of (V)HT/HE-LTF 378 379 <enum 0 location_pkt_bw_20MHz> 380 <enum 1 location_pkt_bw_40MHz> 381 <enum 2 location_pkt_bw_80MHz> 382 <enum 3 location_pkt_bw_160MHz> 383 <enum 4 location_pkt_bw_240MHz> Only valid for CFR, FAC 384 calculations are not PoR for 240 MHz. 385 <enum 5 location_pkt_bw_320MHz> Only valid for CFR, FAC 386 calculations are not PoR for 320 MHz. 387 <legal 0-5> 388 */ 389 390 #define RX_LOCATION_INFO_RTT_PKT_BW_VHT_OFFSET 0x0000000c 391 #define RX_LOCATION_INFO_RTT_PKT_BW_VHT_LSB 16 392 #define RX_LOCATION_INFO_RTT_PKT_BW_VHT_MSB 19 393 #define RX_LOCATION_INFO_RTT_PKT_BW_VHT_MASK 0x000f0000 394 395 396 /* Description RTT_PKT_BW_LEG 397 398 Indicate the bandwidth of L-LTF 399 400 <enum 0 location_pkt_bw_20MHz> 401 <enum 1 location_pkt_bw_40MHz> 402 <enum 2 location_pkt_bw_80MHz> 403 <enum 3 location_pkt_bw_160MHz> 404 <enum 4 location_pkt_bw_240MHz> Only valid for CFR, FAC 405 calculations are not PoR for 240 MHz. 406 <enum 5 location_pkt_bw_320MHz> Only valid for CFR, FAC 407 calculations are not PoR for 320 MHz. 408 <legal 0-5> 409 */ 410 411 #define RX_LOCATION_INFO_RTT_PKT_BW_LEG_OFFSET 0x0000000c 412 #define RX_LOCATION_INFO_RTT_PKT_BW_LEG_LSB 20 413 #define RX_LOCATION_INFO_RTT_PKT_BW_LEG_MSB 23 414 #define RX_LOCATION_INFO_RTT_PKT_BW_LEG_MASK 0x00f00000 415 416 417 /* Description RTT_MCS_RATE 418 419 Bits 0~4 indicate MCS rate, if Legacy, 420 0: 48 Mbps, 421 1: 24 Mbps, 422 2: 12 Mbps, 423 3: 6 Mbps, 424 4: 54 Mbps, 425 5: 36 Mbps, 426 6: 18 Mbps, 427 7: 9 Mbps, 428 8-15: reserved 429 430 if HT, 0-7: MCS0-MCS7, 8-15: reserved, 431 if VHT, 0-9: MCS0-MCS9, 10-15: reserved, 432 if HE or EHT, 0-11: MCS0-MCS11, 12-13: 4096QAM, 14-15: reserved 433 434 <legal all> 435 */ 436 437 #define RX_LOCATION_INFO_RTT_MCS_RATE_OFFSET 0x0000000c 438 #define RX_LOCATION_INFO_RTT_MCS_RATE_LSB 24 439 #define RX_LOCATION_INFO_RTT_MCS_RATE_MSB 31 440 #define RX_LOCATION_INFO_RTT_MCS_RATE_MASK 0xff000000 441 442 443 /* Description RTT_CFO_MEASUREMENT 444 445 CFO measurement. Needed for passive locationing 446 447 14 bits, signed 1.13. 13 bits fraction to provide a resolution 448 of 153 Hz 449 450 In units of cycles/800 ns 451 <legal 0-16383> 452 */ 453 454 #define RX_LOCATION_INFO_RTT_CFO_MEASUREMENT_OFFSET 0x00000010 455 #define RX_LOCATION_INFO_RTT_CFO_MEASUREMENT_LSB 0 456 #define RX_LOCATION_INFO_RTT_CFO_MEASUREMENT_MSB 15 457 #define RX_LOCATION_INFO_RTT_CFO_MEASUREMENT_MASK 0x0000ffff 458 459 460 /* Description RTT_PREAMBLE_TYPE 461 462 Indicate preamble type 463 464 <enum 0 location_preamble_type_legacy> 465 <enum 1 location_preamble_type_ht> 466 <enum 2 location_preamble_type_vht> 467 <enum 3 location_preamble_type_he_su_4xltf> 468 <enum 4 location_preamble_type_he_su_2xltf> 469 <enum 5 location_preamble_type_he_su_1xltf> 470 <enum 6 location_preamble_type_he_trigger_based_ul_4xltf> 471 472 <enum 7 location_preamble_type_he_trigger_based_ul_2xltf> 473 474 <enum 8 location_preamble_type_he_trigger_based_ul_1xltf> 475 476 <enum 9 location_preamble_type_he_mu_4xltf> 477 <enum 10 location_preamble_type_he_mu_2xltf> 478 <enum 11 location_preamble_type_he_mu_1xltf> 479 <enum 12 location_preamble_type_he_extended_range_su_4xltf> 480 481 <enum 13 location_preamble_type_he_extended_range_su_2xltf> 482 483 <enum 14 location_preamble_type_he_extended_range_su_1xltf> 484 485 <legal 0-14> 486 */ 487 488 #define RX_LOCATION_INFO_RTT_PREAMBLE_TYPE_OFFSET 0x00000010 489 #define RX_LOCATION_INFO_RTT_PREAMBLE_TYPE_LSB 16 490 #define RX_LOCATION_INFO_RTT_PREAMBLE_TYPE_MSB 23 491 #define RX_LOCATION_INFO_RTT_PREAMBLE_TYPE_MASK 0x00ff0000 492 493 494 /* Description RTT_GI_TYPE 495 496 Indicate GI (guard interval) type 497 498 <enum 0 location_gi_0_8_us > HE related GI. Can also be 499 used for HE 500 <enum 1 location_gi_0_4_us > HE related GI. Can also be 501 used for HE 502 <enum 2 location_gi_1_6_us > HE related GI 503 <enum 3 location_gi_3_2_us > HE related GI 504 <legal 0 - 3> 505 */ 506 507 #define RX_LOCATION_INFO_RTT_GI_TYPE_OFFSET 0x00000010 508 #define RX_LOCATION_INFO_RTT_GI_TYPE_LSB 24 509 #define RX_LOCATION_INFO_RTT_GI_TYPE_MSB 31 510 #define RX_LOCATION_INFO_RTT_GI_TYPE_MASK 0xff000000 511 512 513 /* Description RX_START_TS 514 515 RX packet start timestamp lower 32 bits 516 517 It reports the time the first L-STF ADC sample arrived at 518 RX antenna. 519 520 The clock unit is 960MHz. 521 <legal all> 522 */ 523 524 #define RX_LOCATION_INFO_RX_START_TS_OFFSET 0x00000014 525 #define RX_LOCATION_INFO_RX_START_TS_LSB 0 526 #define RX_LOCATION_INFO_RX_START_TS_MSB 31 527 #define RX_LOCATION_INFO_RX_START_TS_MASK 0xffffffff 528 529 530 /* Description RX_START_TS_UPPER 531 532 RX packet start timestamp upper 32 bits 533 534 It reports the time the first L-STF ADC sample arrived at 535 RX antenna. 536 537 The clock unit is 960MHz. 538 <legal all> 539 */ 540 541 #define RX_LOCATION_INFO_RX_START_TS_UPPER_OFFSET 0x00000018 542 #define RX_LOCATION_INFO_RX_START_TS_UPPER_LSB 0 543 #define RX_LOCATION_INFO_RX_START_TS_UPPER_MSB 31 544 #define RX_LOCATION_INFO_RX_START_TS_UPPER_MASK 0xffffffff 545 546 547 /* Description RX_END_TS 548 549 RX packet end timestamp lower 32 bits 550 551 It reports the time the last symbol's last ADC sample arrived 552 at RX antenna. 553 554 The clock unit is 960MHz. Only 32 bits are reported. 555 <legal all> 556 */ 557 558 #define RX_LOCATION_INFO_RX_END_TS_OFFSET 0x0000001c 559 #define RX_LOCATION_INFO_RX_END_TS_LSB 0 560 #define RX_LOCATION_INFO_RX_END_TS_MSB 31 561 #define RX_LOCATION_INFO_RX_END_TS_MASK 0xffffffff 562 563 564 /* Description GAIN_CHAIN0 565 566 Reports the total gain in dB and the gain table index to 567 support angle of arrival for chain0 568 */ 569 570 #define RX_LOCATION_INFO_GAIN_CHAIN0_OFFSET 0x00000020 571 #define RX_LOCATION_INFO_GAIN_CHAIN0_LSB 0 572 #define RX_LOCATION_INFO_GAIN_CHAIN0_MSB 15 573 #define RX_LOCATION_INFO_GAIN_CHAIN0_MASK 0x0000ffff 574 575 576 /* Description GAIN_CHAIN1 577 578 Reports the total gain in dB and the gain table index to 579 support angle of arrival for chain1 580 */ 581 582 #define RX_LOCATION_INFO_GAIN_CHAIN1_OFFSET 0x00000020 583 #define RX_LOCATION_INFO_GAIN_CHAIN1_LSB 16 584 #define RX_LOCATION_INFO_GAIN_CHAIN1_MSB 31 585 #define RX_LOCATION_INFO_GAIN_CHAIN1_MASK 0xffff0000 586 587 588 /* Description GAIN_CHAIN2 589 590 Reports the total gain in dB and the gain table index to 591 support angle of arrival for chain2 592 */ 593 594 #define RX_LOCATION_INFO_GAIN_CHAIN2_OFFSET 0x00000024 595 #define RX_LOCATION_INFO_GAIN_CHAIN2_LSB 0 596 #define RX_LOCATION_INFO_GAIN_CHAIN2_MSB 15 597 #define RX_LOCATION_INFO_GAIN_CHAIN2_MASK 0x0000ffff 598 599 600 /* Description GAIN_CHAIN3 601 602 Reports the total gain in dB and the gain table index to 603 support angle of arrival for chain3 604 */ 605 606 #define RX_LOCATION_INFO_GAIN_CHAIN3_OFFSET 0x00000024 607 #define RX_LOCATION_INFO_GAIN_CHAIN3_LSB 16 608 #define RX_LOCATION_INFO_GAIN_CHAIN3_MSB 31 609 #define RX_LOCATION_INFO_GAIN_CHAIN3_MASK 0xffff0000 610 611 612 /* Description GAIN_REPORT_STATUS 613 614 Number of valid gain reports (in fields gain_chain0 - gain_chain_3) 615 616 <legal 0-4> 617 */ 618 619 #define RX_LOCATION_INFO_GAIN_REPORT_STATUS_OFFSET 0x00000028 620 #define RX_LOCATION_INFO_GAIN_REPORT_STATUS_LSB 0 621 #define RX_LOCATION_INFO_GAIN_REPORT_STATUS_MSB 7 622 #define RX_LOCATION_INFO_GAIN_REPORT_STATUS_MASK 0x000000ff 623 624 625 /* Description RTT_TIMING_BACKOFF_SEL 626 627 Indicate which timing backoff value is used 628 629 <enum 0 timing_backoff_low_rssi> 630 <enum 1 timing_backoff_mid_rssi> 631 <enum 2 timing_backoff_high_rssi> 632 <enum 3 reserved> 633 <legal 0-3> 634 */ 635 636 #define RX_LOCATION_INFO_RTT_TIMING_BACKOFF_SEL_OFFSET 0x00000028 637 #define RX_LOCATION_INFO_RTT_TIMING_BACKOFF_SEL_LSB 8 638 #define RX_LOCATION_INFO_RTT_TIMING_BACKOFF_SEL_MSB 15 639 #define RX_LOCATION_INFO_RTT_TIMING_BACKOFF_SEL_MASK 0x0000ff00 640 641 642 /* Description RTT_FAC_COMBINED 643 644 Final adjusted and combined first arrival correction value 645 646 <legal all> 647 */ 648 649 #define RX_LOCATION_INFO_RTT_FAC_COMBINED_OFFSET 0x00000028 650 #define RX_LOCATION_INFO_RTT_FAC_COMBINED_LSB 16 651 #define RX_LOCATION_INFO_RTT_FAC_COMBINED_MSB 31 652 #define RX_LOCATION_INFO_RTT_FAC_COMBINED_MASK 0xffff0000 653 654 655 /* Description RTT_FAC_0 656 657 The fields 'rtt_fac_0' - 'rtt_fac_31' show the RTT first 658 arrival correction (FAC) value computed from the LTFs on 659 the selected Rx chains. 660 661 16 bits, signed 11.5. 11 integer bits to cover -3.2us to 662 3.2us, and 5 fraction bits to cover 160 MHz with 32x FAC 663 interpolation. 664 665 The clock unit is 320MHz. 666 667 For .11az/MIMO, the FACs will be stored in spatial stream 668 order with multiple chains reported together for each stream. [ss0-ch0, 669 ss0-ch1, ..., ss1-ch0, ss1-ch1, ...] 670 671 For legacy RTT5/.11mc, the FACs will be stored in preamble 672 order with multiple chains reported together for each LTF. [legacy-ch0, 673 legacy-ch1, ..., (v)ht/he-ch0, (v)ht/he-ch1, ...] 674 */ 675 676 #define RX_LOCATION_INFO_RTT_FAC_0_OFFSET 0x0000002c 677 #define RX_LOCATION_INFO_RTT_FAC_0_LSB 0 678 #define RX_LOCATION_INFO_RTT_FAC_0_MSB 15 679 #define RX_LOCATION_INFO_RTT_FAC_0_MASK 0x0000ffff 680 681 682 /* Description RTT_FAC_1 683 684 See 'rtt_fac_0' description 685 */ 686 687 #define RX_LOCATION_INFO_RTT_FAC_1_OFFSET 0x0000002c 688 #define RX_LOCATION_INFO_RTT_FAC_1_LSB 16 689 #define RX_LOCATION_INFO_RTT_FAC_1_MSB 31 690 #define RX_LOCATION_INFO_RTT_FAC_1_MASK 0xffff0000 691 692 693 /* Description RTT_FAC_2 694 695 See 'rtt_fac_0' description 696 */ 697 698 #define RX_LOCATION_INFO_RTT_FAC_2_OFFSET 0x00000030 699 #define RX_LOCATION_INFO_RTT_FAC_2_LSB 0 700 #define RX_LOCATION_INFO_RTT_FAC_2_MSB 15 701 #define RX_LOCATION_INFO_RTT_FAC_2_MASK 0x0000ffff 702 703 704 /* Description RTT_FAC_3 705 706 See 'rtt_fac_0' description 707 */ 708 709 #define RX_LOCATION_INFO_RTT_FAC_3_OFFSET 0x00000030 710 #define RX_LOCATION_INFO_RTT_FAC_3_LSB 16 711 #define RX_LOCATION_INFO_RTT_FAC_3_MSB 31 712 #define RX_LOCATION_INFO_RTT_FAC_3_MASK 0xffff0000 713 714 715 /* Description RTT_FAC_4 716 717 See 'rtt_fac_0' description 718 */ 719 720 #define RX_LOCATION_INFO_RTT_FAC_4_OFFSET 0x00000034 721 #define RX_LOCATION_INFO_RTT_FAC_4_LSB 0 722 #define RX_LOCATION_INFO_RTT_FAC_4_MSB 15 723 #define RX_LOCATION_INFO_RTT_FAC_4_MASK 0x0000ffff 724 725 726 /* Description RTT_FAC_5 727 728 See 'rtt_fac_0' description 729 */ 730 731 #define RX_LOCATION_INFO_RTT_FAC_5_OFFSET 0x00000034 732 #define RX_LOCATION_INFO_RTT_FAC_5_LSB 16 733 #define RX_LOCATION_INFO_RTT_FAC_5_MSB 31 734 #define RX_LOCATION_INFO_RTT_FAC_5_MASK 0xffff0000 735 736 737 /* Description RTT_FAC_6 738 739 See 'rtt_fac_0' description 740 */ 741 742 #define RX_LOCATION_INFO_RTT_FAC_6_OFFSET 0x00000038 743 #define RX_LOCATION_INFO_RTT_FAC_6_LSB 0 744 #define RX_LOCATION_INFO_RTT_FAC_6_MSB 15 745 #define RX_LOCATION_INFO_RTT_FAC_6_MASK 0x0000ffff 746 747 748 /* Description RTT_FAC_7 749 750 See 'rtt_fac_0' description 751 */ 752 753 #define RX_LOCATION_INFO_RTT_FAC_7_OFFSET 0x00000038 754 #define RX_LOCATION_INFO_RTT_FAC_7_LSB 16 755 #define RX_LOCATION_INFO_RTT_FAC_7_MSB 31 756 #define RX_LOCATION_INFO_RTT_FAC_7_MASK 0xffff0000 757 758 759 /* Description RTT_FAC_8 760 761 See 'rtt_fac_0' description 762 */ 763 764 #define RX_LOCATION_INFO_RTT_FAC_8_OFFSET 0x0000003c 765 #define RX_LOCATION_INFO_RTT_FAC_8_LSB 0 766 #define RX_LOCATION_INFO_RTT_FAC_8_MSB 15 767 #define RX_LOCATION_INFO_RTT_FAC_8_MASK 0x0000ffff 768 769 770 /* Description RTT_FAC_9 771 772 See 'rtt_fac_0' description 773 */ 774 775 #define RX_LOCATION_INFO_RTT_FAC_9_OFFSET 0x0000003c 776 #define RX_LOCATION_INFO_RTT_FAC_9_LSB 16 777 #define RX_LOCATION_INFO_RTT_FAC_9_MSB 31 778 #define RX_LOCATION_INFO_RTT_FAC_9_MASK 0xffff0000 779 780 781 /* Description RTT_FAC_10 782 783 See 'rtt_fac_0' description 784 */ 785 786 #define RX_LOCATION_INFO_RTT_FAC_10_OFFSET 0x00000040 787 #define RX_LOCATION_INFO_RTT_FAC_10_LSB 0 788 #define RX_LOCATION_INFO_RTT_FAC_10_MSB 15 789 #define RX_LOCATION_INFO_RTT_FAC_10_MASK 0x0000ffff 790 791 792 /* Description RTT_FAC_11 793 794 See 'rtt_fac_0' description 795 */ 796 797 #define RX_LOCATION_INFO_RTT_FAC_11_OFFSET 0x00000040 798 #define RX_LOCATION_INFO_RTT_FAC_11_LSB 16 799 #define RX_LOCATION_INFO_RTT_FAC_11_MSB 31 800 #define RX_LOCATION_INFO_RTT_FAC_11_MASK 0xffff0000 801 802 803 /* Description RTT_FAC_12 804 805 See 'rtt_fac_0' description 806 */ 807 808 #define RX_LOCATION_INFO_RTT_FAC_12_OFFSET 0x00000044 809 #define RX_LOCATION_INFO_RTT_FAC_12_LSB 0 810 #define RX_LOCATION_INFO_RTT_FAC_12_MSB 15 811 #define RX_LOCATION_INFO_RTT_FAC_12_MASK 0x0000ffff 812 813 814 /* Description RTT_FAC_13 815 816 See 'rtt_fac_0' description 817 */ 818 819 #define RX_LOCATION_INFO_RTT_FAC_13_OFFSET 0x00000044 820 #define RX_LOCATION_INFO_RTT_FAC_13_LSB 16 821 #define RX_LOCATION_INFO_RTT_FAC_13_MSB 31 822 #define RX_LOCATION_INFO_RTT_FAC_13_MASK 0xffff0000 823 824 825 /* Description RTT_FAC_14 826 827 See 'rtt_fac_0' description 828 */ 829 830 #define RX_LOCATION_INFO_RTT_FAC_14_OFFSET 0x00000048 831 #define RX_LOCATION_INFO_RTT_FAC_14_LSB 0 832 #define RX_LOCATION_INFO_RTT_FAC_14_MSB 15 833 #define RX_LOCATION_INFO_RTT_FAC_14_MASK 0x0000ffff 834 835 836 /* Description RTT_FAC_15 837 838 See 'rtt_fac_0' description 839 */ 840 841 #define RX_LOCATION_INFO_RTT_FAC_15_OFFSET 0x00000048 842 #define RX_LOCATION_INFO_RTT_FAC_15_LSB 16 843 #define RX_LOCATION_INFO_RTT_FAC_15_MSB 31 844 #define RX_LOCATION_INFO_RTT_FAC_15_MASK 0xffff0000 845 846 847 /* Description RTT_FAC_16 848 849 See 'rtt_fac_0' description 850 */ 851 852 #define RX_LOCATION_INFO_RTT_FAC_16_OFFSET 0x0000004c 853 #define RX_LOCATION_INFO_RTT_FAC_16_LSB 0 854 #define RX_LOCATION_INFO_RTT_FAC_16_MSB 15 855 #define RX_LOCATION_INFO_RTT_FAC_16_MASK 0x0000ffff 856 857 858 /* Description RTT_FAC_17 859 860 See 'rtt_fac_0' description 861 */ 862 863 #define RX_LOCATION_INFO_RTT_FAC_17_OFFSET 0x0000004c 864 #define RX_LOCATION_INFO_RTT_FAC_17_LSB 16 865 #define RX_LOCATION_INFO_RTT_FAC_17_MSB 31 866 #define RX_LOCATION_INFO_RTT_FAC_17_MASK 0xffff0000 867 868 869 /* Description RTT_FAC_18 870 871 See 'rtt_fac_0' description 872 */ 873 874 #define RX_LOCATION_INFO_RTT_FAC_18_OFFSET 0x00000050 875 #define RX_LOCATION_INFO_RTT_FAC_18_LSB 0 876 #define RX_LOCATION_INFO_RTT_FAC_18_MSB 15 877 #define RX_LOCATION_INFO_RTT_FAC_18_MASK 0x0000ffff 878 879 880 /* Description RTT_FAC_19 881 882 See 'rtt_fac_0' description 883 */ 884 885 #define RX_LOCATION_INFO_RTT_FAC_19_OFFSET 0x00000050 886 #define RX_LOCATION_INFO_RTT_FAC_19_LSB 16 887 #define RX_LOCATION_INFO_RTT_FAC_19_MSB 31 888 #define RX_LOCATION_INFO_RTT_FAC_19_MASK 0xffff0000 889 890 891 /* Description RTT_FAC_20 892 893 See 'rtt_fac_0' description 894 */ 895 896 #define RX_LOCATION_INFO_RTT_FAC_20_OFFSET 0x00000054 897 #define RX_LOCATION_INFO_RTT_FAC_20_LSB 0 898 #define RX_LOCATION_INFO_RTT_FAC_20_MSB 15 899 #define RX_LOCATION_INFO_RTT_FAC_20_MASK 0x0000ffff 900 901 902 /* Description RTT_FAC_21 903 904 See 'rtt_fac_0' description 905 */ 906 907 #define RX_LOCATION_INFO_RTT_FAC_21_OFFSET 0x00000054 908 #define RX_LOCATION_INFO_RTT_FAC_21_LSB 16 909 #define RX_LOCATION_INFO_RTT_FAC_21_MSB 31 910 #define RX_LOCATION_INFO_RTT_FAC_21_MASK 0xffff0000 911 912 913 /* Description RTT_FAC_22 914 915 See 'rtt_fac_0' description 916 */ 917 918 #define RX_LOCATION_INFO_RTT_FAC_22_OFFSET 0x00000058 919 #define RX_LOCATION_INFO_RTT_FAC_22_LSB 0 920 #define RX_LOCATION_INFO_RTT_FAC_22_MSB 15 921 #define RX_LOCATION_INFO_RTT_FAC_22_MASK 0x0000ffff 922 923 924 /* Description RTT_FAC_23 925 926 See 'rtt_fac_0' description 927 */ 928 929 #define RX_LOCATION_INFO_RTT_FAC_23_OFFSET 0x00000058 930 #define RX_LOCATION_INFO_RTT_FAC_23_LSB 16 931 #define RX_LOCATION_INFO_RTT_FAC_23_MSB 31 932 #define RX_LOCATION_INFO_RTT_FAC_23_MASK 0xffff0000 933 934 935 /* Description RTT_FAC_24 936 937 See 'rtt_fac_0' description 938 */ 939 940 #define RX_LOCATION_INFO_RTT_FAC_24_OFFSET 0x0000005c 941 #define RX_LOCATION_INFO_RTT_FAC_24_LSB 0 942 #define RX_LOCATION_INFO_RTT_FAC_24_MSB 15 943 #define RX_LOCATION_INFO_RTT_FAC_24_MASK 0x0000ffff 944 945 946 /* Description RTT_FAC_25 947 948 See 'rtt_fac_0' description 949 */ 950 951 #define RX_LOCATION_INFO_RTT_FAC_25_OFFSET 0x0000005c 952 #define RX_LOCATION_INFO_RTT_FAC_25_LSB 16 953 #define RX_LOCATION_INFO_RTT_FAC_25_MSB 31 954 #define RX_LOCATION_INFO_RTT_FAC_25_MASK 0xffff0000 955 956 957 /* Description RTT_FAC_26 958 959 See 'rtt_fac_0' description 960 */ 961 962 #define RX_LOCATION_INFO_RTT_FAC_26_OFFSET 0x00000060 963 #define RX_LOCATION_INFO_RTT_FAC_26_LSB 0 964 #define RX_LOCATION_INFO_RTT_FAC_26_MSB 15 965 #define RX_LOCATION_INFO_RTT_FAC_26_MASK 0x0000ffff 966 967 968 /* Description RTT_FAC_27 969 970 See 'rtt_fac_0' description 971 */ 972 973 #define RX_LOCATION_INFO_RTT_FAC_27_OFFSET 0x00000060 974 #define RX_LOCATION_INFO_RTT_FAC_27_LSB 16 975 #define RX_LOCATION_INFO_RTT_FAC_27_MSB 31 976 #define RX_LOCATION_INFO_RTT_FAC_27_MASK 0xffff0000 977 978 979 /* Description RTT_FAC_28 980 981 See 'rtt_fac_0' description 982 */ 983 984 #define RX_LOCATION_INFO_RTT_FAC_28_OFFSET 0x00000064 985 #define RX_LOCATION_INFO_RTT_FAC_28_LSB 0 986 #define RX_LOCATION_INFO_RTT_FAC_28_MSB 15 987 #define RX_LOCATION_INFO_RTT_FAC_28_MASK 0x0000ffff 988 989 990 /* Description RTT_FAC_29 991 992 See 'rtt_fac_0' description 993 */ 994 995 #define RX_LOCATION_INFO_RTT_FAC_29_OFFSET 0x00000064 996 #define RX_LOCATION_INFO_RTT_FAC_29_LSB 16 997 #define RX_LOCATION_INFO_RTT_FAC_29_MSB 31 998 #define RX_LOCATION_INFO_RTT_FAC_29_MASK 0xffff0000 999 1000 1001 /* Description RTT_FAC_30 1002 1003 See 'rtt_fac_0' description 1004 */ 1005 1006 #define RX_LOCATION_INFO_RTT_FAC_30_OFFSET 0x00000068 1007 #define RX_LOCATION_INFO_RTT_FAC_30_LSB 0 1008 #define RX_LOCATION_INFO_RTT_FAC_30_MSB 15 1009 #define RX_LOCATION_INFO_RTT_FAC_30_MASK 0x0000ffff 1010 1011 1012 /* Description RTT_FAC_31 1013 1014 See 'rtt_fac_0' description 1015 */ 1016 1017 #define RX_LOCATION_INFO_RTT_FAC_31_OFFSET 0x00000068 1018 #define RX_LOCATION_INFO_RTT_FAC_31_LSB 16 1019 #define RX_LOCATION_INFO_RTT_FAC_31_MSB 31 1020 #define RX_LOCATION_INFO_RTT_FAC_31_MASK 0xffff0000 1021 1022 1023 /* Description RESERVED_27A 1024 1025 <legal 0> 1026 */ 1027 1028 #define RX_LOCATION_INFO_RESERVED_27A_OFFSET 0x0000006c 1029 #define RX_LOCATION_INFO_RESERVED_27A_LSB 0 1030 #define RX_LOCATION_INFO_RESERVED_27A_MSB 31 1031 #define RX_LOCATION_INFO_RESERVED_27A_MASK 0xffffffff 1032 1033 1034 1035 #endif // RX_LOCATION_INFO 1036