1 /* 2 * Copyright (c) 2020 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 // 20 // DO NOT EDIT! This file is automatically generated 21 // These definitions are tied to a particular hardware layout 22 23 24 #ifndef _RX_MPDU_LINK_PTR_H_ 25 #define _RX_MPDU_LINK_PTR_H_ 26 #if !defined(__ASSEMBLER__) 27 #endif 28 29 #include "buffer_addr_info.h" 30 31 // ################ START SUMMARY ################# 32 // 33 // Dword Fields 34 // 0-1 struct buffer_addr_info mpdu_link_desc_addr_info; 35 // 36 // ################ END SUMMARY ################# 37 38 #define NUM_OF_DWORDS_RX_MPDU_LINK_PTR 2 39 40 struct rx_mpdu_link_ptr { 41 struct buffer_addr_info mpdu_link_desc_addr_info; 42 }; 43 44 /* 45 46 struct buffer_addr_info mpdu_link_desc_addr_info 47 48 Details of the physical address of an MPDU link 49 descriptor 50 */ 51 52 53 /* EXTERNAL REFERENCE : struct buffer_addr_info mpdu_link_desc_addr_info */ 54 55 56 /* Description RX_MPDU_LINK_PTR_0_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_31_0 57 58 Address (lower 32 bits) of the MSDU buffer OR 59 MSDU_EXTENSION descriptor OR Link Descriptor 60 61 62 63 In case of 'NULL' pointer, this field is set to 0 64 65 <legal all> 66 */ 67 #define RX_MPDU_LINK_PTR_0_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_31_0_OFFSET 0x00000000 68 #define RX_MPDU_LINK_PTR_0_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_31_0_LSB 0 69 #define RX_MPDU_LINK_PTR_0_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_31_0_MASK 0xffffffff 70 71 /* Description RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_39_32 72 73 Address (upper 8 bits) of the MSDU buffer OR 74 MSDU_EXTENSION descriptor OR Link Descriptor 75 76 77 78 In case of 'NULL' pointer, this field is set to 0 79 80 <legal all> 81 */ 82 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_39_32_OFFSET 0x00000004 83 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_39_32_LSB 0 84 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_BUFFER_ADDR_39_32_MASK 0x000000ff 85 86 /* Description RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER 87 88 Consumer: WBM 89 90 Producer: SW/FW 91 92 93 94 In case of 'NULL' pointer, this field is set to 0 95 96 97 98 Indicates to which buffer manager the buffer OR 99 MSDU_EXTENSION descriptor OR link descriptor that is being 100 pointed to shall be returned after the frame has been 101 processed. It is used by WBM for routing purposes. 102 103 104 105 <enum 0 WBM_IDLE_BUF_LIST> This buffer shall be returned 106 to the WMB buffer idle list 107 108 <enum 1 WBM_IDLE_DESC_LIST> This buffer shall be 109 returned to the WMB idle link descriptor idle list 110 111 <enum 2 FW_BM> This buffer shall be returned to the FW 112 113 <enum 3 SW0_BM> This buffer shall be returned to the SW, 114 ring 0 115 116 <enum 4 SW1_BM> This buffer shall be returned to the SW, 117 ring 1 118 119 <enum 5 SW2_BM> This buffer shall be returned to the SW, 120 ring 2 121 122 <enum 6 SW3_BM> This buffer shall be returned to the SW, 123 ring 3 124 125 <enum 7 SW4_BM> This buffer shall be returned to the SW, 126 ring 4 127 128 129 130 <legal all> 131 */ 132 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_OFFSET 0x00000004 133 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_LSB 8 134 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_RETURN_BUFFER_MANAGER_MASK 0x00000700 135 136 /* Description RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_SW_BUFFER_COOKIE 137 138 Cookie field exclusively used by SW. 139 140 141 142 In case of 'NULL' pointer, this field is set to 0 143 144 145 146 HW ignores the contents, accept that it passes the 147 programmed value on to other descriptors together with the 148 physical address 149 150 151 152 Field can be used by SW to for example associate the 153 buffers physical address with the virtual address 154 155 The bit definitions as used by SW are within SW HLD 156 specification 157 158 159 160 NOTE: 161 162 The three most significant bits can have a special 163 meaning in case this struct is embedded in a TX_MPDU_DETAILS 164 STRUCT, and field transmit_bw_restriction is set 165 166 167 168 In case of NON punctured transmission: 169 170 Sw_buffer_cookie[20:19] = 2'b00: 20 MHz TX only 171 172 Sw_buffer_cookie[20:19] = 2'b01: 40 MHz TX only 173 174 Sw_buffer_cookie[20:19] = 2'b10: 80 MHz TX only 175 176 Sw_buffer_cookie[20:19] = 2'b11: 160 MHz TX only 177 178 179 180 In case of punctured transmission: 181 182 Sw_buffer_cookie[20:18] = 3'b000: pattern 0 only 183 184 Sw_buffer_cookie[20:18] = 3'b001: pattern 1 only 185 186 Sw_buffer_cookie[20:18] = 3'b010: pattern 2 only 187 188 Sw_buffer_cookie[20:18] = 3'b011: pattern 3 only 189 190 Sw_buffer_cookie[20:18] = 3'b100: pattern 4 only 191 192 Sw_buffer_cookie[20:18] = 3'b101: pattern 5 only 193 194 Sw_buffer_cookie[20:18] = 3'b110: pattern 6 only 195 196 Sw_buffer_cookie[20:18] = 3'b111: pattern 7 only 197 198 199 200 Note: a punctured transmission is indicated by the 201 presence of TLV TX_PUNCTURE_SETUP embedded in the scheduler 202 TLV 203 204 205 206 <legal all> 207 */ 208 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_SW_BUFFER_COOKIE_OFFSET 0x00000004 209 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_SW_BUFFER_COOKIE_LSB 11 210 #define RX_MPDU_LINK_PTR_1_MPDU_LINK_DESC_ADDR_INFO_SW_BUFFER_COOKIE_MASK 0xfffff800 211 212 213 #endif // _RX_MPDU_LINK_PTR_H_ 214