xref: /wlan-driver/fw-api/hw/qcn9000/tcl_data_cmd.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
1*5113495bSYour Name /*
2*5113495bSYour Name  * Copyright (c) 2019, The Linux Foundation. All rights reserved.
3*5113495bSYour Name  *
4*5113495bSYour Name  * Permission to use, copy, modify, and/or distribute this software for any
5*5113495bSYour Name  * purpose with or without fee is hereby granted, provided that the above
6*5113495bSYour Name  * copyright notice and this permission notice appear in all copies.
7*5113495bSYour Name  *
8*5113495bSYour Name  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9*5113495bSYour Name  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10*5113495bSYour Name  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11*5113495bSYour Name  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12*5113495bSYour Name  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13*5113495bSYour Name  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14*5113495bSYour Name  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15*5113495bSYour Name  */
16*5113495bSYour Name 
17*5113495bSYour Name #ifndef _TCL_DATA_CMD_H_
18*5113495bSYour Name #define _TCL_DATA_CMD_H_
19*5113495bSYour Name #if !defined(__ASSEMBLER__)
20*5113495bSYour Name #endif
21*5113495bSYour Name 
22*5113495bSYour Name #include "buffer_addr_info.h"
23*5113495bSYour Name 
24*5113495bSYour Name // ################ START SUMMARY #################
25*5113495bSYour Name //
26*5113495bSYour Name //	Dword	Fields
27*5113495bSYour Name //	0-1	struct buffer_addr_info buf_addr_info;
28*5113495bSYour Name //	2	buf_or_ext_desc_type[0], epd[1], encap_type[3:2], encrypt_type[7:4], src_buffer_swap[8], link_meta_swap[9], tqm_no_drop[10], reserved_2a[11], search_type[13:12], addrx_en[14], addry_en[15], tcl_cmd_number[31:16]
29*5113495bSYour Name //	3	data_length[15:0], ipv4_checksum_en[16], udp_over_ipv4_checksum_en[17], udp_over_ipv6_checksum_en[18], tcp_over_ipv4_checksum_en[19], tcp_over_ipv6_checksum_en[20], to_fw[21], reserved_3a[22], packet_offset[31:23]
30*5113495bSYour Name //	4	buffer_timestamp[18:0], buffer_timestamp_valid[19], reserved_4a[20], hlos_tid_overwrite[21], hlos_tid[25:22], lmac_id[27:26], reserved_4b[31:28]
31*5113495bSYour Name //	5	dscp_tid_table_num[5:0], search_index[25:6], cache_set_num[29:26], mesh_enable[31:30]
32*5113495bSYour Name //	6	reserved_6a[19:0], ring_id[27:20], looping_count[31:28]
33*5113495bSYour Name //
34*5113495bSYour Name // ################ END SUMMARY #################
35*5113495bSYour Name 
36*5113495bSYour Name #define NUM_OF_DWORDS_TCL_DATA_CMD 7
37*5113495bSYour Name 
38*5113495bSYour Name struct tcl_data_cmd {
39*5113495bSYour Name     struct            buffer_addr_info                       buf_addr_info;
40*5113495bSYour Name              uint32_t buf_or_ext_desc_type            :  1, //[0]
41*5113495bSYour Name                       epd                             :  1, //[1]
42*5113495bSYour Name                       encap_type                      :  2, //[3:2]
43*5113495bSYour Name                       encrypt_type                    :  4, //[7:4]
44*5113495bSYour Name                       src_buffer_swap                 :  1, //[8]
45*5113495bSYour Name                       link_meta_swap                  :  1, //[9]
46*5113495bSYour Name                       tqm_no_drop                     :  1, //[10]
47*5113495bSYour Name                       reserved_2a                     :  1, //[11]
48*5113495bSYour Name                       search_type                     :  2, //[13:12]
49*5113495bSYour Name                       addrx_en                        :  1, //[14]
50*5113495bSYour Name                       addry_en                        :  1, //[15]
51*5113495bSYour Name                       tcl_cmd_number                  : 16; //[31:16]
52*5113495bSYour Name              uint32_t data_length                     : 16, //[15:0]
53*5113495bSYour Name                       ipv4_checksum_en                :  1, //[16]
54*5113495bSYour Name                       udp_over_ipv4_checksum_en       :  1, //[17]
55*5113495bSYour Name                       udp_over_ipv6_checksum_en       :  1, //[18]
56*5113495bSYour Name                       tcp_over_ipv4_checksum_en       :  1, //[19]
57*5113495bSYour Name                       tcp_over_ipv6_checksum_en       :  1, //[20]
58*5113495bSYour Name                       to_fw                           :  1, //[21]
59*5113495bSYour Name                       reserved_3a                     :  1, //[22]
60*5113495bSYour Name                       packet_offset                   :  9; //[31:23]
61*5113495bSYour Name              uint32_t buffer_timestamp                : 19, //[18:0]
62*5113495bSYour Name                       buffer_timestamp_valid          :  1, //[19]
63*5113495bSYour Name                       reserved_4a                     :  1, //[20]
64*5113495bSYour Name                       hlos_tid_overwrite              :  1, //[21]
65*5113495bSYour Name                       hlos_tid                        :  4, //[25:22]
66*5113495bSYour Name                       lmac_id                         :  2, //[27:26]
67*5113495bSYour Name                       reserved_4b                     :  4; //[31:28]
68*5113495bSYour Name              uint32_t dscp_tid_table_num              :  6, //[5:0]
69*5113495bSYour Name                       search_index                    : 20, //[25:6]
70*5113495bSYour Name                       cache_set_num                   :  4, //[29:26]
71*5113495bSYour Name                       mesh_enable                     :  2; //[31:30]
72*5113495bSYour Name              uint32_t reserved_6a                     : 20, //[19:0]
73*5113495bSYour Name                       ring_id                         :  8, //[27:20]
74*5113495bSYour Name                       looping_count                   :  4; //[31:28]
75*5113495bSYour Name };
76*5113495bSYour Name 
77*5113495bSYour Name /*
78*5113495bSYour Name 
79*5113495bSYour Name struct buffer_addr_info buf_addr_info
80*5113495bSYour Name 
81*5113495bSYour Name 			Details of the physical address for a single buffer
82*5113495bSYour Name 
83*5113495bSYour Name 			It also contains return ownership info as well as some
84*5113495bSYour Name 			meta data for SW related to this buffer.
85*5113495bSYour Name 
86*5113495bSYour Name 
87*5113495bSYour Name 
88*5113495bSYour Name 			In case of Buf_or_ext_desc_type indicating
89*5113495bSYour Name 			'MSDU_buffer', this address indicates the start of the meta
90*5113495bSYour Name 			data that is preceding the actual packet data.
91*5113495bSYour Name 
92*5113495bSYour Name 			The start of the actual packet data is provided by
93*5113495bSYour Name 			field: Packet_offset
94*5113495bSYour Name 
95*5113495bSYour Name buf_or_ext_desc_type
96*5113495bSYour Name 
97*5113495bSYour Name 			<enum 0 MSDU_buffer> The address points to an MSDU
98*5113495bSYour Name 			buffer.
99*5113495bSYour Name 
100*5113495bSYour Name 			<enum 1 extension_descriptor> The address points to an
101*5113495bSYour Name 			MSDU link extension descriptor
102*5113495bSYour Name 
103*5113495bSYour Name 			< legal all>
104*5113495bSYour Name 
105*5113495bSYour Name epd
106*5113495bSYour Name 
107*5113495bSYour Name 			When this bit is set then input packet is an EPD type
108*5113495bSYour Name 
109*5113495bSYour Name 			<legal all>
110*5113495bSYour Name 
111*5113495bSYour Name encap_type
112*5113495bSYour Name 
113*5113495bSYour Name 			Indicates the encapsulation that HW will perform:
114*5113495bSYour Name 
115*5113495bSYour Name 			<enum 0 RAW> No encapsulation
116*5113495bSYour Name 
117*5113495bSYour Name 			<enum 1 Native_WiFi>
118*5113495bSYour Name 
119*5113495bSYour Name 			<enum 2 Ethernet> Ethernet 2 (DIX)  or 802.3 (uses
120*5113495bSYour Name 			SNAP/LLC)
121*5113495bSYour Name 
122*5113495bSYour Name 			<enum 3 802_3> DO NOT USE. Indicate Ethernet
123*5113495bSYour Name 
124*5113495bSYour Name 
125*5113495bSYour Name 
126*5113495bSYour Name 			Used by the OLE during encapsulation.
127*5113495bSYour Name 
128*5113495bSYour Name 			<legal all>
129*5113495bSYour Name 
130*5113495bSYour Name encrypt_type
131*5113495bSYour Name 
132*5113495bSYour Name 			Field only valid for encap_type: RAW
133*5113495bSYour Name 
134*5113495bSYour Name 
135*5113495bSYour Name 
136*5113495bSYour Name 			Indicates type of decrypt cipher used (as defined in the
137*5113495bSYour Name 			peer entry)
138*5113495bSYour Name 
139*5113495bSYour Name 			<enum 0 wep_40> WEP 40-bit
140*5113495bSYour Name 
141*5113495bSYour Name 			<enum 1 wep_104> WEP 104-bit
142*5113495bSYour Name 
143*5113495bSYour Name 			<enum 2 tkip_no_mic> TKIP without MIC
144*5113495bSYour Name 
145*5113495bSYour Name 			<enum 3 wep_128> WEP 128-bit
146*5113495bSYour Name 
147*5113495bSYour Name 			<enum 4 tkip_with_mic> TKIP with MIC
148*5113495bSYour Name 
149*5113495bSYour Name 			<enum 5 wapi> WAPI
150*5113495bSYour Name 
151*5113495bSYour Name 			<enum 6 aes_ccmp_128> AES CCMP 128
152*5113495bSYour Name 
153*5113495bSYour Name 			<enum 7 no_cipher> No crypto
154*5113495bSYour Name 
155*5113495bSYour Name 			<enum 8 aes_ccmp_256> AES CCMP 256
156*5113495bSYour Name 
157*5113495bSYour Name 			<enum 9 aes_gcmp_128> AES CCMP 128
158*5113495bSYour Name 
159*5113495bSYour Name 			<enum 10 aes_gcmp_256> AES CCMP 256
160*5113495bSYour Name 
161*5113495bSYour Name 			<enum 11 wapi_gcm_sm4> WAPI GCM SM4
162*5113495bSYour Name 
163*5113495bSYour Name 
164*5113495bSYour Name 
165*5113495bSYour Name 			<enum 12 wep_varied_width> DO not use... Only for higher
166*5113495bSYour Name 			layer modules..
167*5113495bSYour Name 
168*5113495bSYour Name 			<legal 0-12>
169*5113495bSYour Name 
170*5113495bSYour Name src_buffer_swap
171*5113495bSYour Name 
172*5113495bSYour Name 			Treats source memory (packet buffer) organization as
173*5113495bSYour Name 			big-endian. The packets are read and byte swapped.
174*5113495bSYour Name 
175*5113495bSYour Name 			1'b0: Source memory is little endian
176*5113495bSYour Name 
177*5113495bSYour Name 			1'b1: Source memory is big endian
178*5113495bSYour Name 
179*5113495bSYour Name 			<legal all>
180*5113495bSYour Name 
181*5113495bSYour Name link_meta_swap
182*5113495bSYour Name 
183*5113495bSYour Name 			Treats link descriptor and Metadata as big-endian. The
184*5113495bSYour Name 			link descriptor/Metadata is read and byte swapped.
185*5113495bSYour Name 
186*5113495bSYour Name 			1'b0: Memory is little endian
187*5113495bSYour Name 
188*5113495bSYour Name 			1'b1: Memory is big endian
189*5113495bSYour Name 
190*5113495bSYour Name 			<legal all>
191*5113495bSYour Name 
192*5113495bSYour Name tqm_no_drop
193*5113495bSYour Name 
194*5113495bSYour Name 			This bit is used to stop TQM from dropping MSDUs while
195*5113495bSYour Name 			adding them to MSDU flows1'b1: Do not drop MSDU when any of
196*5113495bSYour Name 			the threshold value is met while adding MSDU in a flow1'b1:
197*5113495bSYour Name 			Drop MSDU when any of the threshold value is met while
198*5113495bSYour Name 			adding MSDU in a flow
199*5113495bSYour Name 
200*5113495bSYour Name 			<legal all>
201*5113495bSYour Name 
202*5113495bSYour Name reserved_2a
203*5113495bSYour Name 
204*5113495bSYour Name 			<legal 0>
205*5113495bSYour Name 
206*5113495bSYour Name search_type
207*5113495bSYour Name 
208*5113495bSYour Name 			Search type select
209*5113495bSYour Name 
210*5113495bSYour Name 
211*5113495bSYour Name 
212*5113495bSYour Name 			<enum 0 Normal_search> Address and flow search will use
213*5113495bSYour Name 			packet contents
214*5113495bSYour Name 
215*5113495bSYour Name 			<enum 1 Index_based_address_search> Address search will
216*5113495bSYour Name 
217*5113495bSYour Name 			<enum 2 Index_based_flow_search> Flow search will use
218*5113495bSYour Name 			'search_index', and address search will use packet contents
219*5113495bSYour Name 
220*5113495bSYour Name 			<legal 0-2>
221*5113495bSYour Name 
222*5113495bSYour Name addrx_en
223*5113495bSYour Name 
224*5113495bSYour Name 			Address X search enable in ASE
225*5113495bSYour Name 
226*5113495bSYour Name 			1'b0: Search disable
227*5113495bSYour Name 
228*5113495bSYour Name 			1'b1: Search Enable
229*5113495bSYour Name 
230*5113495bSYour Name 			<legal all>
231*5113495bSYour Name 
232*5113495bSYour Name addry_en
233*5113495bSYour Name 
234*5113495bSYour Name 			Address Y search enable in ASE
235*5113495bSYour Name 
236*5113495bSYour Name 			1'b0: Search disable
237*5113495bSYour Name 
238*5113495bSYour Name 			1'b1: Search Enable
239*5113495bSYour Name 
240*5113495bSYour Name 			<legal all>
241*5113495bSYour Name 
242*5113495bSYour Name tcl_cmd_number
243*5113495bSYour Name 
244*5113495bSYour Name 			This number can be used by SW to track, identify and
245*5113495bSYour Name 			link the created commands with the command statuses
246*5113495bSYour Name 
247*5113495bSYour Name 
248*5113495bSYour Name 
249*5113495bSYour Name 			Is set to the value 'TCL_CMD_Number' of the related
250*5113495bSYour Name 			TCL_DATA command
251*5113495bSYour Name 
252*5113495bSYour Name 			<legal all>
253*5113495bSYour Name 
254*5113495bSYour Name data_length
255*5113495bSYour Name 
256*5113495bSYour Name 			Valid Data length in bytes.
257*5113495bSYour Name 
258*5113495bSYour Name 
259*5113495bSYour Name 
260*5113495bSYour Name 			MSDU length in case of direct descriptor.
261*5113495bSYour Name 
262*5113495bSYour Name 			Length of link extension descriptor in case of Link
263*5113495bSYour Name 			extension descriptor. This is used to know the size of
264*5113495bSYour Name 			Metadata.
265*5113495bSYour Name 
266*5113495bSYour Name 			<legal all>
267*5113495bSYour Name 
268*5113495bSYour Name ipv4_checksum_en
269*5113495bSYour Name 
270*5113495bSYour Name 			OLE related control
271*5113495bSYour Name 
272*5113495bSYour Name 			Enable IPv4 checksum replacement
273*5113495bSYour Name 
274*5113495bSYour Name udp_over_ipv4_checksum_en
275*5113495bSYour Name 
276*5113495bSYour Name 			OLE related control
277*5113495bSYour Name 
278*5113495bSYour Name 			Enable UDP over IPv4 checksum replacement.  UDP checksum
279*5113495bSYour Name 			over IPv4 is optional for TCP/IP stacks.
280*5113495bSYour Name 
281*5113495bSYour Name udp_over_ipv6_checksum_en
282*5113495bSYour Name 
283*5113495bSYour Name 			OLE related control
284*5113495bSYour Name 
285*5113495bSYour Name 			Enable UDP over IPv6 checksum replacement.  UDP checksum
286*5113495bSYour Name 			over IPv6 is mandatory for TCP/IP stacks.
287*5113495bSYour Name 
288*5113495bSYour Name tcp_over_ipv4_checksum_en
289*5113495bSYour Name 
290*5113495bSYour Name 			OLE related control
291*5113495bSYour Name 
292*5113495bSYour Name 			Enable TCP checksum over IPv4 replacement
293*5113495bSYour Name 
294*5113495bSYour Name tcp_over_ipv6_checksum_en
295*5113495bSYour Name 
296*5113495bSYour Name 			OLE related control
297*5113495bSYour Name 
298*5113495bSYour Name 			Enable TCP checksum over IPv6 replacement
299*5113495bSYour Name 
300*5113495bSYour Name to_fw
301*5113495bSYour Name 
302*5113495bSYour Name 			Forward packet to FW along with classification result.
303*5113495bSYour Name 			The packet will not be forward to TQM when this bit is set
304*5113495bSYour Name 
305*5113495bSYour Name 
306*5113495bSYour Name 
307*5113495bSYour Name 			1'b0: Use classification result to forward the packet.
308*5113495bSYour Name 
309*5113495bSYour Name 			1'b1: Override classification result and forward packet
310*5113495bSYour Name 			only to FW.
311*5113495bSYour Name 
312*5113495bSYour Name 			<legal all>
313*5113495bSYour Name 
314*5113495bSYour Name reserved_3a
315*5113495bSYour Name 
316*5113495bSYour Name 			<legal 0>
317*5113495bSYour Name 
318*5113495bSYour Name packet_offset
319*5113495bSYour Name 
320*5113495bSYour Name 			Packet offset from Metadata in case of direct buffer
321*5113495bSYour Name 			descriptor. This field is valid when Buf_or_ext_desc_type is
322*5113495bSYour Name 			reset(= 0).
323*5113495bSYour Name 
324*5113495bSYour Name 			<legal all>
325*5113495bSYour Name 
326*5113495bSYour Name buffer_timestamp
327*5113495bSYour Name 
328*5113495bSYour Name 			Field only valid when 'Buffer_timestamp_valid ' is set.
329*5113495bSYour Name 
330*5113495bSYour Name 
331*5113495bSYour Name 
332*5113495bSYour Name 			Frame system entrance timestamp. The timestamp is
333*5113495bSYour Name 			related to the global system timer
334*5113495bSYour Name 
335*5113495bSYour Name 
336*5113495bSYour Name 
337*5113495bSYour Name 			Generally the first module (SW, TCL or TQM). that sees
338*5113495bSYour Name 			this frame and this timestamp field is not valid, shall fill
339*5113495bSYour Name 			in this field.
340*5113495bSYour Name 
341*5113495bSYour Name 
342*5113495bSYour Name 
343*5113495bSYour Name 			Timestamp in units of 1024 us
344*5113495bSYour Name 
345*5113495bSYour Name buffer_timestamp_valid
346*5113495bSYour Name 
347*5113495bSYour Name 			When set, the Buffer_timestamp field contains valid
348*5113495bSYour Name 			info.
349*5113495bSYour Name 
350*5113495bSYour Name reserved_4a
351*5113495bSYour Name 
352*5113495bSYour Name 			<legal 0>
353*5113495bSYour Name 
354*5113495bSYour Name hlos_tid_overwrite
355*5113495bSYour Name 
356*5113495bSYour Name 			When set, TCL shall ignore the IP DSCP and VLAN PCP
357*5113495bSYour Name 			fields and use HLOS_TID as the final TID. Otherwise TCL
358*5113495bSYour Name 			shall consider the DSCP and PCP fields as well as HLOS_TID
359*5113495bSYour Name 			and choose a final TID based on the configured priority
360*5113495bSYour Name 
361*5113495bSYour Name 			<legal all>
362*5113495bSYour Name 
363*5113495bSYour Name hlos_tid
364*5113495bSYour Name 
365*5113495bSYour Name 			HLOS MSDU priority
366*5113495bSYour Name 
367*5113495bSYour Name 
368*5113495bSYour Name 
369*5113495bSYour Name 			Field is used when HLOS_TID_overwrite is set.
370*5113495bSYour Name 
371*5113495bSYour Name 
372*5113495bSYour Name 
373*5113495bSYour Name 			Field is also used when HLOS_TID_overwrite is not set
374*5113495bSYour Name 			and DSCP/PCP is not available in the packet
375*5113495bSYour Name 
376*5113495bSYour Name 			<legal all>
377*5113495bSYour Name 
378*5113495bSYour Name lmac_id
379*5113495bSYour Name 
380*5113495bSYour Name 			TCL uses this LMAC_ID in address search, i.e, while
381*5113495bSYour Name 			finding matching entry for the packet in AST corresponding
382*5113495bSYour Name 			to given LMAC_ID
383*5113495bSYour Name 
384*5113495bSYour Name 			If LMAC ID is all 1s (=> value 3), it indicates wildcard
385*5113495bSYour Name 			match for any MAC
386*5113495bSYour Name 
387*5113495bSYour Name 			<legal 0-3>
388*5113495bSYour Name 
389*5113495bSYour Name reserved_4b
390*5113495bSYour Name 
391*5113495bSYour Name 			<legal 0>
392*5113495bSYour Name 
393*5113495bSYour Name dscp_tid_table_num
394*5113495bSYour Name 
395*5113495bSYour Name 			DSCP to TID mapping table number that need to be used
396*5113495bSYour Name 			for the MSDU, should be specified using this field
397*5113495bSYour Name 
398*5113495bSYour Name 			<legal all>
399*5113495bSYour Name 
400*5113495bSYour Name search_index
401*5113495bSYour Name 
402*5113495bSYour Name 			The index that will be used for index based address or
403*5113495bSYour Name 			flow search. The field is valid when 'search_type' is  1 or
404*5113495bSYour Name 			2.
405*5113495bSYour Name 
406*5113495bSYour Name 			<legal all>
407*5113495bSYour Name 
408*5113495bSYour Name cache_set_num
409*5113495bSYour Name 
410*5113495bSYour Name 			Cache set number that should be used to cache the index
411*5113495bSYour Name 			based search results, for address and flow search. This
412*5113495bSYour Name 			value should be equal to LSB four bits of the hash value of
413*5113495bSYour Name 			match data, in case of search index points to an entry which
414*5113495bSYour Name 			may be used in content based search also. The value can be
415*5113495bSYour Name 			anything when the entry pointed by search index will not be
416*5113495bSYour Name 			used for content based search.
417*5113495bSYour Name 
418*5113495bSYour Name 			<legal all>
419*5113495bSYour Name 
420*5113495bSYour Name mesh_enable
421*5113495bSYour Name 
422*5113495bSYour Name 			If set to a non-zero value:
423*5113495bSYour Name 
424*5113495bSYour Name 			* For raw WiFi frames, this indicates transmission to a
425*5113495bSYour Name 			mesh STA, enabling the interpretation of the 'Mesh Control
426*5113495bSYour Name 			Present' bit (bit 8) of QoS Control (otherwise this bit is
427*5113495bSYour Name 			ignored). The interpretation of the A-MSDU 'Length' field is
428*5113495bSYour Name 			decided by the e-numerations below.
429*5113495bSYour Name 
430*5113495bSYour Name 			* For native WiFi frames, this indicates that a 'Mesh
431*5113495bSYour Name 			Control' field is present between the header and the LLC.
432*5113495bSYour Name 			The three non-zero values are interchangeable.
433*5113495bSYour Name 
434*5113495bSYour Name 
435*5113495bSYour Name 
436*5113495bSYour Name 			<enum 0 MESH_DISABLE>
437*5113495bSYour Name 
438*5113495bSYour Name 			<enum 1 MESH_Q2Q> A-MSDU 'Length' is big endian and
439*5113495bSYour Name 			includes the length of Mesh Control.
440*5113495bSYour Name 
441*5113495bSYour Name 			<enum 2 MESH_11S_BE> A-MSDU 'Length' is big endian and
442*5113495bSYour Name 			excludes the length of Mesh Control.
443*5113495bSYour Name 
444*5113495bSYour Name 			<enum 3 MESH_11S_LE> A-MSDU 'Length' is little endian
445*5113495bSYour Name 			and excludes the length of Mesh Control. This is
446*5113495bSYour Name 			802.11s-compliant.
447*5113495bSYour Name 
448*5113495bSYour Name reserved_6a
449*5113495bSYour Name 
450*5113495bSYour Name 			<legal 0>
451*5113495bSYour Name 
452*5113495bSYour Name ring_id
453*5113495bSYour Name 
454*5113495bSYour Name 			The buffer pointer ring ID.
455*5113495bSYour Name 
456*5113495bSYour Name 			0 refers to the IDLE ring
457*5113495bSYour Name 
458*5113495bSYour Name 			1 - N refers to other rings
459*5113495bSYour Name 
460*5113495bSYour Name 
461*5113495bSYour Name 
462*5113495bSYour Name 			Helps with debugging when dumping ring contents.
463*5113495bSYour Name 
464*5113495bSYour Name 			<legal all>
465*5113495bSYour Name 
466*5113495bSYour Name looping_count
467*5113495bSYour Name 
468*5113495bSYour Name 			A count value that indicates the number of times the
469*5113495bSYour Name 			producer of entries into the Ring has looped around the
470*5113495bSYour Name 			ring.
471*5113495bSYour Name 
472*5113495bSYour Name 			At initialization time, this value is set to 0. On the
473*5113495bSYour Name 			first loop, this value is set to 1. After the max value is
474*5113495bSYour Name 			reached allowed by the number of bits for this field, the
475*5113495bSYour Name 			count value continues with 0 again.
476*5113495bSYour Name 
477*5113495bSYour Name 
478*5113495bSYour Name 
479*5113495bSYour Name 			In case SW is the consumer of the ring entries, it can
480*5113495bSYour Name 			use this field to figure out up to where the producer of
481*5113495bSYour Name 			entries has created new entries. This eliminates the need to
482*5113495bSYour Name 			check where the head pointer' of the ring is located once
483*5113495bSYour Name 			the SW starts processing an interrupt indicating that new
484*5113495bSYour Name 			entries have been put into this ring...
485*5113495bSYour Name 
486*5113495bSYour Name 
487*5113495bSYour Name 
488*5113495bSYour Name 			Also note that SW if it wants only needs to look at the
489*5113495bSYour Name 			LSB bit of this count value.
490*5113495bSYour Name 
491*5113495bSYour Name 			<legal all>
492*5113495bSYour Name */
493*5113495bSYour Name 
494*5113495bSYour Name 
495*5113495bSYour Name  /* EXTERNAL REFERENCE : struct buffer_addr_info buf_addr_info */
496*5113495bSYour Name 
497*5113495bSYour Name 
498*5113495bSYour Name /* Description		TCL_DATA_CMD_0_BUF_ADDR_INFO_BUFFER_ADDR_31_0
499*5113495bSYour Name 
500*5113495bSYour Name 			Address (lower 32 bits) of the MSDU buffer OR
501*5113495bSYour Name 			MSDU_EXTENSION descriptor OR Link Descriptor
502*5113495bSYour Name 
503*5113495bSYour Name 
504*5113495bSYour Name 
505*5113495bSYour Name 			In case of 'NULL' pointer, this field is set to 0
506*5113495bSYour Name 
507*5113495bSYour Name 			<legal all>
508*5113495bSYour Name */
509*5113495bSYour Name #define TCL_DATA_CMD_0_BUF_ADDR_INFO_BUFFER_ADDR_31_0_OFFSET         0x00000000
510*5113495bSYour Name #define TCL_DATA_CMD_0_BUF_ADDR_INFO_BUFFER_ADDR_31_0_LSB            0
511*5113495bSYour Name #define TCL_DATA_CMD_0_BUF_ADDR_INFO_BUFFER_ADDR_31_0_MASK           0xffffffff
512*5113495bSYour Name 
513*5113495bSYour Name /* Description		TCL_DATA_CMD_1_BUF_ADDR_INFO_BUFFER_ADDR_39_32
514*5113495bSYour Name 
515*5113495bSYour Name 			Address (upper 8 bits) of the MSDU buffer OR
516*5113495bSYour Name 			MSDU_EXTENSION descriptor OR Link Descriptor
517*5113495bSYour Name 
518*5113495bSYour Name 
519*5113495bSYour Name 
520*5113495bSYour Name 			In case of 'NULL' pointer, this field is set to 0
521*5113495bSYour Name 
522*5113495bSYour Name 			<legal all>
523*5113495bSYour Name */
524*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_BUFFER_ADDR_39_32_OFFSET        0x00000004
525*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_BUFFER_ADDR_39_32_LSB           0
526*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_BUFFER_ADDR_39_32_MASK          0x000000ff
527*5113495bSYour Name 
528*5113495bSYour Name /* Description		TCL_DATA_CMD_1_BUF_ADDR_INFO_RETURN_BUFFER_MANAGER
529*5113495bSYour Name 
530*5113495bSYour Name 			Consumer: WBM
531*5113495bSYour Name 
532*5113495bSYour Name 			Producer: SW/FW
533*5113495bSYour Name 
534*5113495bSYour Name 
535*5113495bSYour Name 
536*5113495bSYour Name 			In case of 'NULL' pointer, this field is set to 0
537*5113495bSYour Name 
538*5113495bSYour Name 
539*5113495bSYour Name 
540*5113495bSYour Name 			Indicates to which buffer manager the buffer OR
541*5113495bSYour Name 			MSDU_EXTENSION descriptor OR link descriptor that is being
542*5113495bSYour Name 			pointed to shall be returned after the frame has been
543*5113495bSYour Name 			processed. It is used by WBM for routing purposes.
544*5113495bSYour Name 
545*5113495bSYour Name 
546*5113495bSYour Name 
547*5113495bSYour Name 			<enum 0 WBM_IDLE_BUF_LIST> This buffer shall be returned
548*5113495bSYour Name 			to the WMB buffer idle list
549*5113495bSYour Name 
550*5113495bSYour Name 			<enum 1 WBM_IDLE_DESC_LIST> This buffer shall be
551*5113495bSYour Name 			returned to the WMB idle link descriptor idle list
552*5113495bSYour Name 
553*5113495bSYour Name 			<enum 2 FW_BM> This buffer shall be returned to the FW
554*5113495bSYour Name 
555*5113495bSYour Name 			<enum 3 SW0_BM> This buffer shall be returned to the SW,
556*5113495bSYour Name 			ring 0
557*5113495bSYour Name 
558*5113495bSYour Name 			<enum 4 SW1_BM> This buffer shall be returned to the SW,
559*5113495bSYour Name 			ring 1
560*5113495bSYour Name 
561*5113495bSYour Name 			<enum 5 SW2_BM> This buffer shall be returned to the SW,
562*5113495bSYour Name 			ring 2
563*5113495bSYour Name 
564*5113495bSYour Name 			<enum 6 SW3_BM> This buffer shall be returned to the SW,
565*5113495bSYour Name 			ring 3
566*5113495bSYour Name 
567*5113495bSYour Name 			<enum 7 SW4_BM> This buffer shall be returned to the SW,
568*5113495bSYour Name 			ring 4
569*5113495bSYour Name 
570*5113495bSYour Name 
571*5113495bSYour Name 
572*5113495bSYour Name 			<legal all>
573*5113495bSYour Name */
574*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_RETURN_BUFFER_MANAGER_OFFSET    0x00000004
575*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_RETURN_BUFFER_MANAGER_LSB       8
576*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_RETURN_BUFFER_MANAGER_MASK      0x00000700
577*5113495bSYour Name 
578*5113495bSYour Name /* Description		TCL_DATA_CMD_1_BUF_ADDR_INFO_SW_BUFFER_COOKIE
579*5113495bSYour Name 
580*5113495bSYour Name 			Cookie field exclusively used by SW.
581*5113495bSYour Name 
582*5113495bSYour Name 
583*5113495bSYour Name 
584*5113495bSYour Name 			In case of 'NULL' pointer, this field is set to 0
585*5113495bSYour Name 
586*5113495bSYour Name 
587*5113495bSYour Name 
588*5113495bSYour Name 			HW ignores the contents, accept that it passes the
589*5113495bSYour Name 			programmed value on to other descriptors together with the
590*5113495bSYour Name 			physical address
591*5113495bSYour Name 
592*5113495bSYour Name 
593*5113495bSYour Name 
594*5113495bSYour Name 			Field can be used by SW to for example associate the
595*5113495bSYour Name 			buffers physical address with the virtual address
596*5113495bSYour Name 
597*5113495bSYour Name 			The bit definitions as used by SW are within SW HLD
598*5113495bSYour Name 			specification
599*5113495bSYour Name 
600*5113495bSYour Name 
601*5113495bSYour Name 
602*5113495bSYour Name 			NOTE:
603*5113495bSYour Name 
604*5113495bSYour Name 			The three most significant bits can have a special
605*5113495bSYour Name 			meaning in case this struct is embedded in a TX_MPDU_DETAILS
606*5113495bSYour Name 			STRUCT, and field transmit_bw_restriction is set
607*5113495bSYour Name 
608*5113495bSYour Name 
609*5113495bSYour Name 
610*5113495bSYour Name 			In case of NON punctured transmission:
611*5113495bSYour Name 
612*5113495bSYour Name 			Sw_buffer_cookie[20:19] = 2'b00: 20 MHz TX only
613*5113495bSYour Name 
614*5113495bSYour Name 			Sw_buffer_cookie[20:19] = 2'b01: 40 MHz TX only
615*5113495bSYour Name 
616*5113495bSYour Name 			Sw_buffer_cookie[20:19] = 2'b10: 80 MHz TX only
617*5113495bSYour Name 
618*5113495bSYour Name 			Sw_buffer_cookie[20:19] = 2'b11: 160 MHz TX only
619*5113495bSYour Name 
620*5113495bSYour Name 
621*5113495bSYour Name 
622*5113495bSYour Name 			In case of punctured transmission:
623*5113495bSYour Name 
624*5113495bSYour Name 			Sw_buffer_cookie[20:18] = 3'b000: pattern 0 only
625*5113495bSYour Name 
626*5113495bSYour Name 			Sw_buffer_cookie[20:18] = 3'b001: pattern 1 only
627*5113495bSYour Name 
628*5113495bSYour Name 			Sw_buffer_cookie[20:18] = 3'b010: pattern 2 only
629*5113495bSYour Name 
630*5113495bSYour Name 			Sw_buffer_cookie[20:18] = 3'b011: pattern 3 only
631*5113495bSYour Name 
632*5113495bSYour Name 			Sw_buffer_cookie[20:18] = 3'b100: pattern 4 only
633*5113495bSYour Name 
634*5113495bSYour Name 			Sw_buffer_cookie[20:18] = 3'b101: pattern 5 only
635*5113495bSYour Name 
636*5113495bSYour Name 			Sw_buffer_cookie[20:18] = 3'b110: pattern 6 only
637*5113495bSYour Name 
638*5113495bSYour Name 			Sw_buffer_cookie[20:18] = 3'b111: pattern 7 only
639*5113495bSYour Name 
640*5113495bSYour Name 
641*5113495bSYour Name 
642*5113495bSYour Name 			Note: a punctured transmission is indicated by the
643*5113495bSYour Name 			presence of TLV TX_PUNCTURE_SETUP embedded in the scheduler
644*5113495bSYour Name 			TLV
645*5113495bSYour Name 
646*5113495bSYour Name 
647*5113495bSYour Name 
648*5113495bSYour Name 			<legal all>
649*5113495bSYour Name */
650*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_SW_BUFFER_COOKIE_OFFSET         0x00000004
651*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_SW_BUFFER_COOKIE_LSB            11
652*5113495bSYour Name #define TCL_DATA_CMD_1_BUF_ADDR_INFO_SW_BUFFER_COOKIE_MASK           0xfffff800
653*5113495bSYour Name 
654*5113495bSYour Name /* Description		TCL_DATA_CMD_2_BUF_OR_EXT_DESC_TYPE
655*5113495bSYour Name 
656*5113495bSYour Name 			<enum 0 MSDU_buffer> The address points to an MSDU
657*5113495bSYour Name 			buffer.
658*5113495bSYour Name 
659*5113495bSYour Name 			<enum 1 extension_descriptor> The address points to an
660*5113495bSYour Name 			MSDU link extension descriptor
661*5113495bSYour Name 
662*5113495bSYour Name 			< legal all>
663*5113495bSYour Name */
664*5113495bSYour Name #define TCL_DATA_CMD_2_BUF_OR_EXT_DESC_TYPE_OFFSET                   0x00000008
665*5113495bSYour Name #define TCL_DATA_CMD_2_BUF_OR_EXT_DESC_TYPE_LSB                      0
666*5113495bSYour Name #define TCL_DATA_CMD_2_BUF_OR_EXT_DESC_TYPE_MASK                     0x00000001
667*5113495bSYour Name 
668*5113495bSYour Name /* Description		TCL_DATA_CMD_2_EPD
669*5113495bSYour Name 
670*5113495bSYour Name 			When this bit is set then input packet is an EPD type
671*5113495bSYour Name 
672*5113495bSYour Name 			<legal all>
673*5113495bSYour Name */
674*5113495bSYour Name #define TCL_DATA_CMD_2_EPD_OFFSET                                    0x00000008
675*5113495bSYour Name #define TCL_DATA_CMD_2_EPD_LSB                                       1
676*5113495bSYour Name #define TCL_DATA_CMD_2_EPD_MASK                                      0x00000002
677*5113495bSYour Name 
678*5113495bSYour Name /* Description		TCL_DATA_CMD_2_ENCAP_TYPE
679*5113495bSYour Name 
680*5113495bSYour Name 			Indicates the encapsulation that HW will perform:
681*5113495bSYour Name 
682*5113495bSYour Name 			<enum 0 RAW> No encapsulation
683*5113495bSYour Name 
684*5113495bSYour Name 			<enum 1 Native_WiFi>
685*5113495bSYour Name 
686*5113495bSYour Name 			<enum 2 Ethernet> Ethernet 2 (DIX)  or 802.3 (uses
687*5113495bSYour Name 			SNAP/LLC)
688*5113495bSYour Name 
689*5113495bSYour Name 			<enum 3 802_3> DO NOT USE. Indicate Ethernet
690*5113495bSYour Name 
691*5113495bSYour Name 
692*5113495bSYour Name 
693*5113495bSYour Name 			Used by the OLE during encapsulation.
694*5113495bSYour Name 
695*5113495bSYour Name 			<legal all>
696*5113495bSYour Name */
697*5113495bSYour Name #define TCL_DATA_CMD_2_ENCAP_TYPE_OFFSET                             0x00000008
698*5113495bSYour Name #define TCL_DATA_CMD_2_ENCAP_TYPE_LSB                                2
699*5113495bSYour Name #define TCL_DATA_CMD_2_ENCAP_TYPE_MASK                               0x0000000c
700*5113495bSYour Name 
701*5113495bSYour Name /* Description		TCL_DATA_CMD_2_ENCRYPT_TYPE
702*5113495bSYour Name 
703*5113495bSYour Name 			Field only valid for encap_type: RAW
704*5113495bSYour Name 
705*5113495bSYour Name 
706*5113495bSYour Name 
707*5113495bSYour Name 			Indicates type of decrypt cipher used (as defined in the
708*5113495bSYour Name 			peer entry)
709*5113495bSYour Name 
710*5113495bSYour Name 			<enum 0 wep_40> WEP 40-bit
711*5113495bSYour Name 
712*5113495bSYour Name 			<enum 1 wep_104> WEP 104-bit
713*5113495bSYour Name 
714*5113495bSYour Name 			<enum 2 tkip_no_mic> TKIP without MIC
715*5113495bSYour Name 
716*5113495bSYour Name 			<enum 3 wep_128> WEP 128-bit
717*5113495bSYour Name 
718*5113495bSYour Name 			<enum 4 tkip_with_mic> TKIP with MIC
719*5113495bSYour Name 
720*5113495bSYour Name 			<enum 5 wapi> WAPI
721*5113495bSYour Name 
722*5113495bSYour Name 			<enum 6 aes_ccmp_128> AES CCMP 128
723*5113495bSYour Name 
724*5113495bSYour Name 			<enum 7 no_cipher> No crypto
725*5113495bSYour Name 
726*5113495bSYour Name 			<enum 8 aes_ccmp_256> AES CCMP 256
727*5113495bSYour Name 
728*5113495bSYour Name 			<enum 9 aes_gcmp_128> AES CCMP 128
729*5113495bSYour Name 
730*5113495bSYour Name 			<enum 10 aes_gcmp_256> AES CCMP 256
731*5113495bSYour Name 
732*5113495bSYour Name 			<enum 11 wapi_gcm_sm4> WAPI GCM SM4
733*5113495bSYour Name 
734*5113495bSYour Name 
735*5113495bSYour Name 
736*5113495bSYour Name 			<enum 12 wep_varied_width> DO not use... Only for higher
737*5113495bSYour Name 			layer modules..
738*5113495bSYour Name 
739*5113495bSYour Name 			<legal 0-12>
740*5113495bSYour Name */
741*5113495bSYour Name #define TCL_DATA_CMD_2_ENCRYPT_TYPE_OFFSET                           0x00000008
742*5113495bSYour Name #define TCL_DATA_CMD_2_ENCRYPT_TYPE_LSB                              4
743*5113495bSYour Name #define TCL_DATA_CMD_2_ENCRYPT_TYPE_MASK                             0x000000f0
744*5113495bSYour Name 
745*5113495bSYour Name /* Description		TCL_DATA_CMD_2_SRC_BUFFER_SWAP
746*5113495bSYour Name 
747*5113495bSYour Name 			Treats source memory (packet buffer) organization as
748*5113495bSYour Name 			big-endian. The packets are read and byte swapped.
749*5113495bSYour Name 
750*5113495bSYour Name 			1'b0: Source memory is little endian
751*5113495bSYour Name 
752*5113495bSYour Name 			1'b1: Source memory is big endian
753*5113495bSYour Name 
754*5113495bSYour Name 			<legal all>
755*5113495bSYour Name */
756*5113495bSYour Name #define TCL_DATA_CMD_2_SRC_BUFFER_SWAP_OFFSET                        0x00000008
757*5113495bSYour Name #define TCL_DATA_CMD_2_SRC_BUFFER_SWAP_LSB                           8
758*5113495bSYour Name #define TCL_DATA_CMD_2_SRC_BUFFER_SWAP_MASK                          0x00000100
759*5113495bSYour Name 
760*5113495bSYour Name /* Description		TCL_DATA_CMD_2_LINK_META_SWAP
761*5113495bSYour Name 
762*5113495bSYour Name 			Treats link descriptor and Metadata as big-endian. The
763*5113495bSYour Name 			link descriptor/Metadata is read and byte swapped.
764*5113495bSYour Name 
765*5113495bSYour Name 			1'b0: Memory is little endian
766*5113495bSYour Name 
767*5113495bSYour Name 			1'b1: Memory is big endian
768*5113495bSYour Name 
769*5113495bSYour Name 			<legal all>
770*5113495bSYour Name */
771*5113495bSYour Name #define TCL_DATA_CMD_2_LINK_META_SWAP_OFFSET                         0x00000008
772*5113495bSYour Name #define TCL_DATA_CMD_2_LINK_META_SWAP_LSB                            9
773*5113495bSYour Name #define TCL_DATA_CMD_2_LINK_META_SWAP_MASK                           0x00000200
774*5113495bSYour Name 
775*5113495bSYour Name /* Description		TCL_DATA_CMD_2_TQM_NO_DROP
776*5113495bSYour Name 
777*5113495bSYour Name 			This bit is used to stop TQM from dropping MSDUs while
778*5113495bSYour Name 			adding them to MSDU flows1'b1: Do not drop MSDU when any of
779*5113495bSYour Name 			the threshold value is met while adding MSDU in a flow1'b1:
780*5113495bSYour Name 			Drop MSDU when any of the threshold value is met while
781*5113495bSYour Name 			adding MSDU in a flow
782*5113495bSYour Name 
783*5113495bSYour Name 			<legal all>
784*5113495bSYour Name */
785*5113495bSYour Name #define TCL_DATA_CMD_2_TQM_NO_DROP_OFFSET                            0x00000008
786*5113495bSYour Name #define TCL_DATA_CMD_2_TQM_NO_DROP_LSB                               10
787*5113495bSYour Name #define TCL_DATA_CMD_2_TQM_NO_DROP_MASK                              0x00000400
788*5113495bSYour Name 
789*5113495bSYour Name /* Description		TCL_DATA_CMD_2_RESERVED_2A
790*5113495bSYour Name 
791*5113495bSYour Name 			<legal 0>
792*5113495bSYour Name */
793*5113495bSYour Name #define TCL_DATA_CMD_2_RESERVED_2A_OFFSET                            0x00000008
794*5113495bSYour Name #define TCL_DATA_CMD_2_RESERVED_2A_LSB                               11
795*5113495bSYour Name #define TCL_DATA_CMD_2_RESERVED_2A_MASK                              0x00000800
796*5113495bSYour Name 
797*5113495bSYour Name /* Description		TCL_DATA_CMD_2_SEARCH_TYPE
798*5113495bSYour Name 
799*5113495bSYour Name 			Search type select
800*5113495bSYour Name 
801*5113495bSYour Name 
802*5113495bSYour Name 
803*5113495bSYour Name 			<enum 0 Normal_search> Address and flow search will use
804*5113495bSYour Name 			packet contents
805*5113495bSYour Name 
806*5113495bSYour Name 			<enum 1 Index_based_address_search> Address search will
807*5113495bSYour Name 
808*5113495bSYour Name 			<enum 2 Index_based_flow_search> Flow search will use
809*5113495bSYour Name 			'search_index', and address search will use packet contents
810*5113495bSYour Name 
811*5113495bSYour Name 			<legal 0-2>
812*5113495bSYour Name */
813*5113495bSYour Name #define TCL_DATA_CMD_2_SEARCH_TYPE_OFFSET                            0x00000008
814*5113495bSYour Name #define TCL_DATA_CMD_2_SEARCH_TYPE_LSB                               12
815*5113495bSYour Name #define TCL_DATA_CMD_2_SEARCH_TYPE_MASK                              0x00003000
816*5113495bSYour Name 
817*5113495bSYour Name /* Description		TCL_DATA_CMD_2_ADDRX_EN
818*5113495bSYour Name 
819*5113495bSYour Name 			Address X search enable in ASE
820*5113495bSYour Name 
821*5113495bSYour Name 			1'b0: Search disable
822*5113495bSYour Name 
823*5113495bSYour Name 			1'b1: Search Enable
824*5113495bSYour Name 
825*5113495bSYour Name 			<legal all>
826*5113495bSYour Name */
827*5113495bSYour Name #define TCL_DATA_CMD_2_ADDRX_EN_OFFSET                               0x00000008
828*5113495bSYour Name #define TCL_DATA_CMD_2_ADDRX_EN_LSB                                  14
829*5113495bSYour Name #define TCL_DATA_CMD_2_ADDRX_EN_MASK                                 0x00004000
830*5113495bSYour Name 
831*5113495bSYour Name /* Description		TCL_DATA_CMD_2_ADDRY_EN
832*5113495bSYour Name 
833*5113495bSYour Name 			Address Y search enable in ASE
834*5113495bSYour Name 
835*5113495bSYour Name 			1'b0: Search disable
836*5113495bSYour Name 
837*5113495bSYour Name 			1'b1: Search Enable
838*5113495bSYour Name 
839*5113495bSYour Name 			<legal all>
840*5113495bSYour Name */
841*5113495bSYour Name #define TCL_DATA_CMD_2_ADDRY_EN_OFFSET                               0x00000008
842*5113495bSYour Name #define TCL_DATA_CMD_2_ADDRY_EN_LSB                                  15
843*5113495bSYour Name #define TCL_DATA_CMD_2_ADDRY_EN_MASK                                 0x00008000
844*5113495bSYour Name 
845*5113495bSYour Name /* Description		TCL_DATA_CMD_2_TCL_CMD_NUMBER
846*5113495bSYour Name 
847*5113495bSYour Name 			This number can be used by SW to track, identify and
848*5113495bSYour Name 			link the created commands with the command statuses
849*5113495bSYour Name 
850*5113495bSYour Name 
851*5113495bSYour Name 
852*5113495bSYour Name 			Is set to the value 'TCL_CMD_Number' of the related
853*5113495bSYour Name 			TCL_DATA command
854*5113495bSYour Name 
855*5113495bSYour Name 			<legal all>
856*5113495bSYour Name */
857*5113495bSYour Name #define TCL_DATA_CMD_2_TCL_CMD_NUMBER_OFFSET                         0x00000008
858*5113495bSYour Name #define TCL_DATA_CMD_2_TCL_CMD_NUMBER_LSB                            16
859*5113495bSYour Name #define TCL_DATA_CMD_2_TCL_CMD_NUMBER_MASK                           0xffff0000
860*5113495bSYour Name 
861*5113495bSYour Name /* Description		TCL_DATA_CMD_3_DATA_LENGTH
862*5113495bSYour Name 
863*5113495bSYour Name 			Valid Data length in bytes.
864*5113495bSYour Name 
865*5113495bSYour Name 
866*5113495bSYour Name 
867*5113495bSYour Name 			MSDU length in case of direct descriptor.
868*5113495bSYour Name 
869*5113495bSYour Name 			Length of link extension descriptor in case of Link
870*5113495bSYour Name 			extension descriptor. This is used to know the size of
871*5113495bSYour Name 			Metadata.
872*5113495bSYour Name 
873*5113495bSYour Name 			<legal all>
874*5113495bSYour Name */
875*5113495bSYour Name #define TCL_DATA_CMD_3_DATA_LENGTH_OFFSET                            0x0000000c
876*5113495bSYour Name #define TCL_DATA_CMD_3_DATA_LENGTH_LSB                               0
877*5113495bSYour Name #define TCL_DATA_CMD_3_DATA_LENGTH_MASK                              0x0000ffff
878*5113495bSYour Name 
879*5113495bSYour Name /* Description		TCL_DATA_CMD_3_IPV4_CHECKSUM_EN
880*5113495bSYour Name 
881*5113495bSYour Name 			OLE related control
882*5113495bSYour Name 
883*5113495bSYour Name 			Enable IPv4 checksum replacement
884*5113495bSYour Name */
885*5113495bSYour Name #define TCL_DATA_CMD_3_IPV4_CHECKSUM_EN_OFFSET                       0x0000000c
886*5113495bSYour Name #define TCL_DATA_CMD_3_IPV4_CHECKSUM_EN_LSB                          16
887*5113495bSYour Name #define TCL_DATA_CMD_3_IPV4_CHECKSUM_EN_MASK                         0x00010000
888*5113495bSYour Name 
889*5113495bSYour Name /* Description		TCL_DATA_CMD_3_UDP_OVER_IPV4_CHECKSUM_EN
890*5113495bSYour Name 
891*5113495bSYour Name 			OLE related control
892*5113495bSYour Name 
893*5113495bSYour Name 			Enable UDP over IPv4 checksum replacement.  UDP checksum
894*5113495bSYour Name 			over IPv4 is optional for TCP/IP stacks.
895*5113495bSYour Name */
896*5113495bSYour Name #define TCL_DATA_CMD_3_UDP_OVER_IPV4_CHECKSUM_EN_OFFSET              0x0000000c
897*5113495bSYour Name #define TCL_DATA_CMD_3_UDP_OVER_IPV4_CHECKSUM_EN_LSB                 17
898*5113495bSYour Name #define TCL_DATA_CMD_3_UDP_OVER_IPV4_CHECKSUM_EN_MASK                0x00020000
899*5113495bSYour Name 
900*5113495bSYour Name /* Description		TCL_DATA_CMD_3_UDP_OVER_IPV6_CHECKSUM_EN
901*5113495bSYour Name 
902*5113495bSYour Name 			OLE related control
903*5113495bSYour Name 
904*5113495bSYour Name 			Enable UDP over IPv6 checksum replacement.  UDP checksum
905*5113495bSYour Name 			over IPv6 is mandatory for TCP/IP stacks.
906*5113495bSYour Name */
907*5113495bSYour Name #define TCL_DATA_CMD_3_UDP_OVER_IPV6_CHECKSUM_EN_OFFSET              0x0000000c
908*5113495bSYour Name #define TCL_DATA_CMD_3_UDP_OVER_IPV6_CHECKSUM_EN_LSB                 18
909*5113495bSYour Name #define TCL_DATA_CMD_3_UDP_OVER_IPV6_CHECKSUM_EN_MASK                0x00040000
910*5113495bSYour Name 
911*5113495bSYour Name /* Description		TCL_DATA_CMD_3_TCP_OVER_IPV4_CHECKSUM_EN
912*5113495bSYour Name 
913*5113495bSYour Name 			OLE related control
914*5113495bSYour Name 
915*5113495bSYour Name 			Enable TCP checksum over IPv4 replacement
916*5113495bSYour Name */
917*5113495bSYour Name #define TCL_DATA_CMD_3_TCP_OVER_IPV4_CHECKSUM_EN_OFFSET              0x0000000c
918*5113495bSYour Name #define TCL_DATA_CMD_3_TCP_OVER_IPV4_CHECKSUM_EN_LSB                 19
919*5113495bSYour Name #define TCL_DATA_CMD_3_TCP_OVER_IPV4_CHECKSUM_EN_MASK                0x00080000
920*5113495bSYour Name 
921*5113495bSYour Name /* Description		TCL_DATA_CMD_3_TCP_OVER_IPV6_CHECKSUM_EN
922*5113495bSYour Name 
923*5113495bSYour Name 			OLE related control
924*5113495bSYour Name 
925*5113495bSYour Name 			Enable TCP checksum over IPv6 replacement
926*5113495bSYour Name */
927*5113495bSYour Name #define TCL_DATA_CMD_3_TCP_OVER_IPV6_CHECKSUM_EN_OFFSET              0x0000000c
928*5113495bSYour Name #define TCL_DATA_CMD_3_TCP_OVER_IPV6_CHECKSUM_EN_LSB                 20
929*5113495bSYour Name #define TCL_DATA_CMD_3_TCP_OVER_IPV6_CHECKSUM_EN_MASK                0x00100000
930*5113495bSYour Name 
931*5113495bSYour Name /* Description		TCL_DATA_CMD_3_TO_FW
932*5113495bSYour Name 
933*5113495bSYour Name 			Forward packet to FW along with classification result.
934*5113495bSYour Name 			The packet will not be forward to TQM when this bit is set
935*5113495bSYour Name 
936*5113495bSYour Name 
937*5113495bSYour Name 
938*5113495bSYour Name 			1'b0: Use classification result to forward the packet.
939*5113495bSYour Name 
940*5113495bSYour Name 			1'b1: Override classification result and forward packet
941*5113495bSYour Name 			only to FW.
942*5113495bSYour Name 
943*5113495bSYour Name 			<legal all>
944*5113495bSYour Name */
945*5113495bSYour Name #define TCL_DATA_CMD_3_TO_FW_OFFSET                                  0x0000000c
946*5113495bSYour Name #define TCL_DATA_CMD_3_TO_FW_LSB                                     21
947*5113495bSYour Name #define TCL_DATA_CMD_3_TO_FW_MASK                                    0x00200000
948*5113495bSYour Name 
949*5113495bSYour Name /* Description		TCL_DATA_CMD_3_RESERVED_3A
950*5113495bSYour Name 
951*5113495bSYour Name 			<legal 0>
952*5113495bSYour Name */
953*5113495bSYour Name #define TCL_DATA_CMD_3_RESERVED_3A_OFFSET                            0x0000000c
954*5113495bSYour Name #define TCL_DATA_CMD_3_RESERVED_3A_LSB                               22
955*5113495bSYour Name #define TCL_DATA_CMD_3_RESERVED_3A_MASK                              0x00400000
956*5113495bSYour Name 
957*5113495bSYour Name /* Description		TCL_DATA_CMD_3_PACKET_OFFSET
958*5113495bSYour Name 
959*5113495bSYour Name 			Packet offset from Metadata in case of direct buffer
960*5113495bSYour Name 			descriptor. This field is valid when Buf_or_ext_desc_type is
961*5113495bSYour Name 			reset(= 0).
962*5113495bSYour Name 
963*5113495bSYour Name 			<legal all>
964*5113495bSYour Name */
965*5113495bSYour Name #define TCL_DATA_CMD_3_PACKET_OFFSET_OFFSET                          0x0000000c
966*5113495bSYour Name #define TCL_DATA_CMD_3_PACKET_OFFSET_LSB                             23
967*5113495bSYour Name #define TCL_DATA_CMD_3_PACKET_OFFSET_MASK                            0xff800000
968*5113495bSYour Name 
969*5113495bSYour Name /* Description		TCL_DATA_CMD_4_BUFFER_TIMESTAMP
970*5113495bSYour Name 
971*5113495bSYour Name 			Field only valid when 'Buffer_timestamp_valid ' is set.
972*5113495bSYour Name 
973*5113495bSYour Name 
974*5113495bSYour Name 
975*5113495bSYour Name 			Frame system entrance timestamp. The timestamp is
976*5113495bSYour Name 			related to the global system timer
977*5113495bSYour Name 
978*5113495bSYour Name 
979*5113495bSYour Name 
980*5113495bSYour Name 			Generally the first module (SW, TCL or TQM). that sees
981*5113495bSYour Name 			this frame and this timestamp field is not valid, shall fill
982*5113495bSYour Name 			in this field.
983*5113495bSYour Name 
984*5113495bSYour Name 
985*5113495bSYour Name 
986*5113495bSYour Name 			Timestamp in units of 1024 us
987*5113495bSYour Name */
988*5113495bSYour Name #define TCL_DATA_CMD_4_BUFFER_TIMESTAMP_OFFSET                       0x00000010
989*5113495bSYour Name #define TCL_DATA_CMD_4_BUFFER_TIMESTAMP_LSB                          0
990*5113495bSYour Name #define TCL_DATA_CMD_4_BUFFER_TIMESTAMP_MASK                         0x0007ffff
991*5113495bSYour Name 
992*5113495bSYour Name /* Description		TCL_DATA_CMD_4_BUFFER_TIMESTAMP_VALID
993*5113495bSYour Name 
994*5113495bSYour Name 			When set, the Buffer_timestamp field contains valid
995*5113495bSYour Name 			info.
996*5113495bSYour Name */
997*5113495bSYour Name #define TCL_DATA_CMD_4_BUFFER_TIMESTAMP_VALID_OFFSET                 0x00000010
998*5113495bSYour Name #define TCL_DATA_CMD_4_BUFFER_TIMESTAMP_VALID_LSB                    19
999*5113495bSYour Name #define TCL_DATA_CMD_4_BUFFER_TIMESTAMP_VALID_MASK                   0x00080000
1000*5113495bSYour Name 
1001*5113495bSYour Name /* Description		TCL_DATA_CMD_4_RESERVED_4A
1002*5113495bSYour Name 
1003*5113495bSYour Name 			<legal 0>
1004*5113495bSYour Name */
1005*5113495bSYour Name #define TCL_DATA_CMD_4_RESERVED_4A_OFFSET                            0x00000010
1006*5113495bSYour Name #define TCL_DATA_CMD_4_RESERVED_4A_LSB                               20
1007*5113495bSYour Name #define TCL_DATA_CMD_4_RESERVED_4A_MASK                              0x00100000
1008*5113495bSYour Name 
1009*5113495bSYour Name /* Description		TCL_DATA_CMD_4_HLOS_TID_OVERWRITE
1010*5113495bSYour Name 
1011*5113495bSYour Name 			When set, TCL shall ignore the IP DSCP and VLAN PCP
1012*5113495bSYour Name 			fields and use HLOS_TID as the final TID. Otherwise TCL
1013*5113495bSYour Name 			shall consider the DSCP and PCP fields as well as HLOS_TID
1014*5113495bSYour Name 			and choose a final TID based on the configured priority
1015*5113495bSYour Name 
1016*5113495bSYour Name 			<legal all>
1017*5113495bSYour Name */
1018*5113495bSYour Name #define TCL_DATA_CMD_4_HLOS_TID_OVERWRITE_OFFSET                     0x00000010
1019*5113495bSYour Name #define TCL_DATA_CMD_4_HLOS_TID_OVERWRITE_LSB                        21
1020*5113495bSYour Name #define TCL_DATA_CMD_4_HLOS_TID_OVERWRITE_MASK                       0x00200000
1021*5113495bSYour Name 
1022*5113495bSYour Name /* Description		TCL_DATA_CMD_4_HLOS_TID
1023*5113495bSYour Name 
1024*5113495bSYour Name 			HLOS MSDU priority
1025*5113495bSYour Name 
1026*5113495bSYour Name 
1027*5113495bSYour Name 
1028*5113495bSYour Name 			Field is used when HLOS_TID_overwrite is set.
1029*5113495bSYour Name 
1030*5113495bSYour Name 
1031*5113495bSYour Name 
1032*5113495bSYour Name 			Field is also used when HLOS_TID_overwrite is not set
1033*5113495bSYour Name 			and DSCP/PCP is not available in the packet
1034*5113495bSYour Name 
1035*5113495bSYour Name 			<legal all>
1036*5113495bSYour Name */
1037*5113495bSYour Name #define TCL_DATA_CMD_4_HLOS_TID_OFFSET                               0x00000010
1038*5113495bSYour Name #define TCL_DATA_CMD_4_HLOS_TID_LSB                                  22
1039*5113495bSYour Name #define TCL_DATA_CMD_4_HLOS_TID_MASK                                 0x03c00000
1040*5113495bSYour Name 
1041*5113495bSYour Name /* Description		TCL_DATA_CMD_4_LMAC_ID
1042*5113495bSYour Name 
1043*5113495bSYour Name 			TCL uses this LMAC_ID in address search, i.e, while
1044*5113495bSYour Name 			finding matching entry for the packet in AST corresponding
1045*5113495bSYour Name 			to given LMAC_ID
1046*5113495bSYour Name 
1047*5113495bSYour Name 			If LMAC ID is all 1s (=> value 3), it indicates wildcard
1048*5113495bSYour Name 			match for any MAC
1049*5113495bSYour Name 
1050*5113495bSYour Name 			<legal 0-3>
1051*5113495bSYour Name */
1052*5113495bSYour Name #define TCL_DATA_CMD_4_LMAC_ID_OFFSET                                0x00000010
1053*5113495bSYour Name #define TCL_DATA_CMD_4_LMAC_ID_LSB                                   26
1054*5113495bSYour Name #define TCL_DATA_CMD_4_LMAC_ID_MASK                                  0x0c000000
1055*5113495bSYour Name 
1056*5113495bSYour Name /* Description		TCL_DATA_CMD_4_RESERVED_4B
1057*5113495bSYour Name 
1058*5113495bSYour Name 			<legal 0>
1059*5113495bSYour Name */
1060*5113495bSYour Name #define TCL_DATA_CMD_4_RESERVED_4B_OFFSET                            0x00000010
1061*5113495bSYour Name #define TCL_DATA_CMD_4_RESERVED_4B_LSB                               28
1062*5113495bSYour Name #define TCL_DATA_CMD_4_RESERVED_4B_MASK                              0xf0000000
1063*5113495bSYour Name 
1064*5113495bSYour Name /* Description		TCL_DATA_CMD_5_DSCP_TID_TABLE_NUM
1065*5113495bSYour Name 
1066*5113495bSYour Name 			DSCP to TID mapping table number that need to be used
1067*5113495bSYour Name 			for the MSDU, should be specified using this field
1068*5113495bSYour Name 
1069*5113495bSYour Name 			<legal all>
1070*5113495bSYour Name */
1071*5113495bSYour Name #define TCL_DATA_CMD_5_DSCP_TID_TABLE_NUM_OFFSET                     0x00000014
1072*5113495bSYour Name #define TCL_DATA_CMD_5_DSCP_TID_TABLE_NUM_LSB                        0
1073*5113495bSYour Name #define TCL_DATA_CMD_5_DSCP_TID_TABLE_NUM_MASK                       0x0000003f
1074*5113495bSYour Name 
1075*5113495bSYour Name /* Description		TCL_DATA_CMD_5_SEARCH_INDEX
1076*5113495bSYour Name 
1077*5113495bSYour Name 			The index that will be used for index based address or
1078*5113495bSYour Name 			flow search. The field is valid when 'search_type' is  1 or
1079*5113495bSYour Name 			2.
1080*5113495bSYour Name 
1081*5113495bSYour Name 			<legal all>
1082*5113495bSYour Name */
1083*5113495bSYour Name #define TCL_DATA_CMD_5_SEARCH_INDEX_OFFSET                           0x00000014
1084*5113495bSYour Name #define TCL_DATA_CMD_5_SEARCH_INDEX_LSB                              6
1085*5113495bSYour Name #define TCL_DATA_CMD_5_SEARCH_INDEX_MASK                             0x03ffffc0
1086*5113495bSYour Name 
1087*5113495bSYour Name /* Description		TCL_DATA_CMD_5_CACHE_SET_NUM
1088*5113495bSYour Name 
1089*5113495bSYour Name 			Cache set number that should be used to cache the index
1090*5113495bSYour Name 			based search results, for address and flow search. This
1091*5113495bSYour Name 			value should be equal to LSB four bits of the hash value of
1092*5113495bSYour Name 			match data, in case of search index points to an entry which
1093*5113495bSYour Name 			may be used in content based search also. The value can be
1094*5113495bSYour Name 			anything when the entry pointed by search index will not be
1095*5113495bSYour Name 			used for content based search.
1096*5113495bSYour Name 
1097*5113495bSYour Name 			<legal all>
1098*5113495bSYour Name */
1099*5113495bSYour Name #define TCL_DATA_CMD_5_CACHE_SET_NUM_OFFSET                          0x00000014
1100*5113495bSYour Name #define TCL_DATA_CMD_5_CACHE_SET_NUM_LSB                             26
1101*5113495bSYour Name #define TCL_DATA_CMD_5_CACHE_SET_NUM_MASK                            0x3c000000
1102*5113495bSYour Name 
1103*5113495bSYour Name /* Description		TCL_DATA_CMD_5_MESH_ENABLE
1104*5113495bSYour Name 
1105*5113495bSYour Name 			If set to a non-zero value:
1106*5113495bSYour Name 
1107*5113495bSYour Name 			* For raw WiFi frames, this indicates transmission to a
1108*5113495bSYour Name 			mesh STA, enabling the interpretation of the 'Mesh Control
1109*5113495bSYour Name 			Present' bit (bit 8) of QoS Control (otherwise this bit is
1110*5113495bSYour Name 			ignored). The interpretation of the A-MSDU 'Length' field is
1111*5113495bSYour Name 			decided by the e-numerations below.
1112*5113495bSYour Name 
1113*5113495bSYour Name 			* For native WiFi frames, this indicates that a 'Mesh
1114*5113495bSYour Name 			Control' field is present between the header and the LLC.
1115*5113495bSYour Name 			The three non-zero values are interchangeable.
1116*5113495bSYour Name 
1117*5113495bSYour Name 
1118*5113495bSYour Name 
1119*5113495bSYour Name 			<enum 0 MESH_DISABLE>
1120*5113495bSYour Name 
1121*5113495bSYour Name 			<enum 1 MESH_Q2Q> A-MSDU 'Length' is big endian and
1122*5113495bSYour Name 			includes the length of Mesh Control.
1123*5113495bSYour Name 
1124*5113495bSYour Name 			<enum 2 MESH_11S_BE> A-MSDU 'Length' is big endian and
1125*5113495bSYour Name 			excludes the length of Mesh Control.
1126*5113495bSYour Name 
1127*5113495bSYour Name 			<enum 3 MESH_11S_LE> A-MSDU 'Length' is little endian
1128*5113495bSYour Name 			and excludes the length of Mesh Control. This is
1129*5113495bSYour Name 			802.11s-compliant.
1130*5113495bSYour Name */
1131*5113495bSYour Name #define TCL_DATA_CMD_5_MESH_ENABLE_OFFSET                            0x00000014
1132*5113495bSYour Name #define TCL_DATA_CMD_5_MESH_ENABLE_LSB                               30
1133*5113495bSYour Name #define TCL_DATA_CMD_5_MESH_ENABLE_MASK                              0xc0000000
1134*5113495bSYour Name 
1135*5113495bSYour Name /* Description		TCL_DATA_CMD_6_RESERVED_6A
1136*5113495bSYour Name 
1137*5113495bSYour Name 			<legal 0>
1138*5113495bSYour Name */
1139*5113495bSYour Name #define TCL_DATA_CMD_6_RESERVED_6A_OFFSET                            0x00000018
1140*5113495bSYour Name #define TCL_DATA_CMD_6_RESERVED_6A_LSB                               0
1141*5113495bSYour Name #define TCL_DATA_CMD_6_RESERVED_6A_MASK                              0x000fffff
1142*5113495bSYour Name 
1143*5113495bSYour Name /* Description		TCL_DATA_CMD_6_RING_ID
1144*5113495bSYour Name 
1145*5113495bSYour Name 			The buffer pointer ring ID.
1146*5113495bSYour Name 
1147*5113495bSYour Name 			0 refers to the IDLE ring
1148*5113495bSYour Name 
1149*5113495bSYour Name 			1 - N refers to other rings
1150*5113495bSYour Name 
1151*5113495bSYour Name 
1152*5113495bSYour Name 
1153*5113495bSYour Name 			Helps with debugging when dumping ring contents.
1154*5113495bSYour Name 
1155*5113495bSYour Name 			<legal all>
1156*5113495bSYour Name */
1157*5113495bSYour Name #define TCL_DATA_CMD_6_RING_ID_OFFSET                                0x00000018
1158*5113495bSYour Name #define TCL_DATA_CMD_6_RING_ID_LSB                                   20
1159*5113495bSYour Name #define TCL_DATA_CMD_6_RING_ID_MASK                                  0x0ff00000
1160*5113495bSYour Name 
1161*5113495bSYour Name /* Description		TCL_DATA_CMD_6_LOOPING_COUNT
1162*5113495bSYour Name 
1163*5113495bSYour Name 			A count value that indicates the number of times the
1164*5113495bSYour Name 			producer of entries into the Ring has looped around the
1165*5113495bSYour Name 			ring.
1166*5113495bSYour Name 
1167*5113495bSYour Name 			At initialization time, this value is set to 0. On the
1168*5113495bSYour Name 			first loop, this value is set to 1. After the max value is
1169*5113495bSYour Name 			reached allowed by the number of bits for this field, the
1170*5113495bSYour Name 			count value continues with 0 again.
1171*5113495bSYour Name 
1172*5113495bSYour Name 
1173*5113495bSYour Name 
1174*5113495bSYour Name 			In case SW is the consumer of the ring entries, it can
1175*5113495bSYour Name 			use this field to figure out up to where the producer of
1176*5113495bSYour Name 			entries has created new entries. This eliminates the need to
1177*5113495bSYour Name 			check where the head pointer' of the ring is located once
1178*5113495bSYour Name 			the SW starts processing an interrupt indicating that new
1179*5113495bSYour Name 			entries have been put into this ring...
1180*5113495bSYour Name 
1181*5113495bSYour Name 
1182*5113495bSYour Name 
1183*5113495bSYour Name 			Also note that SW if it wants only needs to look at the
1184*5113495bSYour Name 			LSB bit of this count value.
1185*5113495bSYour Name 
1186*5113495bSYour Name 			<legal all>
1187*5113495bSYour Name */
1188*5113495bSYour Name #define TCL_DATA_CMD_6_LOOPING_COUNT_OFFSET                          0x00000018
1189*5113495bSYour Name #define TCL_DATA_CMD_6_LOOPING_COUNT_LSB                             28
1190*5113495bSYour Name #define TCL_DATA_CMD_6_LOOPING_COUNT_MASK                            0xf0000000
1191*5113495bSYour Name 
1192*5113495bSYour Name 
1193*5113495bSYour Name #endif // _TCL_DATA_CMD_H_
1194