• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /******************************************************************************
2  *
3  * Copyright(c) 2016 - 2019 Realtek Corporation. All rights reserved.
4  *
5  * This program is free software; you can redistribute it and/or modify it
6  * under the terms of version 2 of the GNU General Public License as
7  * published by the Free Software Foundation.
8  *
9  * This program is distributed in the hope that it will be useful, but WITHOUT
10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12  * more details.
13  *
14  ******************************************************************************/
15 
16 #ifndef _HALMAC_TX_DESC_IE_AP_H_
17 #define _HALMAC_TX_DESC_IE_AP_H_
18 #if (HALMAC_8814B_SUPPORT)
19 
20 #define IE0_GET_TX_DESC_IE_END(txdesc_ie)                                      \
21 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
22 			      0x1, 31)
23 #define IE0_SET_TX_DESC_IE_END(txdesc_ie, value)                               \
24 	HALMAC_SET_DESC_FIELD_CLR(                                             \
25 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
26 #define IE0_SET_TX_DESC_IE_END_NO_CLR(txdesc_ie, value)                        \
27 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
28 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
29 #define IE0_GET_TX_DESC_IE_UP(txdesc_ie)                                       \
30 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
31 			      0x1, 30)
32 #define IE0_SET_TX_DESC_IE_UP(txdesc_ie, value)                                \
33 	HALMAC_SET_DESC_FIELD_CLR(                                             \
34 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
35 #define IE0_SET_TX_DESC_IE_UP_NO_CLR(txdesc_ie, value)                         \
36 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
37 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
38 #define IE0_GET_TX_DESC_IE_NUM(txdesc_ie)                                      \
39 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
40 			      0xf, 24)
41 #define IE0_SET_TX_DESC_IE_NUM(txdesc_ie, value)                               \
42 	HALMAC_SET_DESC_FIELD_CLR(                                             \
43 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
44 #define IE0_SET_TX_DESC_IE_NUM_NO_CLR(txdesc_ie, value)                        \
45 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
46 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
47 #define IE0_GET_TX_DESC_ARFR_TABLE_SEL(txdesc_ie)                              \
48 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
49 			      0x1, 19)
50 #define IE0_SET_TX_DESC_ARFR_TABLE_SEL(txdesc_ie, value)                       \
51 	HALMAC_SET_DESC_FIELD_CLR(                                             \
52 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 19)
53 #define IE0_SET_TX_DESC_ARFR_TABLE_SEL_NO_CLR(txdesc_ie, value)                \
54 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
55 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 19)
56 #define IE0_GET_TX_DESC_ARFR_HT_EN(txdesc_ie)                                  \
57 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
58 			      0x1, 18)
59 #define IE0_SET_TX_DESC_ARFR_HT_EN(txdesc_ie, value)                           \
60 	HALMAC_SET_DESC_FIELD_CLR(                                             \
61 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 18)
62 #define IE0_SET_TX_DESC_ARFR_HT_EN_NO_CLR(txdesc_ie, value)                    \
63 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
64 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 18)
65 #define IE0_GET_TX_DESC_ARFR_OFDM_EN(txdesc_ie)                                \
66 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
67 			      0x1, 17)
68 #define IE0_SET_TX_DESC_ARFR_OFDM_EN(txdesc_ie, value)                         \
69 	HALMAC_SET_DESC_FIELD_CLR(                                             \
70 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 17)
71 #define IE0_SET_TX_DESC_ARFR_OFDM_EN_NO_CLR(txdesc_ie, value)                  \
72 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
73 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 17)
74 #define IE0_GET_TX_DESC_ARFR_CCK_EN(txdesc_ie)                                 \
75 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
76 			      0x1, 16)
77 #define IE0_SET_TX_DESC_ARFR_CCK_EN(txdesc_ie, value)                          \
78 	HALMAC_SET_DESC_FIELD_CLR(                                             \
79 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 16)
80 #define IE0_SET_TX_DESC_ARFR_CCK_EN_NO_CLR(txdesc_ie, value)                   \
81 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
82 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 16)
83 #define IE0_GET_TX_DESC_HW_RTS_EN(txdesc_ie)                                   \
84 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
85 			      0x1, 9)
86 #define IE0_SET_TX_DESC_HW_RTS_EN(txdesc_ie, value)                            \
87 	HALMAC_SET_DESC_FIELD_CLR(                                             \
88 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 9)
89 #define IE0_SET_TX_DESC_HW_RTS_EN_NO_CLR(txdesc_ie, value)                     \
90 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
91 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 9)
92 #define IE0_GET_TX_DESC_RTS_EN(txdesc_ie)                                      \
93 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
94 			      0x1, 8)
95 #define IE0_SET_TX_DESC_RTS_EN(txdesc_ie, value)                               \
96 	HALMAC_SET_DESC_FIELD_CLR(                                             \
97 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 8)
98 #define IE0_SET_TX_DESC_RTS_EN_NO_CLR(txdesc_ie, value)                        \
99 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
100 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 8)
101 #define IE0_GET_TX_DESC_CTS2SELF(txdesc_ie)                                    \
102 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
103 			      0x1, 7)
104 #define IE0_SET_TX_DESC_CTS2SELF(txdesc_ie, value)                             \
105 	HALMAC_SET_DESC_FIELD_CLR(                                             \
106 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 7)
107 #define IE0_SET_TX_DESC_CTS2SELF_NO_CLR(txdesc_ie, value)                      \
108 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
109 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 7)
110 #define IE0_GET_TX_DESC_RTY_LMT_EN(txdesc_ie)                                  \
111 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
112 			      0x1, 6)
113 #define IE0_SET_TX_DESC_RTY_LMT_EN(txdesc_ie, value)                           \
114 	HALMAC_SET_DESC_FIELD_CLR(                                             \
115 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 6)
116 #define IE0_SET_TX_DESC_RTY_LMT_EN_NO_CLR(txdesc_ie, value)                    \
117 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
118 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 6)
119 #define IE0_GET_TX_DESC_RTS_SHORT(txdesc_ie)                                   \
120 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
121 			      0x1, 5)
122 #define IE0_SET_TX_DESC_RTS_SHORT(txdesc_ie, value)                            \
123 	HALMAC_SET_DESC_FIELD_CLR(                                             \
124 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 5)
125 #define IE0_SET_TX_DESC_RTS_SHORT_NO_CLR(txdesc_ie, value)                     \
126 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
127 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 5)
128 #define IE0_GET_TX_DESC_DISDATAFB(txdesc_ie)                                   \
129 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
130 			      0x1, 4)
131 #define IE0_SET_TX_DESC_DISDATAFB(txdesc_ie, value)                            \
132 	HALMAC_SET_DESC_FIELD_CLR(                                             \
133 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 4)
134 #define IE0_SET_TX_DESC_DISDATAFB_NO_CLR(txdesc_ie, value)                     \
135 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
136 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 4)
137 #define IE0_GET_TX_DESC_DISRTSFB(txdesc_ie)                                    \
138 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
139 			      0x1, 3)
140 #define IE0_SET_TX_DESC_DISRTSFB(txdesc_ie, value)                             \
141 	HALMAC_SET_DESC_FIELD_CLR(                                             \
142 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 3)
143 #define IE0_SET_TX_DESC_DISRTSFB_NO_CLR(txdesc_ie, value)                      \
144 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
145 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 3)
146 #define IE0_GET_TX_DESC_DATA_SHORT(txdesc_ie)                                  \
147 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
148 			      0x1, 2)
149 #define IE0_SET_TX_DESC_DATA_SHORT(txdesc_ie, value)                           \
150 	HALMAC_SET_DESC_FIELD_CLR(                                             \
151 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 2)
152 #define IE0_SET_TX_DESC_DATA_SHORT_NO_CLR(txdesc_ie, value)                    \
153 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
154 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 2)
155 #define IE0_GET_TX_DESC_TRY_RATE(txdesc_ie)                                    \
156 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
157 			      0x1, 1)
158 #define IE0_SET_TX_DESC_TRY_RATE(txdesc_ie, value)                             \
159 	HALMAC_SET_DESC_FIELD_CLR(                                             \
160 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
161 #define IE0_SET_TX_DESC_TRY_RATE_NO_CLR(txdesc_ie, value)                      \
162 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
163 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
164 #define IE0_GET_TX_DESC_USERATE(txdesc_ie)                                     \
165 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
166 			      0x1, 0)
167 #define IE0_SET_TX_DESC_USERATE(txdesc_ie, value)                              \
168 	HALMAC_SET_DESC_FIELD_CLR(                                             \
169 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
170 #define IE0_SET_TX_DESC_USERATE_NO_CLR(txdesc_ie, value)                       \
171 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
172 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
173 #define IE0_GET_TX_DESC_RTS_RTY_LOWEST_RATE(txdesc_ie)                         \
174 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
175 			      0xf, 27)
176 #define IE0_SET_TX_DESC_RTS_RTY_LOWEST_RATE(txdesc_ie, value)                  \
177 	HALMAC_SET_DESC_FIELD_CLR(                                             \
178 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 27)
179 #define IE0_SET_TX_DESC_RTS_RTY_LOWEST_RATE_NO_CLR(txdesc_ie, value)           \
180 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
181 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 27)
182 #define IE0_GET_TX_DESC_DATA_RTY_LOWEST_RATE(txdesc_ie)                        \
183 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
184 			      0x1f, 22)
185 #define IE0_SET_TX_DESC_DATA_RTY_LOWEST_RATE(txdesc_ie, value)                 \
186 	HALMAC_SET_DESC_FIELD_CLR(                                             \
187 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1f, 22)
188 #define IE0_SET_TX_DESC_DATA_RTY_LOWEST_RATE_NO_CLR(txdesc_ie, value)          \
189 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
190 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1f, 22)
191 #define IE0_GET_TX_DESC_RTS_DATA_RTY_LMT(txdesc_ie)                            \
192 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
193 			      0x3f, 16)
194 #define IE0_SET_TX_DESC_RTS_DATA_RTY_LMT(txdesc_ie, value)                     \
195 	HALMAC_SET_DESC_FIELD_CLR(                                             \
196 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3f, 16)
197 #define IE0_SET_TX_DESC_RTS_DATA_RTY_LMT_NO_CLR(txdesc_ie, value)              \
198 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
199 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3f, 16)
200 #define IE0_GET_TX_DESC_DATA_BW(txdesc_ie)                                     \
201 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
202 			      0x3, 12)
203 #define IE0_SET_TX_DESC_DATA_BW(txdesc_ie, value)                              \
204 	HALMAC_SET_DESC_FIELD_CLR(                                             \
205 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 12)
206 #define IE0_SET_TX_DESC_DATA_BW_NO_CLR(txdesc_ie, value)                       \
207 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
208 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 12)
209 #define IE0_GET_TX_DESC_RTSRATE(txdesc_ie)                                     \
210 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
211 			      0xf, 7)
212 #define IE0_SET_TX_DESC_RTSRATE(txdesc_ie, value)                              \
213 	HALMAC_SET_DESC_FIELD_CLR(                                             \
214 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 7)
215 #define IE0_SET_TX_DESC_RTSRATE_NO_CLR(txdesc_ie, value)                       \
216 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
217 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 7)
218 #define IE0_GET_TX_DESC_DATARATE(txdesc_ie)                                    \
219 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
220 			      0x7f, 0)
221 #define IE0_SET_TX_DESC_DATARATE(txdesc_ie, value)                             \
222 	HALMAC_SET_DESC_FIELD_CLR(                                             \
223 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x7f, 0)
224 #define IE0_SET_TX_DESC_DATARATE_NO_CLR(txdesc_ie, value)                      \
225 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
226 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x7f, 0)
227 #define IE1_GET_TX_DESC_IE_END(txdesc_ie)                                      \
228 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
229 			      0x1, 31)
230 #define IE1_SET_TX_DESC_IE_END(txdesc_ie, value)                               \
231 	HALMAC_SET_DESC_FIELD_CLR(                                             \
232 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
233 #define IE1_SET_TX_DESC_IE_END_NO_CLR(txdesc_ie, value)                        \
234 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
235 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
236 #define IE1_GET_TX_DESC_IE_UP(txdesc_ie)                                       \
237 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
238 			      0x1, 30)
239 #define IE1_SET_TX_DESC_IE_UP(txdesc_ie, value)                                \
240 	HALMAC_SET_DESC_FIELD_CLR(                                             \
241 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
242 #define IE1_SET_TX_DESC_IE_UP_NO_CLR(txdesc_ie, value)                         \
243 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
244 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
245 #define IE1_GET_TX_DESC_IE_NUM(txdesc_ie)                                      \
246 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
247 			      0xf, 24)
248 #define IE1_SET_TX_DESC_IE_NUM(txdesc_ie, value)                               \
249 	HALMAC_SET_DESC_FIELD_CLR(                                             \
250 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
251 #define IE1_SET_TX_DESC_IE_NUM_NO_CLR(txdesc_ie, value)                        \
252 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
253 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
254 #define IE1_GET_TX_DESC_AMPDU_DENSITY(txdesc_ie)                               \
255 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
256 			      0x7, 21)
257 #define IE1_SET_TX_DESC_AMPDU_DENSITY(txdesc_ie, value)                        \
258 	HALMAC_SET_DESC_FIELD_CLR(                                             \
259 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x7, 21)
260 #define IE1_SET_TX_DESC_AMPDU_DENSITY_NO_CLR(txdesc_ie, value)                 \
261 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
262 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x7, 21)
263 #define IE1_GET_TX_DESC_MAX_AGG_NUM(txdesc_ie)                                 \
264 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
265 			      0x1f, 16)
266 #define IE1_SET_TX_DESC_MAX_AGG_NUM(txdesc_ie, value)                          \
267 	HALMAC_SET_DESC_FIELD_CLR(                                             \
268 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1f, 16)
269 #define IE1_SET_TX_DESC_MAX_AGG_NUM_NO_CLR(txdesc_ie, value)                   \
270 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
271 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1f, 16)
272 #define IE1_GET_TX_DESC_SECTYPE(txdesc_ie)                                     \
273 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
274 			      0x3, 14)
275 #define IE1_SET_TX_DESC_SECTYPE(txdesc_ie, value)                              \
276 	HALMAC_SET_DESC_FIELD_CLR(                                             \
277 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x3, 14)
278 #define IE1_SET_TX_DESC_SECTYPE_NO_CLR(txdesc_ie, value)                       \
279 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
280 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x3, 14)
281 #define IE1_GET_TX_DESC_MOREFRAG(txdesc_ie)                                    \
282 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
283 			      0x1, 13)
284 #define IE1_SET_TX_DESC_MOREFRAG(txdesc_ie, value)                             \
285 	HALMAC_SET_DESC_FIELD_CLR(                                             \
286 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 13)
287 #define IE1_SET_TX_DESC_MOREFRAG_NO_CLR(txdesc_ie, value)                      \
288 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
289 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 13)
290 #define IE1_GET_TX_DESC_NOACM(txdesc_ie)                                       \
291 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
292 			      0x1, 12)
293 #define IE1_SET_TX_DESC_NOACM(txdesc_ie, value)                                \
294 	HALMAC_SET_DESC_FIELD_CLR(                                             \
295 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 12)
296 #define IE1_SET_TX_DESC_NOACM_NO_CLR(txdesc_ie, value)                         \
297 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
298 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 12)
299 #define IE1_GET_TX_DESC_BCNPKT_TSF_CTRL(txdesc_ie)                             \
300 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
301 			      0x1, 11)
302 #define IE1_SET_TX_DESC_BCNPKT_TSF_CTRL(txdesc_ie, value)                      \
303 	HALMAC_SET_DESC_FIELD_CLR(                                             \
304 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 11)
305 #define IE1_SET_TX_DESC_BCNPKT_TSF_CTRL_NO_CLR(txdesc_ie, value)               \
306 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
307 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 11)
308 #define IE1_GET_TX_DESC_NAVUSEHDR(txdesc_ie)                                   \
309 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
310 			      0x1, 10)
311 #define IE1_SET_TX_DESC_NAVUSEHDR(txdesc_ie, value)                            \
312 	HALMAC_SET_DESC_FIELD_CLR(                                             \
313 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 10)
314 #define IE1_SET_TX_DESC_NAVUSEHDR_NO_CLR(txdesc_ie, value)                     \
315 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
316 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 10)
317 #define IE1_GET_TX_DESC_HTC(txdesc_ie)                                         \
318 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
319 			      0x1, 9)
320 #define IE1_SET_TX_DESC_HTC(txdesc_ie, value)                                  \
321 	HALMAC_SET_DESC_FIELD_CLR(                                             \
322 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 9)
323 #define IE1_SET_TX_DESC_HTC_NO_CLR(txdesc_ie, value)                           \
324 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
325 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 9)
326 #define IE1_GET_TX_DESC_BMC(txdesc_ie)                                         \
327 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
328 			      0x1, 8)
329 #define IE1_SET_TX_DESC_BMC(txdesc_ie, value)                                  \
330 	HALMAC_SET_DESC_FIELD_CLR(                                             \
331 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 8)
332 #define IE1_SET_TX_DESC_BMC_NO_CLR(txdesc_ie, value)                           \
333 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
334 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 8)
335 #define IE1_GET_TX_DESC_TX_PKT_AFTER_PIFS(txdesc_ie)                           \
336 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
337 			      0x1, 7)
338 #define IE1_SET_TX_DESC_TX_PKT_AFTER_PIFS(txdesc_ie, value)                    \
339 	HALMAC_SET_DESC_FIELD_CLR(                                             \
340 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 7)
341 #define IE1_SET_TX_DESC_TX_PKT_AFTER_PIFS_NO_CLR(txdesc_ie, value)             \
342 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
343 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 7)
344 #define IE1_GET_TX_DESC_USE_MAX_TIME_EN(txdesc_ie)                             \
345 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
346 			      0x1, 6)
347 #define IE1_SET_TX_DESC_USE_MAX_TIME_EN(txdesc_ie, value)                      \
348 	HALMAC_SET_DESC_FIELD_CLR(                                             \
349 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 6)
350 #define IE1_SET_TX_DESC_USE_MAX_TIME_EN_NO_CLR(txdesc_ie, value)               \
351 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
352 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 6)
353 #define IE1_GET_TX_DESC_HW_SSN_SEL(txdesc_ie)                                  \
354 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
355 			      0x3, 4)
356 #define IE1_SET_TX_DESC_HW_SSN_SEL(txdesc_ie, value)                           \
357 	HALMAC_SET_DESC_FIELD_CLR(                                             \
358 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x3, 4)
359 #define IE1_SET_TX_DESC_HW_SSN_SEL_NO_CLR(txdesc_ie, value)                    \
360 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
361 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x3, 4)
362 #define IE1_GET_TX_DESC_DISQSELSEQ(txdesc_ie)                                  \
363 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
364 			      0x1, 3)
365 #define IE1_SET_TX_DESC_DISQSELSEQ(txdesc_ie, value)                           \
366 	HALMAC_SET_DESC_FIELD_CLR(                                             \
367 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 3)
368 #define IE1_SET_TX_DESC_DISQSELSEQ_NO_CLR(txdesc_ie, value)                    \
369 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
370 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 3)
371 #define IE1_GET_TX_DESC_EN_HWSEQ(txdesc_ie)                                    \
372 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
373 			      0x1, 2)
374 #define IE1_SET_TX_DESC_EN_HWSEQ(txdesc_ie, value)                             \
375 	HALMAC_SET_DESC_FIELD_CLR(                                             \
376 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 2)
377 #define IE1_SET_TX_DESC_EN_HWSEQ_NO_CLR(txdesc_ie, value)                      \
378 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
379 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 2)
380 #define IE1_GET_TX_DESC_EN_HWEXSEQ(txdesc_ie)                                  \
381 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
382 			      0x1, 1)
383 #define IE1_SET_TX_DESC_EN_HWEXSEQ(txdesc_ie, value)                           \
384 	HALMAC_SET_DESC_FIELD_CLR(                                             \
385 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
386 #define IE1_SET_TX_DESC_EN_HWEXSEQ_NO_CLR(txdesc_ie, value)                    \
387 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
388 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
389 #define IE1_GET_TX_DESC_EN_DESC_ID(txdesc_ie)                                  \
390 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
391 			      0x1, 0)
392 #define IE1_SET_TX_DESC_EN_DESC_ID(txdesc_ie, value)                           \
393 	HALMAC_SET_DESC_FIELD_CLR(                                             \
394 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
395 #define IE1_SET_TX_DESC_EN_DESC_ID_NO_CLR(txdesc_ie, value)                    \
396 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
397 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
398 #define IE1_GET_TX_DESC_AMPDU_MAX_TIME(txdesc_ie)                              \
399 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
400 			      0xff, 24)
401 #define IE1_SET_TX_DESC_AMPDU_MAX_TIME(txdesc_ie, value)                       \
402 	HALMAC_SET_DESC_FIELD_CLR(                                             \
403 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xff, 24)
404 #define IE1_SET_TX_DESC_AMPDU_MAX_TIME_NO_CLR(txdesc_ie, value)                \
405 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
406 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xff, 24)
407 #define IE1_GET_TX_DESC_P_AID(txdesc_ie)                                       \
408 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
409 			      0x1ff, 15)
410 #define IE1_SET_TX_DESC_P_AID(txdesc_ie, value)                                \
411 	HALMAC_SET_DESC_FIELD_CLR(                                             \
412 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1ff,    \
413 		15)
414 #define IE1_SET_TX_DESC_P_AID_NO_CLR(txdesc_ie, value)                         \
415 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
416 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1ff,    \
417 		15)
418 #define IE1_GET_TX_DESC_MOREDATA(txdesc_ie)                                    \
419 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
420 			      0x1, 14)
421 #define IE1_SET_TX_DESC_MOREDATA(txdesc_ie, value)                             \
422 	HALMAC_SET_DESC_FIELD_CLR(                                             \
423 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1, 14)
424 #define IE1_SET_TX_DESC_MOREDATA_NO_CLR(txdesc_ie, value)                      \
425 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
426 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1, 14)
427 #define IE1_GET_TX_DESC_SW_SEQ(txdesc_ie)                                      \
428 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
429 			      0xfff, 0)
430 #define IE1_SET_TX_DESC_SW_SEQ(txdesc_ie, value)                               \
431 	HALMAC_SET_DESC_FIELD_CLR(                                             \
432 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xfff, 0)
433 #define IE1_SET_TX_DESC_SW_SEQ_NO_CLR(txdesc_ie, value)                        \
434 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
435 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xfff, 0)
436 #define IE2_GET_TX_DESC_IE_END(txdesc_ie)                                      \
437 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
438 			      0x1, 31)
439 #define IE2_SET_TX_DESC_IE_END(txdesc_ie, value)                               \
440 	HALMAC_SET_DESC_FIELD_CLR(                                             \
441 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
442 #define IE2_SET_TX_DESC_IE_END_NO_CLR(txdesc_ie, value)                        \
443 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
444 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
445 #define IE2_GET_TX_DESC_IE_UP(txdesc_ie)                                       \
446 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
447 			      0x1, 30)
448 #define IE2_SET_TX_DESC_IE_UP(txdesc_ie, value)                                \
449 	HALMAC_SET_DESC_FIELD_CLR(                                             \
450 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
451 #define IE2_SET_TX_DESC_IE_UP_NO_CLR(txdesc_ie, value)                         \
452 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
453 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
454 #define IE2_GET_TX_DESC_IE_NUM(txdesc_ie)                                      \
455 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
456 			      0xf, 24)
457 #define IE2_SET_TX_DESC_IE_NUM(txdesc_ie, value)                               \
458 	HALMAC_SET_DESC_FIELD_CLR(                                             \
459 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
460 #define IE2_SET_TX_DESC_IE_NUM_NO_CLR(txdesc_ie, value)                        \
461 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
462 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
463 #define IE2_GET_TX_DESC_ADDR_CAM(txdesc_ie)                                    \
464 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
465 			      0xff, 16)
466 #define IE2_SET_TX_DESC_ADDR_CAM(txdesc_ie, value)                             \
467 	HALMAC_SET_DESC_FIELD_CLR(                                             \
468 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xff, 16)
469 #define IE2_SET_TX_DESC_ADDR_CAM_NO_CLR(txdesc_ie, value)                      \
470 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
471 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xff, 16)
472 #define IE2_GET_TX_DESC_MULTIPLE_PORT(txdesc_ie)                               \
473 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
474 			      0x7, 12)
475 #define IE2_SET_TX_DESC_MULTIPLE_PORT(txdesc_ie, value)                        \
476 	HALMAC_SET_DESC_FIELD_CLR(                                             \
477 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x7, 12)
478 #define IE2_SET_TX_DESC_MULTIPLE_PORT_NO_CLR(txdesc_ie, value)                 \
479 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
480 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x7, 12)
481 #define IE2_GET_TX_DESC_RAW(txdesc_ie)                                         \
482 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
483 			      0x1, 11)
484 #define IE2_SET_TX_DESC_RAW(txdesc_ie, value)                                  \
485 	HALMAC_SET_DESC_FIELD_CLR(                                             \
486 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 11)
487 #define IE2_SET_TX_DESC_RAW_NO_CLR(txdesc_ie, value)                           \
488 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
489 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 11)
490 #define IE2_GET_TX_DESC_RDG_EN(txdesc_ie)                                      \
491 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
492 			      0x1, 10)
493 #define IE2_SET_TX_DESC_RDG_EN(txdesc_ie, value)                               \
494 	HALMAC_SET_DESC_FIELD_CLR(                                             \
495 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 10)
496 #define IE2_SET_TX_DESC_RDG_EN_NO_CLR(txdesc_ie, value)                        \
497 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
498 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 10)
499 #define IE2_GET_TX_DESC_SPECIAL_CW(txdesc_ie)                                  \
500 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
501 			      0x1, 7)
502 #define IE2_SET_TX_DESC_SPECIAL_CW(txdesc_ie, value)                           \
503 	HALMAC_SET_DESC_FIELD_CLR(                                             \
504 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 7)
505 #define IE2_SET_TX_DESC_SPECIAL_CW_NO_CLR(txdesc_ie, value)                    \
506 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
507 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 7)
508 #define IE2_GET_TX_DESC_POLLUTED(txdesc_ie)                                    \
509 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
510 			      0x1, 6)
511 #define IE2_SET_TX_DESC_POLLUTED(txdesc_ie, value)                             \
512 	HALMAC_SET_DESC_FIELD_CLR(                                             \
513 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 6)
514 #define IE2_SET_TX_DESC_POLLUTED_NO_CLR(txdesc_ie, value)                      \
515 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
516 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 6)
517 #define IE2_GET_TX_DESC_BT_NULL(txdesc_ie)                                     \
518 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
519 			      0x1, 5)
520 #define IE2_SET_TX_DESC_BT_NULL(txdesc_ie, value)                              \
521 	HALMAC_SET_DESC_FIELD_CLR(                                             \
522 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 5)
523 #define IE2_SET_TX_DESC_BT_NULL_NO_CLR(txdesc_ie, value)                       \
524 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
525 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 5)
526 #define IE2_GET_TX_DESC_NULL_1(txdesc_ie)                                      \
527 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
528 			      0x1, 4)
529 #define IE2_SET_TX_DESC_NULL_1(txdesc_ie, value)                               \
530 	HALMAC_SET_DESC_FIELD_CLR(                                             \
531 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 4)
532 #define IE2_SET_TX_DESC_NULL_1_NO_CLR(txdesc_ie, value)                        \
533 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
534 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 4)
535 #define IE2_GET_TX_DESC_NULL_0(txdesc_ie)                                      \
536 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
537 			      0x1, 3)
538 #define IE2_SET_TX_DESC_NULL_0(txdesc_ie, value)                               \
539 	HALMAC_SET_DESC_FIELD_CLR(                                             \
540 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 3)
541 #define IE2_SET_TX_DESC_NULL_0_NO_CLR(txdesc_ie, value)                        \
542 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
543 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 3)
544 #define IE2_GET_TX_DESC_TRI_FRAME(txdesc_ie)                                   \
545 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
546 			      0x1, 2)
547 #define IE2_SET_TX_DESC_TRI_FRAME(txdesc_ie, value)                            \
548 	HALMAC_SET_DESC_FIELD_CLR(                                             \
549 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 2)
550 #define IE2_SET_TX_DESC_TRI_FRAME_NO_CLR(txdesc_ie, value)                     \
551 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
552 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 2)
553 #define IE2_GET_TX_DESC_SPE_RPT(txdesc_ie)                                     \
554 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
555 			      0x1, 1)
556 #define IE2_SET_TX_DESC_SPE_RPT(txdesc_ie, value)                              \
557 	HALMAC_SET_DESC_FIELD_CLR(                                             \
558 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
559 #define IE2_SET_TX_DESC_SPE_RPT_NO_CLR(txdesc_ie, value)                       \
560 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
561 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
562 #define IE2_GET_TX_DESC_FTM_EN(txdesc_ie)                                      \
563 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
564 			      0x1, 0)
565 #define IE2_SET_TX_DESC_FTM_EN(txdesc_ie, value)                               \
566 	HALMAC_SET_DESC_FIELD_CLR(                                             \
567 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
568 #define IE2_SET_TX_DESC_FTM_EN_NO_CLR(txdesc_ie, value)                        \
569 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
570 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
571 #define IE2_GET_TX_DESC_MBSSID(txdesc_ie)                                      \
572 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
573 			      0xf, 27)
574 #define IE2_SET_TX_DESC_MBSSID(txdesc_ie, value)                               \
575 	HALMAC_SET_DESC_FIELD_CLR(                                             \
576 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 27)
577 #define IE2_SET_TX_DESC_MBSSID_NO_CLR(txdesc_ie, value)                        \
578 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
579 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 27)
580 #define IE2_GET_TX_DESC_GROUP_BIT_IE_OFFSET(txdesc_ie)                         \
581 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
582 			      0x7ff, 16)
583 #define IE2_SET_TX_DESC_GROUP_BIT_IE_OFFSET(txdesc_ie, value)                  \
584 	HALMAC_SET_DESC_FIELD_CLR(                                             \
585 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x7ff,    \
586 		16)
587 #define IE2_SET_TX_DESC_GROUP_BIT_IE_OFFSET_NO_CLR(txdesc_ie, value)           \
588 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
589 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x7ff,    \
590 		16)
591 #define IE2_GET_TX_DESC_RDG_NAV_EXT(txdesc_ie)                                 \
592 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
593 			      0x1, 15)
594 #define IE2_SET_TX_DESC_RDG_NAV_EXT(txdesc_ie, value)                          \
595 	HALMAC_SET_DESC_FIELD_CLR(                                             \
596 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1, 15)
597 #define IE2_SET_TX_DESC_RDG_NAV_EXT_NO_CLR(txdesc_ie, value)                   \
598 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
599 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1, 15)
600 #define IE2_GET_TX_DESC_DROP_ID(txdesc_ie)                                     \
601 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
602 			      0x3, 12)
603 #define IE2_SET_TX_DESC_DROP_ID(txdesc_ie, value)                              \
604 	HALMAC_SET_DESC_FIELD_CLR(                                             \
605 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 12)
606 #define IE2_SET_TX_DESC_DROP_ID_NO_CLR(txdesc_ie, value)                       \
607 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
608 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 12)
609 #define IE2_GET_TX_DESC_SW_DEFINE(txdesc_ie)                                   \
610 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
611 			      0xfff, 0)
612 #define IE2_SET_TX_DESC_SW_DEFINE(txdesc_ie, value)                            \
613 	HALMAC_SET_DESC_FIELD_CLR(                                             \
614 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xfff, 0)
615 #define IE2_SET_TX_DESC_SW_DEFINE_NO_CLR(txdesc_ie, value)                     \
616 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
617 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xfff, 0)
618 #define IE3_GET_TX_DESC_IE_END(txdesc_ie)                                      \
619 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
620 			      0x1, 31)
621 #define IE3_SET_TX_DESC_IE_END(txdesc_ie, value)                               \
622 	HALMAC_SET_DESC_FIELD_CLR(                                             \
623 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
624 #define IE3_SET_TX_DESC_IE_END_NO_CLR(txdesc_ie, value)                        \
625 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
626 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
627 #define IE3_GET_TX_DESC_IE_UP(txdesc_ie)                                       \
628 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
629 			      0x1, 30)
630 #define IE3_SET_TX_DESC_IE_UP(txdesc_ie, value)                                \
631 	HALMAC_SET_DESC_FIELD_CLR(                                             \
632 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
633 #define IE3_SET_TX_DESC_IE_UP_NO_CLR(txdesc_ie, value)                         \
634 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
635 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
636 #define IE3_GET_TX_DESC_IE_NUM(txdesc_ie)                                      \
637 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
638 			      0xf, 24)
639 #define IE3_SET_TX_DESC_IE_NUM(txdesc_ie, value)                               \
640 	HALMAC_SET_DESC_FIELD_CLR(                                             \
641 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
642 #define IE3_SET_TX_DESC_IE_NUM_NO_CLR(txdesc_ie, value)                        \
643 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
644 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
645 #define IE3_GET_TX_DESC_DATA_SC(txdesc_ie)                                     \
646 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
647 			      0xf, 20)
648 #define IE3_SET_TX_DESC_DATA_SC(txdesc_ie, value)                              \
649 	HALMAC_SET_DESC_FIELD_CLR(                                             \
650 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 20)
651 #define IE3_SET_TX_DESC_DATA_SC_NO_CLR(txdesc_ie, value)                       \
652 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
653 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 20)
654 #define IE3_GET_TX_DESC_SIGNALING_TA_PKT_SC(txdesc_ie)                         \
655 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
656 			      0xf, 16)
657 #define IE3_SET_TX_DESC_SIGNALING_TA_PKT_SC(txdesc_ie, value)                  \
658 	HALMAC_SET_DESC_FIELD_CLR(                                             \
659 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 16)
660 #define IE3_SET_TX_DESC_SIGNALING_TA_PKT_SC_NO_CLR(txdesc_ie, value)           \
661 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
662 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 16)
663 #define IE3_GET_TX_DESC_CTRL_CNT(txdesc_ie)                                    \
664 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
665 			      0xf, 8)
666 #define IE3_SET_TX_DESC_CTRL_CNT(txdesc_ie, value)                             \
667 	HALMAC_SET_DESC_FIELD_CLR(                                             \
668 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 8)
669 #define IE3_SET_TX_DESC_CTRL_CNT_NO_CLR(txdesc_ie, value)                      \
670 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
671 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 8)
672 #define IE3_GET_TX_DESC_CTRL_CNT_VALID(txdesc_ie)                              \
673 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
674 			      0x1, 1)
675 #define IE3_SET_TX_DESC_CTRL_CNT_VALID(txdesc_ie, value)                       \
676 	HALMAC_SET_DESC_FIELD_CLR(                                             \
677 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
678 #define IE3_SET_TX_DESC_CTRL_CNT_VALID_NO_CLR(txdesc_ie, value)                \
679 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
680 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
681 #define IE3_GET_TX_DESC_SIGNALING_TA_PKT_EN(txdesc_ie)                         \
682 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
683 			      0x1, 0)
684 #define IE3_SET_TX_DESC_SIGNALING_TA_PKT_EN(txdesc_ie, value)                  \
685 	HALMAC_SET_DESC_FIELD_CLR(                                             \
686 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
687 #define IE3_SET_TX_DESC_SIGNALING_TA_PKT_EN_NO_CLR(txdesc_ie, value)           \
688 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
689 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
690 #define IE3_GET_TX_DESC_G_ID(txdesc_ie)                                        \
691 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
692 			      0x3f, 24)
693 #define IE3_SET_TX_DESC_G_ID(txdesc_ie, value)                                 \
694 	HALMAC_SET_DESC_FIELD_CLR(                                             \
695 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3f, 24)
696 #define IE3_SET_TX_DESC_G_ID_NO_CLR(txdesc_ie, value)                          \
697 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
698 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3f, 24)
699 #define IE3_GET_TX_DESC_SND_TARGET(txdesc_ie)                                  \
700 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
701 			      0xff, 16)
702 #define IE3_SET_TX_DESC_SND_TARGET(txdesc_ie, value)                           \
703 	HALMAC_SET_DESC_FIELD_CLR(                                             \
704 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xff, 16)
705 #define IE3_SET_TX_DESC_SND_TARGET_NO_CLR(txdesc_ie, value)                    \
706 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
707 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xff, 16)
708 #define IE3_GET_TX_DESC_CCA_RTS(txdesc_ie)                                     \
709 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
710 			      0x3, 11)
711 #define IE3_SET_TX_DESC_CCA_RTS(txdesc_ie, value)                              \
712 	HALMAC_SET_DESC_FIELD_CLR(                                             \
713 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 11)
714 #define IE3_SET_TX_DESC_CCA_RTS_NO_CLR(txdesc_ie, value)                       \
715 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
716 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 11)
717 #define IE3_GET_TX_DESC_SND_PKT_SEL(txdesc_ie)                                 \
718 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
719 			      0x3, 9)
720 #define IE3_SET_TX_DESC_SND_PKT_SEL(txdesc_ie, value)                          \
721 	HALMAC_SET_DESC_FIELD_CLR(                                             \
722 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 9)
723 #define IE3_SET_TX_DESC_SND_PKT_SEL_NO_CLR(txdesc_ie, value)                   \
724 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
725 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 9)
726 #define IE3_GET_TX_DESC_NDPA(txdesc_ie)                                        \
727 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
728 			      0x3, 7)
729 #define IE3_SET_TX_DESC_NDPA(txdesc_ie, value)                                 \
730 	HALMAC_SET_DESC_FIELD_CLR(                                             \
731 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 7)
732 #define IE3_SET_TX_DESC_NDPA_NO_CLR(txdesc_ie, value)                          \
733 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
734 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 7)
735 #define IE3_GET_TX_DESC_MU_DATARATE(txdesc_ie)                                 \
736 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
737 			      0x7f, 0)
738 #define IE3_SET_TX_DESC_MU_DATARATE(txdesc_ie, value)                          \
739 	HALMAC_SET_DESC_FIELD_CLR(                                             \
740 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x7f, 0)
741 #define IE3_SET_TX_DESC_MU_DATARATE_NO_CLR(txdesc_ie, value)                   \
742 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
743 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x7f, 0)
744 #define IE4_GET_TX_DESC_IE_END(txdesc_ie)                                      \
745 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
746 			      0x1, 31)
747 #define IE4_SET_TX_DESC_IE_END(txdesc_ie, value)                               \
748 	HALMAC_SET_DESC_FIELD_CLR(                                             \
749 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
750 #define IE4_SET_TX_DESC_IE_END_NO_CLR(txdesc_ie, value)                        \
751 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
752 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
753 #define IE4_GET_TX_DESC_IE_UP(txdesc_ie)                                       \
754 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
755 			      0x1, 30)
756 #define IE4_SET_TX_DESC_IE_UP(txdesc_ie, value)                                \
757 	HALMAC_SET_DESC_FIELD_CLR(                                             \
758 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
759 #define IE4_SET_TX_DESC_IE_UP_NO_CLR(txdesc_ie, value)                         \
760 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
761 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
762 #define IE4_GET_TX_DESC_IE_NUM(txdesc_ie)                                      \
763 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
764 			      0xf, 24)
765 #define IE4_SET_TX_DESC_IE_NUM(txdesc_ie, value)                               \
766 	HALMAC_SET_DESC_FIELD_CLR(                                             \
767 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
768 #define IE4_SET_TX_DESC_IE_NUM_NO_CLR(txdesc_ie, value)                        \
769 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
770 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
771 #define IE4_GET_TX_DESC_VCS_STBC(txdesc_ie)                                    \
772 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
773 			      0x3, 10)
774 #define IE4_SET_TX_DESC_VCS_STBC(txdesc_ie, value)                             \
775 	HALMAC_SET_DESC_FIELD_CLR(                                             \
776 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x3, 10)
777 #define IE4_SET_TX_DESC_VCS_STBC_NO_CLR(txdesc_ie, value)                      \
778 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
779 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x3, 10)
780 #define IE4_GET_TX_DESC_DATA_STBC(txdesc_ie)                                   \
781 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
782 			      0x3, 8)
783 #define IE4_SET_TX_DESC_DATA_STBC(txdesc_ie, value)                            \
784 	HALMAC_SET_DESC_FIELD_CLR(                                             \
785 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x3, 8)
786 #define IE4_SET_TX_DESC_DATA_STBC_NO_CLR(txdesc_ie, value)                     \
787 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
788 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x3, 8)
789 #define IE4_GET_TX_DESC_DATA_LDPC(txdesc_ie)                                   \
790 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
791 			      0x1, 2)
792 #define IE4_SET_TX_DESC_DATA_LDPC(txdesc_ie, value)                            \
793 	HALMAC_SET_DESC_FIELD_CLR(                                             \
794 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 2)
795 #define IE4_SET_TX_DESC_DATA_LDPC_NO_CLR(txdesc_ie, value)                     \
796 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
797 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 2)
798 #define IE4_GET_TX_DESC_GF(txdesc_ie)                                          \
799 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
800 			      0x1, 1)
801 #define IE4_SET_TX_DESC_GF(txdesc_ie, value)                                   \
802 	HALMAC_SET_DESC_FIELD_CLR(                                             \
803 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
804 #define IE4_SET_TX_DESC_GF_NO_CLR(txdesc_ie, value)                            \
805 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
806 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 1)
807 #define IE4_GET_TX_DESC_LSIG_TXOP_EN(txdesc_ie)                                \
808 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
809 			      0x1, 0)
810 #define IE4_SET_TX_DESC_LSIG_TXOP_EN(txdesc_ie, value)                         \
811 	HALMAC_SET_DESC_FIELD_CLR(                                             \
812 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
813 #define IE4_SET_TX_DESC_LSIG_TXOP_EN_NO_CLR(txdesc_ie, value)                  \
814 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
815 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 0)
816 #define IE4_GET_TX_DESC_PATH_MAPA(txdesc_ie)                                   \
817 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
818 			      0x3, 30)
819 #define IE4_SET_TX_DESC_PATH_MAPA(txdesc_ie, value)                            \
820 	HALMAC_SET_DESC_FIELD_CLR(                                             \
821 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 30)
822 #define IE4_SET_TX_DESC_PATH_MAPA_NO_CLR(txdesc_ie, value)                     \
823 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
824 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 30)
825 #define IE4_GET_TX_DESC_PATH_MAPB(txdesc_ie)                                   \
826 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
827 			      0x3, 28)
828 #define IE4_SET_TX_DESC_PATH_MAPB(txdesc_ie, value)                            \
829 	HALMAC_SET_DESC_FIELD_CLR(                                             \
830 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 28)
831 #define IE4_SET_TX_DESC_PATH_MAPB_NO_CLR(txdesc_ie, value)                     \
832 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
833 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 28)
834 #define IE4_GET_TX_DESC_PATH_MAPC(txdesc_ie)                                   \
835 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
836 			      0x3, 26)
837 #define IE4_SET_TX_DESC_PATH_MAPC(txdesc_ie, value)                            \
838 	HALMAC_SET_DESC_FIELD_CLR(                                             \
839 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 26)
840 #define IE4_SET_TX_DESC_PATH_MAPC_NO_CLR(txdesc_ie, value)                     \
841 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
842 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 26)
843 #define IE4_GET_TX_DESC_PATH_MAPD(txdesc_ie)                                   \
844 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
845 			      0x3, 24)
846 #define IE4_SET_TX_DESC_PATH_MAPD(txdesc_ie, value)                            \
847 	HALMAC_SET_DESC_FIELD_CLR(                                             \
848 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 24)
849 #define IE4_SET_TX_DESC_PATH_MAPD_NO_CLR(txdesc_ie, value)                     \
850 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
851 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 24)
852 #define IE4_GET_TX_DESC_ANTSEL_A(txdesc_ie)                                    \
853 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
854 			      0xf, 20)
855 #define IE4_SET_TX_DESC_ANTSEL_A(txdesc_ie, value)                             \
856 	HALMAC_SET_DESC_FIELD_CLR(                                             \
857 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 20)
858 #define IE4_SET_TX_DESC_ANTSEL_A_NO_CLR(txdesc_ie, value)                      \
859 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
860 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 20)
861 #define IE4_GET_TX_DESC_ANTSEL_B(txdesc_ie)                                    \
862 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
863 			      0xf, 16)
864 #define IE4_SET_TX_DESC_ANTSEL_B(txdesc_ie, value)                             \
865 	HALMAC_SET_DESC_FIELD_CLR(                                             \
866 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 16)
867 #define IE4_SET_TX_DESC_ANTSEL_B_NO_CLR(txdesc_ie, value)                      \
868 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
869 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 16)
870 #define IE4_GET_TX_DESC_ANTSEL_C(txdesc_ie)                                    \
871 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
872 			      0xf, 12)
873 #define IE4_SET_TX_DESC_ANTSEL_C(txdesc_ie, value)                             \
874 	HALMAC_SET_DESC_FIELD_CLR(                                             \
875 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 12)
876 #define IE4_SET_TX_DESC_ANTSEL_C_NO_CLR(txdesc_ie, value)                      \
877 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
878 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 12)
879 #define IE4_GET_TX_DESC_ANTSEL_D(txdesc_ie)                                    \
880 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
881 			      0xf, 8)
882 #define IE4_SET_TX_DESC_ANTSEL_D(txdesc_ie, value)                             \
883 	HALMAC_SET_DESC_FIELD_CLR(                                             \
884 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 8)
885 #define IE4_SET_TX_DESC_ANTSEL_D_NO_CLR(txdesc_ie, value)                      \
886 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
887 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 8)
888 #define IE4_GET_TX_DESC_NTX_PATH_EN(txdesc_ie)                                 \
889 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
890 			      0xf, 4)
891 #define IE4_SET_TX_DESC_NTX_PATH_EN(txdesc_ie, value)                          \
892 	HALMAC_SET_DESC_FIELD_CLR(                                             \
893 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 4)
894 #define IE4_SET_TX_DESC_NTX_PATH_EN_NO_CLR(txdesc_ie, value)                   \
895 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
896 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0xf, 4)
897 #define IE4_GET_TX_DESC_ANTLSEL_EN(txdesc_ie)                                  \
898 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
899 			      0x1, 3)
900 #define IE4_SET_TX_DESC_ANTLSEL_EN(txdesc_ie, value)                           \
901 	HALMAC_SET_DESC_FIELD_CLR(                                             \
902 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1, 3)
903 #define IE4_SET_TX_DESC_ANTLSEL_EN_NO_CLR(txdesc_ie, value)                    \
904 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
905 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1, 3)
906 #define IE4_GET_TX_DESC_TXPWR_OFSET_TYPE(txdesc_ie)                            \
907 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
908 			      0x3, 0)
909 #define IE4_SET_TX_DESC_TXPWR_OFSET_TYPE(txdesc_ie, value)                     \
910 	HALMAC_SET_DESC_FIELD_CLR(                                             \
911 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 0)
912 #define IE4_SET_TX_DESC_TXPWR_OFSET_TYPE_NO_CLR(txdesc_ie, value)              \
913 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
914 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3, 0)
915 #define IE5_GET_TX_DESC_IE_END(txdesc_ie)                                      \
916 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
917 			      0x1, 31)
918 #define IE5_SET_TX_DESC_IE_END(txdesc_ie, value)                               \
919 	HALMAC_SET_DESC_FIELD_CLR(                                             \
920 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
921 #define IE5_SET_TX_DESC_IE_END_NO_CLR(txdesc_ie, value)                        \
922 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
923 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 31)
924 #define IE5_GET_TX_DESC_IE_UP(txdesc_ie)                                       \
925 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
926 			      0x1, 30)
927 #define IE5_SET_TX_DESC_IE_UP(txdesc_ie, value)                                \
928 	HALMAC_SET_DESC_FIELD_CLR(                                             \
929 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
930 #define IE5_SET_TX_DESC_IE_UP_NO_CLR(txdesc_ie, value)                         \
931 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
932 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1, 30)
933 #define IE5_GET_TX_DESC_IE_NUM(txdesc_ie)                                      \
934 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
935 			      0xf, 24)
936 #define IE5_SET_TX_DESC_IE_NUM(txdesc_ie, value)                               \
937 	HALMAC_SET_DESC_FIELD_CLR(                                             \
938 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
939 #define IE5_SET_TX_DESC_IE_NUM_NO_CLR(txdesc_ie, value)                        \
940 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
941 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 24)
942 #define IE5_GET_TX_DESC_LEN1_L(txdesc_ie)                                      \
943 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
944 			      0x7f, 17)
945 #define IE5_SET_TX_DESC_LEN1_L(txdesc_ie, value)                               \
946 	HALMAC_SET_DESC_FIELD_CLR(                                             \
947 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x7f, 17)
948 #define IE5_SET_TX_DESC_LEN1_L_NO_CLR(txdesc_ie, value)                        \
949 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
950 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x7f, 17)
951 #define IE5_GET_TX_DESC_LEN0(txdesc_ie)                                        \
952 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
953 			      0x1fff, 4)
954 #define IE5_SET_TX_DESC_LEN0(txdesc_ie, value)                                 \
955 	HALMAC_SET_DESC_FIELD_CLR(                                             \
956 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1fff,   \
957 		4)
958 #define IE5_SET_TX_DESC_LEN0_NO_CLR(txdesc_ie, value)                          \
959 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
960 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0x1fff,   \
961 		4)
962 #define IE5_GET_TX_DESC_PKT_NUM(txdesc_ie)                                     \
963 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword0,    \
964 			      0xf, 0)
965 #define IE5_SET_TX_DESC_PKT_NUM(txdesc_ie, value)                              \
966 	HALMAC_SET_DESC_FIELD_CLR(                                             \
967 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 0)
968 #define IE5_SET_TX_DESC_PKT_NUM_NO_CLR(txdesc_ie, value)                       \
969 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
970 		((struct halmac_tx_desc *)txdesc_ie)->dword0, value, 0xf, 0)
971 #define IE5_GET_TX_DESC_LEN3(txdesc_ie)                                        \
972 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
973 			      0x1fff, 19)
974 #define IE5_SET_TX_DESC_LEN3(txdesc_ie, value)                                 \
975 	HALMAC_SET_DESC_FIELD_CLR(                                             \
976 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1fff,   \
977 		19)
978 #define IE5_SET_TX_DESC_LEN3_NO_CLR(txdesc_ie, value)                          \
979 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
980 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1fff,   \
981 		19)
982 #define IE5_GET_TX_DESC_LEN2(txdesc_ie)                                        \
983 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
984 			      0x1fff, 6)
985 #define IE5_SET_TX_DESC_LEN2(txdesc_ie, value)                                 \
986 	HALMAC_SET_DESC_FIELD_CLR(                                             \
987 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1fff,   \
988 		6)
989 #define IE5_SET_TX_DESC_LEN2_NO_CLR(txdesc_ie, value)                          \
990 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
991 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x1fff,   \
992 		6)
993 #define IE5_GET_TX_DESC_LEN1_H(txdesc_ie)                                      \
994 	HALMAC_GET_DESC_FIELD(((struct halmac_tx_desc *)txdesc_ie)->dword1,    \
995 			      0x3f, 0)
996 #define IE5_SET_TX_DESC_LEN1_H(txdesc_ie, value)                               \
997 	HALMAC_SET_DESC_FIELD_CLR(                                             \
998 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3f, 0)
999 #define IE5_SET_TX_DESC_LEN1_H_NO_CLR(txdesc_ie, value)                        \
1000 	HALMAC_SET_DESC_FIELD_NO_CLR(                                          \
1001 		((struct halmac_tx_desc *)txdesc_ie)->dword1, value, 0x3f, 0)
1002 
1003 #endif
1004 
1005 #endif
1006