xref: /wlan-driver/fw-api/hw/qca6290/v1/reo_entrance_ring.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
1*5113495bSYour Name /*
2*5113495bSYour Name  * Copyright (c) 2016-2017 The Linux Foundation. All rights reserved.
3*5113495bSYour Name  *
4*5113495bSYour Name  * Permission to use, copy, modify, and/or distribute this software for
5*5113495bSYour Name  * any purpose with or without fee is hereby granted, provided that the
6*5113495bSYour Name  * above copyright notice and this permission notice appear in all
7*5113495bSYour Name  * copies.
8*5113495bSYour Name  *
9*5113495bSYour Name  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
10*5113495bSYour Name  * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
11*5113495bSYour Name  * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
12*5113495bSYour Name  * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
13*5113495bSYour Name  * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
14*5113495bSYour Name  * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
15*5113495bSYour Name  * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
16*5113495bSYour Name  * PERFORMANCE OF THIS SOFTWARE.
17*5113495bSYour Name  */
18*5113495bSYour Name 
19*5113495bSYour Name // $ATH_LICENSE_HW_HDR_C$
20*5113495bSYour Name //
21*5113495bSYour Name // DO NOT EDIT!  This file is automatically generated
22*5113495bSYour Name //               These definitions are tied to a particular hardware layout
23*5113495bSYour Name 
24*5113495bSYour Name 
25*5113495bSYour Name #ifndef _REO_ENTRANCE_RING_H_
26*5113495bSYour Name #define _REO_ENTRANCE_RING_H_
27*5113495bSYour Name #if !defined(__ASSEMBLER__)
28*5113495bSYour Name #endif
29*5113495bSYour Name 
30*5113495bSYour Name #include "rx_mpdu_details.h"
31*5113495bSYour Name 
32*5113495bSYour Name // ################ START SUMMARY #################
33*5113495bSYour Name //
34*5113495bSYour Name //	Dword	Fields
35*5113495bSYour Name //	0-3	struct rx_mpdu_details reo_level_mpdu_frame_info;
36*5113495bSYour Name //	4	rx_reo_queue_desc_addr_31_0[31:0]
37*5113495bSYour Name //	5	rx_reo_queue_desc_addr_39_32[7:0], rounded_mpdu_byte_count[21:8], reo_destination_indication[26:22], frameless_bar[27], reserved_5a[31:28]
38*5113495bSYour Name //	6	rxdma_push_reason[1:0], rxdma_error_code[6:2], reserved_6a[31:7]
39*5113495bSYour Name //	7	reserved_7a[19:0], ring_id[27:20], looping_count[31:28]
40*5113495bSYour Name //
41*5113495bSYour Name // ################ END SUMMARY #################
42*5113495bSYour Name 
43*5113495bSYour Name #define NUM_OF_DWORDS_REO_ENTRANCE_RING 8
44*5113495bSYour Name 
45*5113495bSYour Name struct reo_entrance_ring {
46*5113495bSYour Name     struct            rx_mpdu_details                       reo_level_mpdu_frame_info;
47*5113495bSYour Name              uint32_t rx_reo_queue_desc_addr_31_0     : 32; //[31:0]
48*5113495bSYour Name              uint32_t rx_reo_queue_desc_addr_39_32    :  8, //[7:0]
49*5113495bSYour Name                       rounded_mpdu_byte_count         : 14, //[21:8]
50*5113495bSYour Name                       reo_destination_indication      :  5, //[26:22]
51*5113495bSYour Name                       frameless_bar                   :  1, //[27]
52*5113495bSYour Name                       reserved_5a                     :  4; //[31:28]
53*5113495bSYour Name              uint32_t rxdma_push_reason               :  2, //[1:0]
54*5113495bSYour Name                       rxdma_error_code                :  5, //[6:2]
55*5113495bSYour Name                       reserved_6a                     : 25; //[31:7]
56*5113495bSYour Name              uint32_t reserved_7a                     : 20, //[19:0]
57*5113495bSYour Name                       ring_id                         :  8, //[27:20]
58*5113495bSYour Name                       looping_count                   :  4; //[31:28]
59*5113495bSYour Name };
60*5113495bSYour Name 
61*5113495bSYour Name /*
62*5113495bSYour Name 
63*5113495bSYour Name struct rx_mpdu_details reo_level_mpdu_frame_info
64*5113495bSYour Name 
65*5113495bSYour Name 			Consumer: REO
66*5113495bSYour Name 
67*5113495bSYour Name 			Producer: RXDMA
68*5113495bSYour Name 
69*5113495bSYour Name 
70*5113495bSYour Name 
71*5113495bSYour Name 			Details related to the MPDU being pushed into the REO
72*5113495bSYour Name 
73*5113495bSYour Name rx_reo_queue_desc_addr_31_0
74*5113495bSYour Name 
75*5113495bSYour Name 			Consumer: REO
76*5113495bSYour Name 
77*5113495bSYour Name 			Producer: RXDMA
78*5113495bSYour Name 
79*5113495bSYour Name 
80*5113495bSYour Name 
81*5113495bSYour Name 			Address (lower 32 bits) of the REO queue descriptor.
82*5113495bSYour Name 
83*5113495bSYour Name 			<legal all>
84*5113495bSYour Name 
85*5113495bSYour Name rx_reo_queue_desc_addr_39_32
86*5113495bSYour Name 
87*5113495bSYour Name 			Consumer: REO
88*5113495bSYour Name 
89*5113495bSYour Name 			Producer: RXDMA
90*5113495bSYour Name 
91*5113495bSYour Name 
92*5113495bSYour Name 
93*5113495bSYour Name 			Address (upper 8 bits) of the REO queue descriptor.
94*5113495bSYour Name 
95*5113495bSYour Name 			<legal all>
96*5113495bSYour Name 
97*5113495bSYour Name rounded_mpdu_byte_count
98*5113495bSYour Name 
99*5113495bSYour Name 			An approximation of the number of bytes received in this
100*5113495bSYour Name 			MPDU.
101*5113495bSYour Name 
102*5113495bSYour Name 			Used to keeps stats on the amount of data flowing
103*5113495bSYour Name 			through a queue.
104*5113495bSYour Name 
105*5113495bSYour Name 			<legal all>
106*5113495bSYour Name 
107*5113495bSYour Name reo_destination_indication
108*5113495bSYour Name 
109*5113495bSYour Name 			RXDMA copy the MPDU's first MSDU's destination
110*5113495bSYour Name 			indication field here. This is used for REO to be able to
111*5113495bSYour Name 			re-route the packet to a different SW destination ring if
112*5113495bSYour Name 			the packet is detected as error in REO.
113*5113495bSYour Name 
114*5113495bSYour Name 
115*5113495bSYour Name 
116*5113495bSYour Name 			The ID of the REO exit ring where the MSDU frame shall
117*5113495bSYour Name 			push after (MPDU level) reordering has finished.
118*5113495bSYour Name 
119*5113495bSYour Name 
120*5113495bSYour Name 
121*5113495bSYour Name 			<enum 0 reo_destination_tcl> Reo will push the frame
122*5113495bSYour Name 			into the REO2TCL ring
123*5113495bSYour Name 
124*5113495bSYour Name 			<enum 1 reo_destination_sw1> Reo will push the frame
125*5113495bSYour Name 			into the REO2SW1 ring
126*5113495bSYour Name 
127*5113495bSYour Name 			<enum 2 reo_destination_sw2> Reo will push the frame
128*5113495bSYour Name 			into the REO2SW1 ring
129*5113495bSYour Name 
130*5113495bSYour Name 			<enum 3 reo_destination_sw3> Reo will push the frame
131*5113495bSYour Name 			into the REO2SW1 ring
132*5113495bSYour Name 
133*5113495bSYour Name 			<enum 4 reo_destination_sw4> Reo will push the frame
134*5113495bSYour Name 			into the REO2SW1 ring
135*5113495bSYour Name 
136*5113495bSYour Name 			<enum 5 reo_destination_release> Reo will push the frame
137*5113495bSYour Name 			into the REO_release ring
138*5113495bSYour Name 
139*5113495bSYour Name 			<enum 6 reo_destination_fw> Reo will push the frame into
140*5113495bSYour Name 			the REO2FW ring
141*5113495bSYour Name 
142*5113495bSYour Name 			<enum 7 reo_destination_7> REO remaps this
143*5113495bSYour Name 
144*5113495bSYour Name 			<enum 8 reo_destination_8> REO remaps this <enum 9
145*5113495bSYour Name 			reo_destination_9> REO remaps this <enum 10
146*5113495bSYour Name 			reo_destination_10> REO remaps this
147*5113495bSYour Name 
148*5113495bSYour Name 			<enum 11 reo_destination_11> REO remaps this
149*5113495bSYour Name 
150*5113495bSYour Name 			<enum 12 reo_destination_12> REO remaps this <enum 13
151*5113495bSYour Name 			reo_destination_13> REO remaps this
152*5113495bSYour Name 
153*5113495bSYour Name 			<enum 14 reo_destination_14> REO remaps this
154*5113495bSYour Name 
155*5113495bSYour Name 			<enum 15 reo_destination_15> REO remaps this
156*5113495bSYour Name 
157*5113495bSYour Name 			<enum 16 reo_destination_16> REO remaps this
158*5113495bSYour Name 
159*5113495bSYour Name 			<enum 17 reo_destination_17> REO remaps this
160*5113495bSYour Name 
161*5113495bSYour Name 			<enum 18 reo_destination_18> REO remaps this
162*5113495bSYour Name 
163*5113495bSYour Name 			<enum 19 reo_destination_19> REO remaps this
164*5113495bSYour Name 
165*5113495bSYour Name 			<enum 20 reo_destination_20> REO remaps this
166*5113495bSYour Name 
167*5113495bSYour Name 			<enum 21 reo_destination_21> REO remaps this
168*5113495bSYour Name 
169*5113495bSYour Name 			<enum 22 reo_destination_22> REO remaps this
170*5113495bSYour Name 
171*5113495bSYour Name 			<enum 23 reo_destination_23> REO remaps this
172*5113495bSYour Name 
173*5113495bSYour Name 			<enum 24 reo_destination_24> REO remaps this
174*5113495bSYour Name 
175*5113495bSYour Name 			<enum 25 reo_destination_25> REO remaps this
176*5113495bSYour Name 
177*5113495bSYour Name 			<enum 26 reo_destination_26> REO remaps this
178*5113495bSYour Name 
179*5113495bSYour Name 			<enum 27 reo_destination_27> REO remaps this
180*5113495bSYour Name 
181*5113495bSYour Name 			<enum 28 reo_destination_28> REO remaps this
182*5113495bSYour Name 
183*5113495bSYour Name 			<enum 29 reo_destination_29> REO remaps this
184*5113495bSYour Name 
185*5113495bSYour Name 			<enum 30 reo_destination_30> REO remaps this
186*5113495bSYour Name 
187*5113495bSYour Name 			<enum 31 reo_destination_31> REO remaps this
188*5113495bSYour Name 
189*5113495bSYour Name 
190*5113495bSYour Name 
191*5113495bSYour Name 			<legal all>
192*5113495bSYour Name 
193*5113495bSYour Name frameless_bar
194*5113495bSYour Name 
195*5113495bSYour Name 			When set, this REO entrance ring struct contains BAR
196*5113495bSYour Name 			info from a multi TID BAR frame. The original multi TID BAR
197*5113495bSYour Name 			frame itself contained all the REO info for the first TID,
198*5113495bSYour Name 			but all the subsequent TID info and their linkage to the REO
199*5113495bSYour Name 			descriptors is passed down as 'frameless' BAR info.
200*5113495bSYour Name 
201*5113495bSYour Name 
202*5113495bSYour Name 
203*5113495bSYour Name 			The only fields valid in this descriptor when this bit
204*5113495bSYour Name 			is set are:
205*5113495bSYour Name 
206*5113495bSYour Name 			Rx_reo_queue_desc_addr_31_0
207*5113495bSYour Name 
208*5113495bSYour Name 			RX_reo_queue_desc_addr_39_32
209*5113495bSYour Name 
210*5113495bSYour Name 
211*5113495bSYour Name 
212*5113495bSYour Name 			And within the
213*5113495bSYour Name 
214*5113495bSYour Name 			Reo_level_mpdu_frame_info:
215*5113495bSYour Name 
216*5113495bSYour Name 			   Within Rx_mpdu_desc_info_details:
217*5113495bSYour Name 
218*5113495bSYour Name 			Mpdu_Sequence_number
219*5113495bSYour Name 
220*5113495bSYour Name 			BAR_frame
221*5113495bSYour Name 
222*5113495bSYour Name 			Peer_meta_data
223*5113495bSYour Name 
224*5113495bSYour Name 			All other fields shall be set to 0
225*5113495bSYour Name 
226*5113495bSYour Name 
227*5113495bSYour Name 
228*5113495bSYour Name 			<legal all>
229*5113495bSYour Name 
230*5113495bSYour Name reserved_5a
231*5113495bSYour Name 
232*5113495bSYour Name 			<legal 0>
233*5113495bSYour Name 
234*5113495bSYour Name rxdma_push_reason
235*5113495bSYour Name 
236*5113495bSYour Name 			Indicates why rxdma pushed the frame to this ring
237*5113495bSYour Name 
238*5113495bSYour Name 
239*5113495bSYour Name 
240*5113495bSYour Name 			<enum 0 rxdma_error_detected> RXDMA detected an error an
241*5113495bSYour Name 			pushed this frame to this queue
242*5113495bSYour Name 
243*5113495bSYour Name 			<enum 1 rxdma_routing_instruction> RXDMA pushed the
244*5113495bSYour Name 			frame to this queue per received routing instructions. No
245*5113495bSYour Name 			error within RXDMA was detected
246*5113495bSYour Name 
247*5113495bSYour Name 
248*5113495bSYour Name 
249*5113495bSYour Name 			This field is ignored by REO.
250*5113495bSYour Name 
251*5113495bSYour Name 			<legal 0 - 1>
252*5113495bSYour Name 
253*5113495bSYour Name rxdma_error_code
254*5113495bSYour Name 
255*5113495bSYour Name 			Field only valid when 'rxdma_push_reason' set to
256*5113495bSYour Name 			'rxdma_error_detected'.
257*5113495bSYour Name 
258*5113495bSYour Name 
259*5113495bSYour Name 
260*5113495bSYour Name 			This field is ignored by REO.
261*5113495bSYour Name 
262*5113495bSYour Name 
263*5113495bSYour Name 
264*5113495bSYour Name 			<enum 0 rxdma_overflow_err>MPDU frame is not complete
265*5113495bSYour Name 			due to a FIFO overflow error in RXPCU.
266*5113495bSYour Name 
267*5113495bSYour Name 			<enum 1 rxdma_mpdu_length_err>MPDU frame is not complete
268*5113495bSYour Name 			due to receiving incomplete MPDU from the PHY
269*5113495bSYour Name 
270*5113495bSYour Name 
271*5113495bSYour Name 			<enum 3 rxdma_decrypt_err>CRYPTO reported a decryption
272*5113495bSYour Name 			error or CRYPTO received an encrypted frame, but did not get
273*5113495bSYour Name 			a valid corresponding key id in the peer entry.
274*5113495bSYour Name 
275*5113495bSYour Name 			<enum 4 rxdma_tkip_mic_err>CRYPTO reported a TKIP MIC
276*5113495bSYour Name 			error
277*5113495bSYour Name 
278*5113495bSYour Name 			<enum 5 rxdma_unecrypted_err>CRYPTO reported an
279*5113495bSYour Name 			unencrypted frame error when encrypted was expected
280*5113495bSYour Name 
281*5113495bSYour Name 			<enum 6 rxdma_msdu_len_err>RX OLE reported an MSDU
282*5113495bSYour Name 			length error
283*5113495bSYour Name 
284*5113495bSYour Name 			<enum 7 rxdma_msdu_limit_err>RX OLE reported that max
285*5113495bSYour Name 			number of MSDUs allowed in an MPDU got exceeded
286*5113495bSYour Name 
287*5113495bSYour Name 			<enum 8 rxdma_wifi_parse_err>RX OLE reported a parsing
288*5113495bSYour Name 			error
289*5113495bSYour Name 
290*5113495bSYour Name 			<enum 9 rxdma_amsdu_parse_err>RX OLE reported an A-MSDU
291*5113495bSYour Name 			parsing error
292*5113495bSYour Name 
293*5113495bSYour Name 			<enum 10 rxdma_sa_timeout_err>RX OLE reported a timeout
294*5113495bSYour Name 			during SA search
295*5113495bSYour Name 
296*5113495bSYour Name 			<enum 11 rxdma_da_timeout_err>RX OLE reported a timeout
297*5113495bSYour Name 			during DA search
298*5113495bSYour Name 
299*5113495bSYour Name 			<enum 12 rxdma_flow_timeout_err>RX OLE reported a
300*5113495bSYour Name 			timeout during flow search
301*5113495bSYour Name 
302*5113495bSYour Name 			<enum 13 Rxdma_flush_request>RXDMA received a flush
303*5113495bSYour Name 			request
304*5113495bSYour Name 
305*5113495bSYour Name reserved_6a
306*5113495bSYour Name 
307*5113495bSYour Name 			<legal 0>
308*5113495bSYour Name 
309*5113495bSYour Name reserved_7a
310*5113495bSYour Name 
311*5113495bSYour Name 			<legal 0>
312*5113495bSYour Name 
313*5113495bSYour Name ring_id
314*5113495bSYour Name 
315*5113495bSYour Name 			Consumer: SW/REO/DEBUG
316*5113495bSYour Name 
317*5113495bSYour Name 			Producer: SRNG (of RXDMA)
318*5113495bSYour Name 
319*5113495bSYour Name 
320*5113495bSYour Name 
321*5113495bSYour Name 			For debugging.
322*5113495bSYour Name 
323*5113495bSYour Name 			This field is filled in by the SRNG module.
324*5113495bSYour Name 
325*5113495bSYour Name 			It help to identify the ring that is being looked <legal
326*5113495bSYour Name 			all>
327*5113495bSYour Name 
328*5113495bSYour Name looping_count
329*5113495bSYour Name 
330*5113495bSYour Name 			Consumer: SW/REO/DEBUG
331*5113495bSYour Name 
332*5113495bSYour Name 			Producer: SRNG (of RXDMA)
333*5113495bSYour Name 
334*5113495bSYour Name 
335*5113495bSYour Name 
336*5113495bSYour Name 			For debugging.
337*5113495bSYour Name 
338*5113495bSYour Name 			This field is filled in by the SRNG module.
339*5113495bSYour Name 
340*5113495bSYour Name 
341*5113495bSYour Name 
342*5113495bSYour Name 			A count value that indicates the number of times the
343*5113495bSYour Name 			producer of entries into this Ring has looped around the
344*5113495bSYour Name 			ring.
345*5113495bSYour Name 
346*5113495bSYour Name 			At initialization time, this value is set to 0. On the
347*5113495bSYour Name 			first loop, this value is set to 1. After the max value is
348*5113495bSYour Name 			reached allowed by the number of bits for this field, the
349*5113495bSYour Name 			count value continues with 0 again.
350*5113495bSYour Name 
351*5113495bSYour Name 
352*5113495bSYour Name 
353*5113495bSYour Name 			In case SW is the consumer of the ring entries, it can
354*5113495bSYour Name 			use this field to figure out up to where the producer of
355*5113495bSYour Name 			entries has created new entries. This eliminates the need to
356*5113495bSYour Name 			check where the head pointer' of the ring is located once
357*5113495bSYour Name 			the SW starts processing an interrupt indicating that new
358*5113495bSYour Name 			entries have been put into this ring...
359*5113495bSYour Name 
360*5113495bSYour Name 
361*5113495bSYour Name 
362*5113495bSYour Name 			Also note that SW if it wants only needs to look at the
363*5113495bSYour Name 			LSB bit of this count value.
364*5113495bSYour Name 
365*5113495bSYour Name 			<legal all>
366*5113495bSYour Name */
367*5113495bSYour Name 
368*5113495bSYour Name #define REO_ENTRANCE_RING_0_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_OFFSET 0x00000000
369*5113495bSYour Name #define REO_ENTRANCE_RING_0_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_LSB 28
370*5113495bSYour Name #define REO_ENTRANCE_RING_0_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_MASK 0xffffffff
371*5113495bSYour Name #define REO_ENTRANCE_RING_1_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_OFFSET 0x00000004
372*5113495bSYour Name #define REO_ENTRANCE_RING_1_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_LSB 28
373*5113495bSYour Name #define REO_ENTRANCE_RING_1_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_MASK 0xffffffff
374*5113495bSYour Name #define REO_ENTRANCE_RING_2_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_OFFSET 0x00000008
375*5113495bSYour Name #define REO_ENTRANCE_RING_2_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_LSB 28
376*5113495bSYour Name #define REO_ENTRANCE_RING_2_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_MASK 0xffffffff
377*5113495bSYour Name #define REO_ENTRANCE_RING_3_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_OFFSET 0x0000000c
378*5113495bSYour Name #define REO_ENTRANCE_RING_3_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_LSB 28
379*5113495bSYour Name #define REO_ENTRANCE_RING_3_RX_MPDU_DETAILS_REO_LEVEL_MPDU_FRAME_INFO_MASK 0xffffffff
380*5113495bSYour Name 
381*5113495bSYour Name /* Description		REO_ENTRANCE_RING_4_RX_REO_QUEUE_DESC_ADDR_31_0
382*5113495bSYour Name 
383*5113495bSYour Name 			Consumer: REO
384*5113495bSYour Name 
385*5113495bSYour Name 			Producer: RXDMA
386*5113495bSYour Name 
387*5113495bSYour Name 
388*5113495bSYour Name 
389*5113495bSYour Name 			Address (lower 32 bits) of the REO queue descriptor.
390*5113495bSYour Name 
391*5113495bSYour Name 			<legal all>
392*5113495bSYour Name */
393*5113495bSYour Name #define REO_ENTRANCE_RING_4_RX_REO_QUEUE_DESC_ADDR_31_0_OFFSET       0x00000010
394*5113495bSYour Name #define REO_ENTRANCE_RING_4_RX_REO_QUEUE_DESC_ADDR_31_0_LSB          0
395*5113495bSYour Name #define REO_ENTRANCE_RING_4_RX_REO_QUEUE_DESC_ADDR_31_0_MASK         0xffffffff
396*5113495bSYour Name 
397*5113495bSYour Name /* Description		REO_ENTRANCE_RING_5_RX_REO_QUEUE_DESC_ADDR_39_32
398*5113495bSYour Name 
399*5113495bSYour Name 			Consumer: REO
400*5113495bSYour Name 
401*5113495bSYour Name 			Producer: RXDMA
402*5113495bSYour Name 
403*5113495bSYour Name 
404*5113495bSYour Name 
405*5113495bSYour Name 			Address (upper 8 bits) of the REO queue descriptor.
406*5113495bSYour Name 
407*5113495bSYour Name 			<legal all>
408*5113495bSYour Name */
409*5113495bSYour Name #define REO_ENTRANCE_RING_5_RX_REO_QUEUE_DESC_ADDR_39_32_OFFSET      0x00000014
410*5113495bSYour Name #define REO_ENTRANCE_RING_5_RX_REO_QUEUE_DESC_ADDR_39_32_LSB         0
411*5113495bSYour Name #define REO_ENTRANCE_RING_5_RX_REO_QUEUE_DESC_ADDR_39_32_MASK        0x000000ff
412*5113495bSYour Name 
413*5113495bSYour Name /* Description		REO_ENTRANCE_RING_5_ROUNDED_MPDU_BYTE_COUNT
414*5113495bSYour Name 
415*5113495bSYour Name 			An approximation of the number of bytes received in this
416*5113495bSYour Name 			MPDU.
417*5113495bSYour Name 
418*5113495bSYour Name 			Used to keeps stats on the amount of data flowing
419*5113495bSYour Name 			through a queue.
420*5113495bSYour Name 
421*5113495bSYour Name 			<legal all>
422*5113495bSYour Name */
423*5113495bSYour Name #define REO_ENTRANCE_RING_5_ROUNDED_MPDU_BYTE_COUNT_OFFSET           0x00000014
424*5113495bSYour Name #define REO_ENTRANCE_RING_5_ROUNDED_MPDU_BYTE_COUNT_LSB              8
425*5113495bSYour Name #define REO_ENTRANCE_RING_5_ROUNDED_MPDU_BYTE_COUNT_MASK             0x003fff00
426*5113495bSYour Name 
427*5113495bSYour Name /* Description		REO_ENTRANCE_RING_5_REO_DESTINATION_INDICATION
428*5113495bSYour Name 
429*5113495bSYour Name 			RXDMA copy the MPDU's first MSDU's destination
430*5113495bSYour Name 			indication field here. This is used for REO to be able to
431*5113495bSYour Name 			re-route the packet to a different SW destination ring if
432*5113495bSYour Name 			the packet is detected as error in REO.
433*5113495bSYour Name 
434*5113495bSYour Name 
435*5113495bSYour Name 
436*5113495bSYour Name 			The ID of the REO exit ring where the MSDU frame shall
437*5113495bSYour Name 			push after (MPDU level) reordering has finished.
438*5113495bSYour Name 
439*5113495bSYour Name 
440*5113495bSYour Name 
441*5113495bSYour Name 			<enum 0 reo_destination_tcl> Reo will push the frame
442*5113495bSYour Name 			into the REO2TCL ring
443*5113495bSYour Name 
444*5113495bSYour Name 			<enum 1 reo_destination_sw1> Reo will push the frame
445*5113495bSYour Name 			into the REO2SW1 ring
446*5113495bSYour Name 
447*5113495bSYour Name 			<enum 2 reo_destination_sw2> Reo will push the frame
448*5113495bSYour Name 			into the REO2SW1 ring
449*5113495bSYour Name 
450*5113495bSYour Name 			<enum 3 reo_destination_sw3> Reo will push the frame
451*5113495bSYour Name 			into the REO2SW1 ring
452*5113495bSYour Name 
453*5113495bSYour Name 			<enum 4 reo_destination_sw4> Reo will push the frame
454*5113495bSYour Name 			into the REO2SW1 ring
455*5113495bSYour Name 
456*5113495bSYour Name 			<enum 5 reo_destination_release> Reo will push the frame
457*5113495bSYour Name 			into the REO_release ring
458*5113495bSYour Name 
459*5113495bSYour Name 			<enum 6 reo_destination_fw> Reo will push the frame into
460*5113495bSYour Name 			the REO2FW ring
461*5113495bSYour Name 
462*5113495bSYour Name 			<enum 7 reo_destination_7> REO remaps this
463*5113495bSYour Name 
464*5113495bSYour Name 			<enum 8 reo_destination_8> REO remaps this <enum 9
465*5113495bSYour Name 			reo_destination_9> REO remaps this <enum 10
466*5113495bSYour Name 			reo_destination_10> REO remaps this
467*5113495bSYour Name 
468*5113495bSYour Name 			<enum 11 reo_destination_11> REO remaps this
469*5113495bSYour Name 
470*5113495bSYour Name 			<enum 12 reo_destination_12> REO remaps this <enum 13
471*5113495bSYour Name 			reo_destination_13> REO remaps this
472*5113495bSYour Name 
473*5113495bSYour Name 			<enum 14 reo_destination_14> REO remaps this
474*5113495bSYour Name 
475*5113495bSYour Name 			<enum 15 reo_destination_15> REO remaps this
476*5113495bSYour Name 
477*5113495bSYour Name 			<enum 16 reo_destination_16> REO remaps this
478*5113495bSYour Name 
479*5113495bSYour Name 			<enum 17 reo_destination_17> REO remaps this
480*5113495bSYour Name 
481*5113495bSYour Name 			<enum 18 reo_destination_18> REO remaps this
482*5113495bSYour Name 
483*5113495bSYour Name 			<enum 19 reo_destination_19> REO remaps this
484*5113495bSYour Name 
485*5113495bSYour Name 			<enum 20 reo_destination_20> REO remaps this
486*5113495bSYour Name 
487*5113495bSYour Name 			<enum 21 reo_destination_21> REO remaps this
488*5113495bSYour Name 
489*5113495bSYour Name 			<enum 22 reo_destination_22> REO remaps this
490*5113495bSYour Name 
491*5113495bSYour Name 			<enum 23 reo_destination_23> REO remaps this
492*5113495bSYour Name 
493*5113495bSYour Name 			<enum 24 reo_destination_24> REO remaps this
494*5113495bSYour Name 
495*5113495bSYour Name 			<enum 25 reo_destination_25> REO remaps this
496*5113495bSYour Name 
497*5113495bSYour Name 			<enum 26 reo_destination_26> REO remaps this
498*5113495bSYour Name 
499*5113495bSYour Name 			<enum 27 reo_destination_27> REO remaps this
500*5113495bSYour Name 
501*5113495bSYour Name 			<enum 28 reo_destination_28> REO remaps this
502*5113495bSYour Name 
503*5113495bSYour Name 			<enum 29 reo_destination_29> REO remaps this
504*5113495bSYour Name 
505*5113495bSYour Name 			<enum 30 reo_destination_30> REO remaps this
506*5113495bSYour Name 
507*5113495bSYour Name 			<enum 31 reo_destination_31> REO remaps this
508*5113495bSYour Name 
509*5113495bSYour Name 
510*5113495bSYour Name 
511*5113495bSYour Name 			<legal all>
512*5113495bSYour Name */
513*5113495bSYour Name #define REO_ENTRANCE_RING_5_REO_DESTINATION_INDICATION_OFFSET        0x00000014
514*5113495bSYour Name #define REO_ENTRANCE_RING_5_REO_DESTINATION_INDICATION_LSB           22
515*5113495bSYour Name #define REO_ENTRANCE_RING_5_REO_DESTINATION_INDICATION_MASK          0x07c00000
516*5113495bSYour Name 
517*5113495bSYour Name /* Description		REO_ENTRANCE_RING_5_FRAMELESS_BAR
518*5113495bSYour Name 
519*5113495bSYour Name 			When set, this REO entrance ring struct contains BAR
520*5113495bSYour Name 			info from a multi TID BAR frame. The original multi TID BAR
521*5113495bSYour Name 			frame itself contained all the REO info for the first TID,
522*5113495bSYour Name 			but all the subsequent TID info and their linkage to the REO
523*5113495bSYour Name 			descriptors is passed down as 'frameless' BAR info.
524*5113495bSYour Name 
525*5113495bSYour Name 
526*5113495bSYour Name 
527*5113495bSYour Name 			The only fields valid in this descriptor when this bit
528*5113495bSYour Name 			is set are:
529*5113495bSYour Name 
530*5113495bSYour Name 			Rx_reo_queue_desc_addr_31_0
531*5113495bSYour Name 
532*5113495bSYour Name 			RX_reo_queue_desc_addr_39_32
533*5113495bSYour Name 
534*5113495bSYour Name 
535*5113495bSYour Name 
536*5113495bSYour Name 			And within the
537*5113495bSYour Name 
538*5113495bSYour Name 			Reo_level_mpdu_frame_info:
539*5113495bSYour Name 
540*5113495bSYour Name 			   Within Rx_mpdu_desc_info_details:
541*5113495bSYour Name 
542*5113495bSYour Name 			Mpdu_Sequence_number
543*5113495bSYour Name 
544*5113495bSYour Name 			BAR_frame
545*5113495bSYour Name 
546*5113495bSYour Name 			Peer_meta_data
547*5113495bSYour Name 
548*5113495bSYour Name 			All other fields shall be set to 0
549*5113495bSYour Name 
550*5113495bSYour Name 
551*5113495bSYour Name 
552*5113495bSYour Name 			<legal all>
553*5113495bSYour Name */
554*5113495bSYour Name #define REO_ENTRANCE_RING_5_FRAMELESS_BAR_OFFSET                     0x00000014
555*5113495bSYour Name #define REO_ENTRANCE_RING_5_FRAMELESS_BAR_LSB                        27
556*5113495bSYour Name #define REO_ENTRANCE_RING_5_FRAMELESS_BAR_MASK                       0x08000000
557*5113495bSYour Name 
558*5113495bSYour Name /* Description		REO_ENTRANCE_RING_5_RESERVED_5A
559*5113495bSYour Name 
560*5113495bSYour Name 			<legal 0>
561*5113495bSYour Name */
562*5113495bSYour Name #define REO_ENTRANCE_RING_5_RESERVED_5A_OFFSET                       0x00000014
563*5113495bSYour Name #define REO_ENTRANCE_RING_5_RESERVED_5A_LSB                          28
564*5113495bSYour Name #define REO_ENTRANCE_RING_5_RESERVED_5A_MASK                         0xf0000000
565*5113495bSYour Name 
566*5113495bSYour Name /* Description		REO_ENTRANCE_RING_6_RXDMA_PUSH_REASON
567*5113495bSYour Name 
568*5113495bSYour Name 			Indicates why rxdma pushed the frame to this ring
569*5113495bSYour Name 
570*5113495bSYour Name 
571*5113495bSYour Name 
572*5113495bSYour Name 			<enum 0 rxdma_error_detected> RXDMA detected an error an
573*5113495bSYour Name 			pushed this frame to this queue
574*5113495bSYour Name 
575*5113495bSYour Name 			<enum 1 rxdma_routing_instruction> RXDMA pushed the
576*5113495bSYour Name 			frame to this queue per received routing instructions. No
577*5113495bSYour Name 			error within RXDMA was detected
578*5113495bSYour Name 
579*5113495bSYour Name 
580*5113495bSYour Name 
581*5113495bSYour Name 			This field is ignored by REO.
582*5113495bSYour Name 
583*5113495bSYour Name 			<legal 0 - 1>
584*5113495bSYour Name */
585*5113495bSYour Name #define REO_ENTRANCE_RING_6_RXDMA_PUSH_REASON_OFFSET                 0x00000018
586*5113495bSYour Name #define REO_ENTRANCE_RING_6_RXDMA_PUSH_REASON_LSB                    0
587*5113495bSYour Name #define REO_ENTRANCE_RING_6_RXDMA_PUSH_REASON_MASK                   0x00000003
588*5113495bSYour Name 
589*5113495bSYour Name /* Description		REO_ENTRANCE_RING_6_RXDMA_ERROR_CODE
590*5113495bSYour Name 
591*5113495bSYour Name 			Field only valid when 'rxdma_push_reason' set to
592*5113495bSYour Name 			'rxdma_error_detected'.
593*5113495bSYour Name 
594*5113495bSYour Name 
595*5113495bSYour Name 
596*5113495bSYour Name 			This field is ignored by REO.
597*5113495bSYour Name 
598*5113495bSYour Name 
599*5113495bSYour Name 
600*5113495bSYour Name 			<enum 0 rxdma_overflow_err>MPDU frame is not complete
601*5113495bSYour Name 			due to a FIFO overflow error in RXPCU.
602*5113495bSYour Name 
603*5113495bSYour Name 			<enum 1 rxdma_mpdu_length_err>MPDU frame is not complete
604*5113495bSYour Name 			due to receiving incomplete MPDU from the PHY
605*5113495bSYour Name 
606*5113495bSYour Name 
607*5113495bSYour Name 			<enum 3 rxdma_decrypt_err>CRYPTO reported a decryption
608*5113495bSYour Name 			error or CRYPTO received an encrypted frame, but did not get
609*5113495bSYour Name 			a valid corresponding key id in the peer entry.
610*5113495bSYour Name 
611*5113495bSYour Name 			<enum 4 rxdma_tkip_mic_err>CRYPTO reported a TKIP MIC
612*5113495bSYour Name 			error
613*5113495bSYour Name 
614*5113495bSYour Name 			<enum 5 rxdma_unecrypted_err>CRYPTO reported an
615*5113495bSYour Name 			unencrypted frame error when encrypted was expected
616*5113495bSYour Name 
617*5113495bSYour Name 			<enum 6 rxdma_msdu_len_err>RX OLE reported an MSDU
618*5113495bSYour Name 			length error
619*5113495bSYour Name 
620*5113495bSYour Name 			<enum 7 rxdma_msdu_limit_err>RX OLE reported that max
621*5113495bSYour Name 			number of MSDUs allowed in an MPDU got exceeded
622*5113495bSYour Name 
623*5113495bSYour Name 			<enum 8 rxdma_wifi_parse_err>RX OLE reported a parsing
624*5113495bSYour Name 			error
625*5113495bSYour Name 
626*5113495bSYour Name 			<enum 9 rxdma_amsdu_parse_err>RX OLE reported an A-MSDU
627*5113495bSYour Name 			parsing error
628*5113495bSYour Name 
629*5113495bSYour Name 			<enum 10 rxdma_sa_timeout_err>RX OLE reported a timeout
630*5113495bSYour Name 			during SA search
631*5113495bSYour Name 
632*5113495bSYour Name 			<enum 11 rxdma_da_timeout_err>RX OLE reported a timeout
633*5113495bSYour Name 			during DA search
634*5113495bSYour Name 
635*5113495bSYour Name 			<enum 12 rxdma_flow_timeout_err>RX OLE reported a
636*5113495bSYour Name 			timeout during flow search
637*5113495bSYour Name 
638*5113495bSYour Name 			<enum 13 Rxdma_flush_request>RXDMA received a flush
639*5113495bSYour Name 			request
640*5113495bSYour Name */
641*5113495bSYour Name #define REO_ENTRANCE_RING_6_RXDMA_ERROR_CODE_OFFSET                  0x00000018
642*5113495bSYour Name #define REO_ENTRANCE_RING_6_RXDMA_ERROR_CODE_LSB                     2
643*5113495bSYour Name #define REO_ENTRANCE_RING_6_RXDMA_ERROR_CODE_MASK                    0x0000007c
644*5113495bSYour Name 
645*5113495bSYour Name /* Description		REO_ENTRANCE_RING_6_RESERVED_6A
646*5113495bSYour Name 
647*5113495bSYour Name 			<legal 0>
648*5113495bSYour Name */
649*5113495bSYour Name #define REO_ENTRANCE_RING_6_RESERVED_6A_OFFSET                       0x00000018
650*5113495bSYour Name #define REO_ENTRANCE_RING_6_RESERVED_6A_LSB                          7
651*5113495bSYour Name #define REO_ENTRANCE_RING_6_RESERVED_6A_MASK                         0xffffff80
652*5113495bSYour Name 
653*5113495bSYour Name /* Description		REO_ENTRANCE_RING_7_RESERVED_7A
654*5113495bSYour Name 
655*5113495bSYour Name 			<legal 0>
656*5113495bSYour Name */
657*5113495bSYour Name #define REO_ENTRANCE_RING_7_RESERVED_7A_OFFSET                       0x0000001c
658*5113495bSYour Name #define REO_ENTRANCE_RING_7_RESERVED_7A_LSB                          0
659*5113495bSYour Name #define REO_ENTRANCE_RING_7_RESERVED_7A_MASK                         0x000fffff
660*5113495bSYour Name 
661*5113495bSYour Name /* Description		REO_ENTRANCE_RING_7_RING_ID
662*5113495bSYour Name 
663*5113495bSYour Name 			Consumer: SW/REO/DEBUG
664*5113495bSYour Name 
665*5113495bSYour Name 			Producer: SRNG (of RXDMA)
666*5113495bSYour Name 
667*5113495bSYour Name 
668*5113495bSYour Name 
669*5113495bSYour Name 			For debugging.
670*5113495bSYour Name 
671*5113495bSYour Name 			This field is filled in by the SRNG module.
672*5113495bSYour Name 
673*5113495bSYour Name 			It help to identify the ring that is being looked <legal
674*5113495bSYour Name 			all>
675*5113495bSYour Name */
676*5113495bSYour Name #define REO_ENTRANCE_RING_7_RING_ID_OFFSET                           0x0000001c
677*5113495bSYour Name #define REO_ENTRANCE_RING_7_RING_ID_LSB                              20
678*5113495bSYour Name #define REO_ENTRANCE_RING_7_RING_ID_MASK                             0x0ff00000
679*5113495bSYour Name 
680*5113495bSYour Name /* Description		REO_ENTRANCE_RING_7_LOOPING_COUNT
681*5113495bSYour Name 
682*5113495bSYour Name 			Consumer: SW/REO/DEBUG
683*5113495bSYour Name 
684*5113495bSYour Name 			Producer: SRNG (of RXDMA)
685*5113495bSYour Name 
686*5113495bSYour Name 
687*5113495bSYour Name 
688*5113495bSYour Name 			For debugging.
689*5113495bSYour Name 
690*5113495bSYour Name 			This field is filled in by the SRNG module.
691*5113495bSYour Name 
692*5113495bSYour Name 
693*5113495bSYour Name 
694*5113495bSYour Name 			A count value that indicates the number of times the
695*5113495bSYour Name 			producer of entries into this Ring has looped around the
696*5113495bSYour Name 			ring.
697*5113495bSYour Name 
698*5113495bSYour Name 			At initialization time, this value is set to 0. On the
699*5113495bSYour Name 			first loop, this value is set to 1. After the max value is
700*5113495bSYour Name 			reached allowed by the number of bits for this field, the
701*5113495bSYour Name 			count value continues with 0 again.
702*5113495bSYour Name 
703*5113495bSYour Name 
704*5113495bSYour Name 
705*5113495bSYour Name 			In case SW is the consumer of the ring entries, it can
706*5113495bSYour Name 			use this field to figure out up to where the producer of
707*5113495bSYour Name 			entries has created new entries. This eliminates the need to
708*5113495bSYour Name 			check where the head pointer' of the ring is located once
709*5113495bSYour Name 			the SW starts processing an interrupt indicating that new
710*5113495bSYour Name 			entries have been put into this ring...
711*5113495bSYour Name 
712*5113495bSYour Name 
713*5113495bSYour Name 
714*5113495bSYour Name 			Also note that SW if it wants only needs to look at the
715*5113495bSYour Name 			LSB bit of this count value.
716*5113495bSYour Name 
717*5113495bSYour Name 			<legal all>
718*5113495bSYour Name */
719*5113495bSYour Name #define REO_ENTRANCE_RING_7_LOOPING_COUNT_OFFSET                     0x0000001c
720*5113495bSYour Name #define REO_ENTRANCE_RING_7_LOOPING_COUNT_LSB                        28
721*5113495bSYour Name #define REO_ENTRANCE_RING_7_LOOPING_COUNT_MASK                       0xf0000000
722*5113495bSYour Name 
723*5113495bSYour Name 
724*5113495bSYour Name #endif // _REO_ENTRANCE_RING_H_
725