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 _PDG_TX_REQ_H_ 27 #define _PDG_TX_REQ_H_ 28 #if !defined(__ASSEMBLER__) 29 #endif 30 31 #define NUM_OF_DWORDS_PDG_TX_REQ 2 32 33 #define NUM_OF_QWORDS_PDG_TX_REQ 1 34 35 36 struct pdg_tx_req { 37 #ifndef WIFI_BIT_ORDER_BIG_ENDIAN 38 uint32_t tx_reason : 2, 39 use_puncture_pattern : 2, 40 req_bw : 3, 41 puncture_pattern_number : 6, 42 reserved_0b : 1, 43 req_paprd : 1, 44 duration_field_boundary_valid : 1, 45 duration_field_boundary : 16; 46 uint32_t puncture_subband_mask : 16, 47 reserved_0c : 16; 48 #else 49 uint32_t duration_field_boundary : 16, 50 duration_field_boundary_valid : 1, 51 req_paprd : 1, 52 reserved_0b : 1, 53 puncture_pattern_number : 6, 54 req_bw : 3, 55 use_puncture_pattern : 2, 56 tx_reason : 2; 57 uint32_t reserved_0c : 16, 58 puncture_subband_mask : 16; 59 #endif 60 }; 61 62 63 64 65 #define PDG_TX_REQ_TX_REASON_OFFSET 0x0000000000000000 66 #define PDG_TX_REQ_TX_REASON_LSB 0 67 #define PDG_TX_REQ_TX_REASON_MSB 1 68 #define PDG_TX_REQ_TX_REASON_MASK 0x0000000000000003 69 70 71 72 73 #define PDG_TX_REQ_USE_PUNCTURE_PATTERN_OFFSET 0x0000000000000000 74 #define PDG_TX_REQ_USE_PUNCTURE_PATTERN_LSB 2 75 #define PDG_TX_REQ_USE_PUNCTURE_PATTERN_MSB 3 76 #define PDG_TX_REQ_USE_PUNCTURE_PATTERN_MASK 0x000000000000000c 77 78 79 80 81 #define PDG_TX_REQ_REQ_BW_OFFSET 0x0000000000000000 82 #define PDG_TX_REQ_REQ_BW_LSB 4 83 #define PDG_TX_REQ_REQ_BW_MSB 6 84 #define PDG_TX_REQ_REQ_BW_MASK 0x0000000000000070 85 86 87 88 89 #define PDG_TX_REQ_PUNCTURE_PATTERN_NUMBER_OFFSET 0x0000000000000000 90 #define PDG_TX_REQ_PUNCTURE_PATTERN_NUMBER_LSB 7 91 #define PDG_TX_REQ_PUNCTURE_PATTERN_NUMBER_MSB 12 92 #define PDG_TX_REQ_PUNCTURE_PATTERN_NUMBER_MASK 0x0000000000001f80 93 94 95 96 97 #define PDG_TX_REQ_RESERVED_0B_OFFSET 0x0000000000000000 98 #define PDG_TX_REQ_RESERVED_0B_LSB 13 99 #define PDG_TX_REQ_RESERVED_0B_MSB 13 100 #define PDG_TX_REQ_RESERVED_0B_MASK 0x0000000000002000 101 102 103 104 105 #define PDG_TX_REQ_REQ_PAPRD_OFFSET 0x0000000000000000 106 #define PDG_TX_REQ_REQ_PAPRD_LSB 14 107 #define PDG_TX_REQ_REQ_PAPRD_MSB 14 108 #define PDG_TX_REQ_REQ_PAPRD_MASK 0x0000000000004000 109 110 111 112 113 #define PDG_TX_REQ_DURATION_FIELD_BOUNDARY_VALID_OFFSET 0x0000000000000000 114 #define PDG_TX_REQ_DURATION_FIELD_BOUNDARY_VALID_LSB 15 115 #define PDG_TX_REQ_DURATION_FIELD_BOUNDARY_VALID_MSB 15 116 #define PDG_TX_REQ_DURATION_FIELD_BOUNDARY_VALID_MASK 0x0000000000008000 117 118 119 120 121 #define PDG_TX_REQ_DURATION_FIELD_BOUNDARY_OFFSET 0x0000000000000000 122 #define PDG_TX_REQ_DURATION_FIELD_BOUNDARY_LSB 16 123 #define PDG_TX_REQ_DURATION_FIELD_BOUNDARY_MSB 31 124 #define PDG_TX_REQ_DURATION_FIELD_BOUNDARY_MASK 0x00000000ffff0000 125 126 127 128 129 #define PDG_TX_REQ_PUNCTURE_SUBBAND_MASK_OFFSET 0x0000000000000000 130 #define PDG_TX_REQ_PUNCTURE_SUBBAND_MASK_LSB 32 131 #define PDG_TX_REQ_PUNCTURE_SUBBAND_MASK_MSB 47 132 #define PDG_TX_REQ_PUNCTURE_SUBBAND_MASK_MASK 0x0000ffff00000000 133 134 135 136 137 #define PDG_TX_REQ_RESERVED_0C_OFFSET 0x0000000000000000 138 #define PDG_TX_REQ_RESERVED_0C_LSB 48 139 #define PDG_TX_REQ_RESERVED_0C_MSB 63 140 #define PDG_TX_REQ_RESERVED_0C_MASK 0xffff000000000000 141 142 143 144 #endif 145