1 // SPDX-License-Identifier: GPL-2.0
2 /******************************************************************************
3 *
4 * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
5 *
6 ******************************************************************************/
7
8 #include <linux/kernel.h>
9 #include "odm_precomp.h"
10
CheckPositive(struct dm_odm_t * pDM_Odm,const u32 Condition1,const u32 Condition2)11 static bool CheckPositive(
12 struct dm_odm_t *pDM_Odm, const u32 Condition1, const u32 Condition2
13 )
14 {
15 u8 _BoardType =
16 ((pDM_Odm->BoardType & BIT4) >> 4) << 0 | /* _GLNA */
17 ((pDM_Odm->BoardType & BIT3) >> 3) << 1 | /* _GPA */
18 ((pDM_Odm->BoardType & BIT7) >> 7) << 2 | /* _ALNA */
19 ((pDM_Odm->BoardType & BIT6) >> 6) << 3 | /* _APA */
20 ((pDM_Odm->BoardType & BIT2) >> 2) << 4; /* _BT */
21
22 u32 cond1 = Condition1, cond2 = Condition2;
23 u32 driver1 =
24 pDM_Odm->CutVersion << 24 |
25 pDM_Odm->SupportPlatform << 16 |
26 pDM_Odm->PackageType << 12 |
27 pDM_Odm->SupportInterface << 8 |
28 _BoardType;
29
30 u32 driver2 =
31 pDM_Odm->TypeGLNA << 0 |
32 pDM_Odm->TypeGPA << 8 |
33 pDM_Odm->TypeALNA << 16 |
34 pDM_Odm->TypeAPA << 24;
35
36 /* Value Defined Check =============== */
37 /* QFN Type [15:12] and Cut Version [27:24] need to do value check */
38
39 if (
40 ((cond1 & 0x0000F000) != 0) &&
41 ((cond1 & 0x0000F000) != (driver1 & 0x0000F000))
42 )
43 return false;
44
45 if (
46 ((cond1 & 0x0F000000) != 0) &&
47 ((cond1 & 0x0F000000) != (driver1 & 0x0F000000))
48 )
49 return false;
50
51 /* Bit Defined Check ================ */
52 /* We don't care [31:28] and [23:20] */
53 cond1 &= 0x000F0FFF;
54 driver1 &= 0x000F0FFF;
55
56 if ((cond1 & driver1) == cond1) {
57 u32 bitMask = 0;
58
59 if ((cond1 & 0x0F) == 0) /* BoardType is DONTCARE */
60 return true;
61
62 if ((cond1 & BIT0) != 0) /* GLNA */
63 bitMask |= 0x000000FF;
64 if ((cond1 & BIT1) != 0) /* GPA */
65 bitMask |= 0x0000FF00;
66 if ((cond1 & BIT2) != 0) /* ALNA */
67 bitMask |= 0x00FF0000;
68 if ((cond1 & BIT3) != 0) /* APA */
69 bitMask |= 0xFF000000;
70
71 /* BoardType of each RF path is matched */
72 if ((cond2 & bitMask) == (driver2 & bitMask))
73 return true;
74
75 return false;
76 }
77
78 return false;
79 }
80
81 /******************************************************************************
82 * RadioA.TXT
83 ******************************************************************************/
84
85 static u32 Array_MP_8723B_RadioA[] = {
86 0x000, 0x00010000,
87 0x0B0, 0x000DFFE0,
88 0x0FE, 0x00000000,
89 0x0FE, 0x00000000,
90 0x0FE, 0x00000000,
91 0x0B1, 0x00000018,
92 0x0FE, 0x00000000,
93 0x0FE, 0x00000000,
94 0x0FE, 0x00000000,
95 0x0B2, 0x00084C00,
96 0x0B5, 0x0000D2CC,
97 0x0B6, 0x000925AA,
98 0x0B7, 0x00000010,
99 0x0B8, 0x0000907F,
100 0x05C, 0x00000002,
101 0x07C, 0x00000002,
102 0x07E, 0x00000005,
103 0x08B, 0x0006FC00,
104 0x0B0, 0x000FF9F0,
105 0x01C, 0x000739D2,
106 0x01E, 0x00000000,
107 0x0DF, 0x00000780,
108 0x050, 0x00067435,
109 0x80002000, 0x00000000, 0x40000000, 0x00000000,
110 0x051, 0x0006B10E,
111 0x90003000, 0x00000000, 0x40000000, 0x00000000,
112 0x051, 0x0006B10E,
113 0x90004000, 0x00000000, 0x40000000, 0x00000000,
114 0x051, 0x0006B10E,
115 0xA0000000, 0x00000000,
116 0x051, 0x0006B04E,
117 0xB0000000, 0x00000000,
118 0x052, 0x000007D2,
119 0x053, 0x00000000,
120 0x054, 0x00050400,
121 0x055, 0x0004026E,
122 0x0DD, 0x0000004C,
123 0x070, 0x00067435,
124 0x80002000, 0x00000000, 0x40000000, 0x00000000,
125 0x071, 0x0006B10E,
126 0x90003000, 0x00000000, 0x40000000, 0x00000000,
127 0x071, 0x0006B10E,
128 0x90004000, 0x00000000, 0x40000000, 0x00000000,
129 0x071, 0x0006B10E,
130 0xA0000000, 0x00000000,
131 0x071, 0x0006B04E,
132 0xB0000000, 0x00000000,
133 0x072, 0x000007D2,
134 0x073, 0x00000000,
135 0x074, 0x00050400,
136 0x075, 0x0004026E,
137 0x0EF, 0x00000100,
138 0x034, 0x0000ADD7,
139 0x035, 0x00005C00,
140 0x034, 0x00009DD4,
141 0x035, 0x00005000,
142 0x034, 0x00008DD1,
143 0x035, 0x00004400,
144 0x034, 0x00007DCE,
145 0x035, 0x00003800,
146 0x034, 0x00006CD1,
147 0x035, 0x00004400,
148 0x034, 0x00005CCE,
149 0x035, 0x00003800,
150 0x034, 0x000048CE,
151 0x035, 0x00004400,
152 0x034, 0x000034CE,
153 0x035, 0x00003800,
154 0x034, 0x00002451,
155 0x035, 0x00004400,
156 0x034, 0x0000144E,
157 0x035, 0x00003800,
158 0x034, 0x00000051,
159 0x035, 0x00004400,
160 0x0EF, 0x00000000,
161 0x0EF, 0x00000100,
162 0x0ED, 0x00000010,
163 0x044, 0x0000ADD7,
164 0x044, 0x00009DD4,
165 0x044, 0x00008DD1,
166 0x044, 0x00007DCE,
167 0x044, 0x00006CC1,
168 0x044, 0x00005CCE,
169 0x044, 0x000044D1,
170 0x044, 0x000034CE,
171 0x044, 0x00002451,
172 0x044, 0x0000144E,
173 0x044, 0x00000051,
174 0x0EF, 0x00000000,
175 0x0ED, 0x00000000,
176 0x07F, 0x00020080,
177 0x0EF, 0x00002000,
178 0x03B, 0x000380EF,
179 0x03B, 0x000302FE,
180 0x03B, 0x00028CE6,
181 0x03B, 0x000200BC,
182 0x03B, 0x000188A5,
183 0x03B, 0x00010FBC,
184 0x03B, 0x00008F71,
185 0x03B, 0x00000900,
186 0x0EF, 0x00000000,
187 0x0ED, 0x00000001,
188 0x040, 0x000380EF,
189 0x040, 0x000302FE,
190 0x040, 0x00028CE6,
191 0x040, 0x000200BC,
192 0x040, 0x000188A5,
193 0x040, 0x00010FBC,
194 0x040, 0x00008F71,
195 0x040, 0x00000900,
196 0x0ED, 0x00000000,
197 0x082, 0x00080000,
198 0x083, 0x00008000,
199 0x084, 0x00048D80,
200 0x085, 0x00068000,
201 0x0A2, 0x00080000,
202 0x0A3, 0x00008000,
203 0x0A4, 0x00048D80,
204 0x0A5, 0x00068000,
205 0x0ED, 0x00000002,
206 0x0EF, 0x00000002,
207 0x056, 0x00000032,
208 0x076, 0x00000032,
209 0x001, 0x00000780,
210
211 };
212
ODM_ReadAndConfig_MP_8723B_RadioA(struct dm_odm_t * pDM_Odm)213 void ODM_ReadAndConfig_MP_8723B_RadioA(struct dm_odm_t *pDM_Odm)
214 {
215 u32 i = 0;
216 u32 ArrayLen = ARRAY_SIZE(Array_MP_8723B_RadioA);
217 u32 *Array = Array_MP_8723B_RadioA;
218
219 for (i = 0; i < ArrayLen; i += 2) {
220 u32 v1 = Array[i];
221 u32 v2 = Array[i+1];
222
223 /* This (offset, data) pair doesn't care the condition. */
224 if (v1 < 0x40000000) {
225 odm_ConfigRF_RadioA_8723B(pDM_Odm, v1, v2);
226 continue;
227 } else {
228 /* This line is the beginning of branch. */
229 bool bMatched = true;
230 u8 cCond = (u8)((v1 & (BIT29|BIT28)) >> 28);
231
232 if (cCond == COND_ELSE) { /* ELSE, ENDIF */
233 bMatched = true;
234 READ_NEXT_PAIR(v1, v2, i);
235 } else if (!CheckPositive(pDM_Odm, v1, v2)) {
236 bMatched = false;
237 READ_NEXT_PAIR(v1, v2, i);
238 READ_NEXT_PAIR(v1, v2, i);
239 } else {
240 READ_NEXT_PAIR(v1, v2, i);
241 bMatched = true;
242 READ_NEXT_PAIR(v1, v2, i);
243 }
244
245 if (!bMatched) {
246 /* Condition isn't matched.
247 * Discard the following (offset, data) pairs.
248 */
249 while (v1 < 0x40000000 && i < ArrayLen-2)
250 READ_NEXT_PAIR(v1, v2, i);
251
252 i -= 2; /* prevent from for-loop += 2 */
253 } else {
254 /* Configure matched pairs and skip to end of if-else. */
255 while (v1 < 0x40000000 && i < ArrayLen-2) {
256 odm_ConfigRF_RadioA_8723B(pDM_Odm, v1, v2);
257 READ_NEXT_PAIR(v1, v2, i);
258 }
259
260 /* Keeps reading until ENDIF. */
261 cCond = (u8)((v1 & (BIT29|BIT28)) >> 28);
262 while (cCond != COND_ENDIF && i < ArrayLen-2) {
263 READ_NEXT_PAIR(v1, v2, i);
264 cCond = (u8)((v1 & (BIT29|BIT28)) >> 28);
265 }
266 }
267 }
268 }
269 }
270
271 /******************************************************************************
272 * TxPowerTrack_SDIO.TXT
273 ******************************************************************************/
274
275 static u8 gDeltaSwingTableIdx_MP_2GB_N_TxPowerTrack_SDIO_8723B[] = {
276 0, 0, 1, 2, 2, 2, 3, 3, 3, 4, 5, 5, 6, 6, 6, 6,
277 7, 7, 7, 8, 8, 9, 9, 10, 10, 11, 12, 13, 14, 15
278 };
279 static u8 gDeltaSwingTableIdx_MP_2GB_P_TxPowerTrack_SDIO_8723B[] = {
280 0, 0, 1, 2, 2, 3, 3, 4, 5, 5, 6, 6, 7, 7, 8, 8,
281 9, 9, 10, 10, 10, 11, 11, 12, 12, 13, 13, 14, 15, 15
282 };
283 static u8 gDeltaSwingTableIdx_MP_2GA_N_TxPowerTrack_SDIO_8723B[] = {
284 0, 0, 1, 2, 2, 2, 3, 3, 3, 4, 5, 5, 6, 6, 6, 6,
285 7, 7, 7, 8, 8, 9, 9, 10, 10, 11, 12, 13, 14, 15
286 };
287 static u8 gDeltaSwingTableIdx_MP_2GA_P_TxPowerTrack_SDIO_8723B[] = {
288 0, 0, 1, 2, 2, 3, 3, 4, 5, 5, 6, 6, 7, 7, 8, 8,
289 9, 9, 10, 10, 10, 11, 11, 12, 12, 13, 13, 14, 15, 15
290 };
291 static u8 gDeltaSwingTableIdx_MP_2GCCKB_N_TxPowerTrack_SDIO_8723B[] = {
292 0, 0, 1, 2, 2, 3, 3, 4, 4, 5, 6, 6, 7, 7, 7, 8,
293 8, 8, 9, 9, 9, 10, 10, 11, 11, 12, 12, 13, 14, 15
294 };
295 static u8 gDeltaSwingTableIdx_MP_2GCCKB_P_TxPowerTrack_SDIO_8723B[] = {
296 0, 0, 1, 2, 2, 2, 3, 3, 3, 4, 5, 5, 6, 6, 7, 7,
297 8, 8, 9, 9, 9, 10, 10, 11, 11, 12, 12, 13, 14, 15
298 };
299 static u8 gDeltaSwingTableIdx_MP_2GCCKA_N_TxPowerTrack_SDIO_8723B[] = {
300 0, 0, 1, 2, 2, 3, 3, 4, 4, 5, 6, 6, 7, 7, 7, 8,
301 8, 8, 9, 9, 9, 10, 10, 11, 11, 12, 12, 13, 14, 15
302 };
303 static u8 gDeltaSwingTableIdx_MP_2GCCKA_P_TxPowerTrack_SDIO_8723B[] = {
304 0, 0, 1, 2, 2, 2, 3, 3, 3, 4, 5, 5, 6, 6, 7, 7,
305 8, 8, 9, 9, 9, 10, 10, 11, 11, 12, 12, 13, 14, 15
306 };
307
ODM_ReadAndConfig_MP_8723B_TxPowerTrack_SDIO(struct dm_odm_t * pDM_Odm)308 void ODM_ReadAndConfig_MP_8723B_TxPowerTrack_SDIO(struct dm_odm_t *pDM_Odm)
309 {
310 struct odm_rf_cal_t *pRFCalibrateInfo = &pDM_Odm->RFCalibrateInfo;
311
312
313 memcpy(
314 pRFCalibrateInfo->DeltaSwingTableIdx_2GA_P,
315 gDeltaSwingTableIdx_MP_2GA_P_TxPowerTrack_SDIO_8723B,
316 DELTA_SWINGIDX_SIZE
317 );
318 memcpy(
319 pRFCalibrateInfo->DeltaSwingTableIdx_2GA_N,
320 gDeltaSwingTableIdx_MP_2GA_N_TxPowerTrack_SDIO_8723B,
321 DELTA_SWINGIDX_SIZE
322 );
323 memcpy(
324 pRFCalibrateInfo->DeltaSwingTableIdx_2GB_P,
325 gDeltaSwingTableIdx_MP_2GB_P_TxPowerTrack_SDIO_8723B,
326 DELTA_SWINGIDX_SIZE
327 );
328 memcpy(
329 pRFCalibrateInfo->DeltaSwingTableIdx_2GB_N,
330 gDeltaSwingTableIdx_MP_2GB_N_TxPowerTrack_SDIO_8723B,
331 DELTA_SWINGIDX_SIZE
332 );
333
334 memcpy(
335 pRFCalibrateInfo->DeltaSwingTableIdx_2GCCKA_P,
336 gDeltaSwingTableIdx_MP_2GCCKA_P_TxPowerTrack_SDIO_8723B,
337 DELTA_SWINGIDX_SIZE
338 );
339 memcpy(
340 pRFCalibrateInfo->DeltaSwingTableIdx_2GCCKA_N,
341 gDeltaSwingTableIdx_MP_2GCCKA_N_TxPowerTrack_SDIO_8723B,
342 DELTA_SWINGIDX_SIZE
343 );
344 memcpy(
345 pRFCalibrateInfo->DeltaSwingTableIdx_2GCCKB_P,
346 gDeltaSwingTableIdx_MP_2GCCKB_P_TxPowerTrack_SDIO_8723B,
347 DELTA_SWINGIDX_SIZE
348 );
349 memcpy(
350 pRFCalibrateInfo->DeltaSwingTableIdx_2GCCKB_N,
351 gDeltaSwingTableIdx_MP_2GCCKB_N_TxPowerTrack_SDIO_8723B,
352 DELTA_SWINGIDX_SIZE
353 );
354 }
355
356 /******************************************************************************
357 * TXPWR_LMT.TXT
358 ******************************************************************************/
359
360 static u8 *Array_MP_8723B_TXPWR_LMT[] = {
361 "FCC", "20M", "CCK", "1T", "01", "32",
362 "ETSI", "20M", "CCK", "1T", "01", "32",
363 "MKK", "20M", "CCK", "1T", "01", "32",
364 "FCC", "20M", "CCK", "1T", "02", "32",
365 "ETSI", "20M", "CCK", "1T", "02", "32",
366 "MKK", "20M", "CCK", "1T", "02", "32",
367 "FCC", "20M", "CCK", "1T", "03", "32",
368 "ETSI", "20M", "CCK", "1T", "03", "32",
369 "MKK", "20M", "CCK", "1T", "03", "32",
370 "FCC", "20M", "CCK", "1T", "04", "32",
371 "ETSI", "20M", "CCK", "1T", "04", "32",
372 "MKK", "20M", "CCK", "1T", "04", "32",
373 "FCC", "20M", "CCK", "1T", "05", "32",
374 "ETSI", "20M", "CCK", "1T", "05", "32",
375 "MKK", "20M", "CCK", "1T", "05", "32",
376 "FCC", "20M", "CCK", "1T", "06", "32",
377 "ETSI", "20M", "CCK", "1T", "06", "32",
378 "MKK", "20M", "CCK", "1T", "06", "32",
379 "FCC", "20M", "CCK", "1T", "07", "32",
380 "ETSI", "20M", "CCK", "1T", "07", "32",
381 "MKK", "20M", "CCK", "1T", "07", "32",
382 "FCC", "20M", "CCK", "1T", "08", "32",
383 "ETSI", "20M", "CCK", "1T", "08", "32",
384 "MKK", "20M", "CCK", "1T", "08", "32",
385 "FCC", "20M", "CCK", "1T", "09", "32",
386 "ETSI", "20M", "CCK", "1T", "09", "32",
387 "MKK", "20M", "CCK", "1T", "09", "32",
388 "FCC", "20M", "CCK", "1T", "10", "32",
389 "ETSI", "20M", "CCK", "1T", "10", "32",
390 "MKK", "20M", "CCK", "1T", "10", "32",
391 "FCC", "20M", "CCK", "1T", "11", "32",
392 "ETSI", "20M", "CCK", "1T", "11", "32",
393 "MKK", "20M", "CCK", "1T", "11", "32",
394 "FCC", "20M", "CCK", "1T", "12", "63",
395 "ETSI", "20M", "CCK", "1T", "12", "32",
396 "MKK", "20M", "CCK", "1T", "12", "32",
397 "FCC", "20M", "CCK", "1T", "13", "63",
398 "ETSI", "20M", "CCK", "1T", "13", "32",
399 "MKK", "20M", "CCK", "1T", "13", "32",
400 "FCC", "20M", "CCK", "1T", "14", "63",
401 "ETSI", "20M", "CCK", "1T", "14", "63",
402 "MKK", "20M", "CCK", "1T", "14", "32",
403 "FCC", "20M", "OFDM", "1T", "01", "28",
404 "ETSI", "20M", "OFDM", "1T", "01", "32",
405 "MKK", "20M", "OFDM", "1T", "01", "32",
406 "FCC", "20M", "OFDM", "1T", "02", "28",
407 "ETSI", "20M", "OFDM", "1T", "02", "32",
408 "MKK", "20M", "OFDM", "1T", "02", "32",
409 "FCC", "20M", "OFDM", "1T", "03", "32",
410 "ETSI", "20M", "OFDM", "1T", "03", "32",
411 "MKK", "20M", "OFDM", "1T", "03", "32",
412 "FCC", "20M", "OFDM", "1T", "04", "32",
413 "ETSI", "20M", "OFDM", "1T", "04", "32",
414 "MKK", "20M", "OFDM", "1T", "04", "32",
415 "FCC", "20M", "OFDM", "1T", "05", "32",
416 "ETSI", "20M", "OFDM", "1T", "05", "32",
417 "MKK", "20M", "OFDM", "1T", "05", "32",
418 "FCC", "20M", "OFDM", "1T", "06", "32",
419 "ETSI", "20M", "OFDM", "1T", "06", "32",
420 "MKK", "20M", "OFDM", "1T", "06", "32",
421 "FCC", "20M", "OFDM", "1T", "07", "32",
422 "ETSI", "20M", "OFDM", "1T", "07", "32",
423 "MKK", "20M", "OFDM", "1T", "07", "32",
424 "FCC", "20M", "OFDM", "1T", "08", "32",
425 "ETSI", "20M", "OFDM", "1T", "08", "32",
426 "MKK", "20M", "OFDM", "1T", "08", "32",
427 "FCC", "20M", "OFDM", "1T", "09", "32",
428 "ETSI", "20M", "OFDM", "1T", "09", "32",
429 "MKK", "20M", "OFDM", "1T", "09", "32",
430 "FCC", "20M", "OFDM", "1T", "10", "28",
431 "ETSI", "20M", "OFDM", "1T", "10", "32",
432 "MKK", "20M", "OFDM", "1T", "10", "32",
433 "FCC", "20M", "OFDM", "1T", "11", "28",
434 "ETSI", "20M", "OFDM", "1T", "11", "32",
435 "MKK", "20M", "OFDM", "1T", "11", "32",
436 "FCC", "20M", "OFDM", "1T", "12", "63",
437 "ETSI", "20M", "OFDM", "1T", "12", "32",
438 "MKK", "20M", "OFDM", "1T", "12", "32",
439 "FCC", "20M", "OFDM", "1T", "13", "63",
440 "ETSI", "20M", "OFDM", "1T", "13", "32",
441 "MKK", "20M", "OFDM", "1T", "13", "32",
442 "FCC", "20M", "OFDM", "1T", "14", "63",
443 "ETSI", "20M", "OFDM", "1T", "14", "63",
444 "MKK", "20M", "OFDM", "1T", "14", "63",
445 "FCC", "20M", "HT", "1T", "01", "26",
446 "ETSI", "20M", "HT", "1T", "01", "32",
447 "MKK", "20M", "HT", "1T", "01", "32",
448 "FCC", "20M", "HT", "1T", "02", "26",
449 "ETSI", "20M", "HT", "1T", "02", "32",
450 "MKK", "20M", "HT", "1T", "02", "32",
451 "FCC", "20M", "HT", "1T", "03", "32",
452 "ETSI", "20M", "HT", "1T", "03", "32",
453 "MKK", "20M", "HT", "1T", "03", "32",
454 "FCC", "20M", "HT", "1T", "04", "32",
455 "ETSI", "20M", "HT", "1T", "04", "32",
456 "MKK", "20M", "HT", "1T", "04", "32",
457 "FCC", "20M", "HT", "1T", "05", "32",
458 "ETSI", "20M", "HT", "1T", "05", "32",
459 "MKK", "20M", "HT", "1T", "05", "32",
460 "FCC", "20M", "HT", "1T", "06", "32",
461 "ETSI", "20M", "HT", "1T", "06", "32",
462 "MKK", "20M", "HT", "1T", "06", "32",
463 "FCC", "20M", "HT", "1T", "07", "32",
464 "ETSI", "20M", "HT", "1T", "07", "32",
465 "MKK", "20M", "HT", "1T", "07", "32",
466 "FCC", "20M", "HT", "1T", "08", "32",
467 "ETSI", "20M", "HT", "1T", "08", "32",
468 "MKK", "20M", "HT", "1T", "08", "32",
469 "FCC", "20M", "HT", "1T", "09", "32",
470 "ETSI", "20M", "HT", "1T", "09", "32",
471 "MKK", "20M", "HT", "1T", "09", "32",
472 "FCC", "20M", "HT", "1T", "10", "26",
473 "ETSI", "20M", "HT", "1T", "10", "32",
474 "MKK", "20M", "HT", "1T", "10", "32",
475 "FCC", "20M", "HT", "1T", "11", "26",
476 "ETSI", "20M", "HT", "1T", "11", "32",
477 "MKK", "20M", "HT", "1T", "11", "32",
478 "FCC", "20M", "HT", "1T", "12", "63",
479 "ETSI", "20M", "HT", "1T", "12", "32",
480 "MKK", "20M", "HT", "1T", "12", "32",
481 "FCC", "20M", "HT", "1T", "13", "63",
482 "ETSI", "20M", "HT", "1T", "13", "32",
483 "MKK", "20M", "HT", "1T", "13", "32",
484 "FCC", "20M", "HT", "1T", "14", "63",
485 "ETSI", "20M", "HT", "1T", "14", "63",
486 "MKK", "20M", "HT", "1T", "14", "63",
487 "FCC", "40M", "HT", "1T", "01", "63",
488 "ETSI", "40M", "HT", "1T", "01", "63",
489 "MKK", "40M", "HT", "1T", "01", "63",
490 "FCC", "40M", "HT", "1T", "02", "63",
491 "ETSI", "40M", "HT", "1T", "02", "63",
492 "MKK", "40M", "HT", "1T", "02", "63",
493 "FCC", "40M", "HT", "1T", "03", "26",
494 "ETSI", "40M", "HT", "1T", "03", "32",
495 "MKK", "40M", "HT", "1T", "03", "32",
496 "FCC", "40M", "HT", "1T", "04", "26",
497 "ETSI", "40M", "HT", "1T", "04", "32",
498 "MKK", "40M", "HT", "1T", "04", "32",
499 "FCC", "40M", "HT", "1T", "05", "32",
500 "ETSI", "40M", "HT", "1T", "05", "32",
501 "MKK", "40M", "HT", "1T", "05", "32",
502 "FCC", "40M", "HT", "1T", "06", "32",
503 "ETSI", "40M", "HT", "1T", "06", "32",
504 "MKK", "40M", "HT", "1T", "06", "32",
505 "FCC", "40M", "HT", "1T", "07", "32",
506 "ETSI", "40M", "HT", "1T", "07", "32",
507 "MKK", "40M", "HT", "1T", "07", "32",
508 "FCC", "40M", "HT", "1T", "08", "26",
509 "ETSI", "40M", "HT", "1T", "08", "32",
510 "MKK", "40M", "HT", "1T", "08", "32",
511 "FCC", "40M", "HT", "1T", "09", "26",
512 "ETSI", "40M", "HT", "1T", "09", "32",
513 "MKK", "40M", "HT", "1T", "09", "32",
514 "FCC", "40M", "HT", "1T", "10", "26",
515 "ETSI", "40M", "HT", "1T", "10", "32",
516 "MKK", "40M", "HT", "1T", "10", "32",
517 "FCC", "40M", "HT", "1T", "11", "26",
518 "ETSI", "40M", "HT", "1T", "11", "32",
519 "MKK", "40M", "HT", "1T", "11", "32",
520 "FCC", "40M", "HT", "1T", "12", "63",
521 "ETSI", "40M", "HT", "1T", "12", "32",
522 "MKK", "40M", "HT", "1T", "12", "32",
523 "FCC", "40M", "HT", "1T", "13", "63",
524 "ETSI", "40M", "HT", "1T", "13", "32",
525 "MKK", "40M", "HT", "1T", "13", "32",
526 "FCC", "40M", "HT", "1T", "14", "63",
527 "ETSI", "40M", "HT", "1T", "14", "63",
528 "MKK", "40M", "HT", "1T", "14", "63"
529 };
530
ODM_ReadAndConfig_MP_8723B_TXPWR_LMT(struct dm_odm_t * pDM_Odm)531 void ODM_ReadAndConfig_MP_8723B_TXPWR_LMT(struct dm_odm_t *pDM_Odm)
532 {
533 u32 i = 0;
534 u8 **Array = Array_MP_8723B_TXPWR_LMT;
535
536 for (i = 0; i < ARRAY_SIZE(Array_MP_8723B_TXPWR_LMT); i += 6) {
537 u8 *regulation = Array[i];
538 u8 *bandwidth = Array[i+1];
539 u8 *rate = Array[i+2];
540 u8 *rfPath = Array[i+3];
541 u8 *chnl = Array[i+4];
542 u8 *val = Array[i+5];
543
544 odm_ConfigBB_TXPWR_LMT_8723B(
545 pDM_Odm,
546 regulation,
547 bandwidth,
548 rate,
549 rfPath,
550 chnl,
551 val
552 );
553 }
554 }
555