summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/mt6359.h
blob: 296ffa7f50b5226a47fb852e1015f306892e443a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
/* SPDX-License-Identifier: GPL-2.0 */
/*
 * Copyright (C) 2020 MediaTek Inc.
 * Author: Argus Lin <argus.lin@mediatek.com>
 */

#ifndef _MT6359_H_
#define _MT6359_H_

/*************Register Bit Define*************/
#define MT6359_TOP0_ID                       0x0
#define MT6359_SMT_CON1                      0x32
#define MT6359_DRV_CON2                      0x3c
#define MT6359_DRV_CON3                      0x3e
#define MT6359_DRV_CON4                      0x40
#define MT6359_TOP_CKPDN_CON0                0x10c
#define MT6359_TOP_CKPDN_CON0_SET            0x10e
#define MT6359_TOP_CKPDN_CON0_CLR            0x110
#define MT6359_AUXADC_RQST0                  0x1108
#define MT6359_AUXADC_CON10                  0x11a0
#define MT6359_AUXADC_ACCDET                 0x11ba
#define MT6359_LDO_VUSB_OP_EN                0x1d0c
#define MT6359_LDO_VUSB_OP_EN_SET            0x1d0e
#define MT6359_LDO_VUSB_OP_EN_CLR            0x1d10
#define MT6359_AUD_TOP_CKPDN_CON0            0x230c
#define MT6359_AUD_TOP_CKPDN_CON0_SET        0x230e
#define MT6359_AUD_TOP_CKPDN_CON0_CLR        0x2310
#define MT6359_AUD_TOP_RST_CON0              0x2320
#define MT6359_AUD_TOP_RST_CON0_SET          0x2322
#define MT6359_AUD_TOP_RST_CON0_CLR          0x2324
#define MT6359_AUD_TOP_INT_CON0              0x2328
#define MT6359_AUD_TOP_INT_CON0_SET          0x232a
#define MT6359_AUD_TOP_INT_CON0_CLR          0x232c
#define MT6359_AUD_TOP_INT_MASK_CON0         0x232e
#define MT6359_AUD_TOP_INT_MASK_CON0_SET     0x2330
#define MT6359_AUD_TOP_INT_MASK_CON0_CLR     0x2332
#define MT6359_AUD_TOP_INT_STATUS0           0x2334
#define MT6359_AFE_NCP_CFG2                  0x24e2
#define MT6359_AUDENC_DSN_ID                 0x2500
#define MT6359_AUDENC_DSN_REV0               0x2502
#define MT6359_AUDENC_DSN_DBI                0x2504
#define MT6359_AUDENC_DSN_FPI                0x2506
#define MT6359_AUDENC_ANA_CON0               0x2508
#define MT6359_AUDENC_ANA_CON1               0x250a
#define MT6359_AUDENC_ANA_CON2               0x250c
#define MT6359_AUDENC_ANA_CON3               0x250e
#define MT6359_AUDENC_ANA_CON4               0x2510
#define MT6359_AUDENC_ANA_CON5               0x2512
#define MT6359_AUDENC_ANA_CON6               0x2514
#define MT6359_AUDENC_ANA_CON7               0x2516
#define MT6359_AUDENC_ANA_CON8               0x2518
#define MT6359_AUDENC_ANA_CON9               0x251a
#define MT6359_AUDENC_ANA_CON10              0x251c
#define MT6359_AUDENC_ANA_CON11              0x251e
#define MT6359_AUDENC_ANA_CON12              0x2520
#define MT6359_AUDENC_ANA_CON13              0x2522
#define MT6359_AUDENC_ANA_CON14              0x2524
#define MT6359_AUDENC_ANA_CON15              0x2526
#define MT6359_AUDENC_ANA_CON16              0x2528
#define MT6359_AUDENC_ANA_CON17              0x252a
#define MT6359_AUDENC_ANA_CON18              0x252c
#define MT6359_AUDENC_ANA_CON19              0x252e
#define MT6359_AUDENC_ANA_CON20              0x2530
#define MT6359_AUDENC_ANA_CON21              0x2532
#define MT6359_AUDENC_ANA_CON22              0x2534
#define MT6359_AUDENC_ANA_CON23              0x2536
#define MT6359_AUDDEC_DSN_ID                 0x2580
#define MT6359_AUDDEC_DSN_REV0               0x2582
#define MT6359_AUDDEC_DSN_DBI                0x2584
#define MT6359_AUDDEC_DSN_FPI                0x2586
#define MT6359_AUDDEC_ANA_CON0               0x2588
#define MT6359_AUDDEC_ANA_CON1               0x258a
#define MT6359_AUDDEC_ANA_CON2               0x258c
#define MT6359_AUDDEC_ANA_CON3               0x258e
#define MT6359_AUDDEC_ANA_CON4               0x2590
#define MT6359_AUDDEC_ANA_CON5               0x2592
#define MT6359_AUDDEC_ANA_CON6               0x2594
#define MT6359_AUDDEC_ANA_CON7               0x2596
#define MT6359_AUDDEC_ANA_CON8               0x2598
#define MT6359_AUDDEC_ANA_CON9               0x259a
#define MT6359_AUDDEC_ANA_CON10              0x259c
#define MT6359_AUDDEC_ANA_CON11              0x259e
#define MT6359_AUDDEC_ANA_CON12              0x25a0
#define MT6359_AUDDEC_ANA_CON13              0x25a2
#define MT6359_AUDDEC_ANA_CON14              0x25a4
#define MT6359_ACCDET_DSN_DIG_ID             0x2680
#define MT6359_ACCDET_DSN_DIG_REV0           0x2682
#define MT6359_ACCDET_DSN_DBI                0x2684
#define MT6359_ACCDET_DSN_FPI                0x2686
#define MT6359_ACCDET_CON0                   0x2688
#define MT6359_ACCDET_CON1                   0x268a
#define MT6359_ACCDET_CON2                   0x268c
#define MT6359_ACCDET_CON3                   0x268e
#define MT6359_ACCDET_CON4                   0x2690
#define MT6359_ACCDET_CON5                   0x2692
#define MT6359_ACCDET_CON6                   0x2694
#define MT6359_ACCDET_CON7                   0x2696
#define MT6359_ACCDET_CON8                   0x2698
#define MT6359_ACCDET_CON9                   0x269a
#define MT6359_ACCDET_CON10                  0x269c
#define MT6359_ACCDET_CON11                  0x269e
#define MT6359_ACCDET_CON12                  0x26a0
#define MT6359_ACCDET_CON13                  0x26a2
#define MT6359_ACCDET_CON14                  0x26a4
#define MT6359_ACCDET_CON15                  0x26a6
#define MT6359_ACCDET_CON16                  0x26a8
#define MT6359_ACCDET_CON17                  0x26aa
#define MT6359_ACCDET_CON18                  0x26ac
#define MT6359_ACCDET_CON19                  0x26ae
#define MT6359_ACCDET_CON20                  0x26b0
#define MT6359_ACCDET_CON21                  0x26b2
#define MT6359_ACCDET_CON22                  0x26b4
#define MT6359_ACCDET_CON23                  0x26b6
#define MT6359_ACCDET_CON24                  0x26b8
#define MT6359_ACCDET_CON25                  0x26ba
#define MT6359_ACCDET_CON26                  0x26bc
#define MT6359_ACCDET_CON27                  0x26be
#define MT6359_ACCDET_CON28                  0x26c0
#define MT6359_ACCDET_CON29                  0x26c2
#define MT6359_ACCDET_CON30                  0x26c4
#define MT6359_ACCDET_CON31                  0x26c6
#define MT6359_ACCDET_CON32                  0x26c8
#define MT6359_ACCDET_CON33                  0x26ca
#define MT6359_ACCDET_CON34                  0x26cc
#define MT6359_ACCDET_CON35                  0x26ce
#define MT6359_ACCDET_CON36                  0x26d0
#define MT6359_ACCDET_CON37                  0x26d2
#define MT6359_ACCDET_CON38                  0x26d4
#define MT6359_ACCDET_CON39                  0x26d6
#define MT6359_ACCDET_CON40                  0x26d8

#define TOP0_ANA_ID_ADDR                               \
	MT6359_TOP0_ID
#define TOP0_ANA_ID_SFT                                0
#define TOP0_ANA_ID_MASK                               0xFF
#define TOP0_ANA_ID_MASK_SFT                           (0xFF << 0)
#define AUXADC_RQST_CH0_ADDR                           \
	MT6359_AUXADC_RQST0
#define AUXADC_RQST_CH0_SFT                            0
#define AUXADC_RQST_CH0_MASK                           0x1
#define AUXADC_RQST_CH0_MASK_SFT                       (0x1 << 0)
#define AUXADC_ACCDET_ANASWCTRL_EN_ADDR                \
	MT6359_AUXADC_CON15
#define AUXADC_ACCDET_ANASWCTRL_EN_SFT                 6
#define AUXADC_ACCDET_ANASWCTRL_EN_MASK                0x1
#define AUXADC_ACCDET_ANASWCTRL_EN_MASK_SFT            (0x1 << 6)

#define AUXADC_ACCDET_AUTO_SPL_ADDR                    \
	MT6359_AUXADC_ACCDET
#define AUXADC_ACCDET_AUTO_SPL_SFT                     0
#define AUXADC_ACCDET_AUTO_SPL_MASK                    0x1
#define AUXADC_ACCDET_AUTO_SPL_MASK_SFT                (0x1 << 0)
#define AUXADC_ACCDET_AUTO_RQST_CLR_ADDR               \
	MT6359_AUXADC_ACCDET
#define AUXADC_ACCDET_AUTO_RQST_CLR_SFT                1
#define AUXADC_ACCDET_AUTO_RQST_CLR_MASK               0x1
#define AUXADC_ACCDET_AUTO_RQST_CLR_MASK_SFT           (0x1 << 1)
#define AUXADC_ACCDET_DIG1_RSV0_ADDR                   \
	MT6359_AUXADC_ACCDET
#define AUXADC_ACCDET_DIG1_RSV0_SFT                    2
#define AUXADC_ACCDET_DIG1_RSV0_MASK                   0x3F
#define AUXADC_ACCDET_DIG1_RSV0_MASK_SFT               (0x3F << 2)
#define AUXADC_ACCDET_DIG0_RSV0_ADDR                   \
	MT6359_AUXADC_ACCDET
#define AUXADC_ACCDET_DIG0_RSV0_SFT                    8
#define AUXADC_ACCDET_DIG0_RSV0_MASK                   0xFF
#define AUXADC_ACCDET_DIG0_RSV0_MASK_SFT               (0xFF << 8)

#define RG_ACCDET_CK_PDN_ADDR                          \
	MT6359_AUD_TOP_CKPDN_CON0
#define RG_ACCDET_CK_PDN_SFT                           0
#define RG_ACCDET_CK_PDN_MASK                          0x1
#define RG_ACCDET_CK_PDN_MASK_SFT                      (0x1 << 0)

#define RG_ACCDET_RST_ADDR                             \
	MT6359_AUD_TOP_RST_CON0
#define RG_ACCDET_RST_SFT                              1
#define RG_ACCDET_RST_MASK                             0x1
#define RG_ACCDET_RST_MASK_SFT                         (0x1 << 1)
#define BANK_ACCDET_SWRST_ADDR                         \
	MT6359_AUD_TOP_RST_BANK_CON0
#define BANK_ACCDET_SWRST_SFT                          0
#define BANK_ACCDET_SWRST_MASK                         0x1
#define BANK_ACCDET_SWRST_MASK_SFT                     (0x1 << 0)

#define RG_INT_EN_ACCDET_ADDR                          \
	MT6359_AUD_TOP_INT_CON0
#define RG_INT_EN_ACCDET_SFT                           5
#define RG_INT_EN_ACCDET_MASK                          0x1
#define RG_INT_EN_ACCDET_MASK_SFT                      (0x1 << 5)
#define RG_INT_EN_ACCDET_EINT0_ADDR                    \
	MT6359_AUD_TOP_INT_CON0
#define RG_INT_EN_ACCDET_EINT0_SFT                     6
#define RG_INT_EN_ACCDET_EINT0_MASK                    0x1
#define RG_INT_EN_ACCDET_EINT0_MASK_SFT                (0x1 << 6)
#define RG_INT_EN_ACCDET_EINT1_ADDR                    \
	MT6359_AUD_TOP_INT_CON0
#define RG_INT_EN_ACCDET_EINT1_SFT                     7
#define RG_INT_EN_ACCDET_EINT1_MASK                    0x1
#define RG_INT_EN_ACCDET_EINT1_MASK_SFT                (0x1 << 7)

#define RG_INT_MASK_ACCDET_ADDR                        \
	MT6359_AUD_TOP_INT_MASK_CON0
#define RG_INT_MASK_ACCDET_SFT                         5
#define RG_INT_MASK_ACCDET_MASK                        0x1
#define RG_INT_MASK_ACCDET_MASK_SFT                    (0x1 << 5)
#define RG_INT_MASK_ACCDET_EINT0_ADDR                  \
	MT6359_AUD_TOP_INT_MASK_CON0
#define RG_INT_MASK_ACCDET_EINT0_SFT                   6
#define RG_INT_MASK_ACCDET_EINT0_MASK                  0x1
#define RG_INT_MASK_ACCDET_EINT0_MASK_SFT              (0x1 << 6)
#define RG_INT_MASK_ACCDET_EINT1_ADDR                  \
	MT6359_AUD_TOP_INT_MASK_CON0
#define RG_INT_MASK_ACCDET_EINT1_SFT                   7
#define RG_INT_MASK_ACCDET_EINT1_MASK                  0x1
#define RG_INT_MASK_ACCDET_EINT1_MASK_SFT              (0x1 << 7)

#define RG_INT_STATUS_ACCDET_ADDR                      \
	MT6359_AUD_TOP_INT_STATUS0
#define RG_INT_STATUS_ACCDET_SFT                       5
#define RG_INT_STATUS_ACCDET_MASK                      0x1
#define RG_INT_STATUS_ACCDET_MASK_SFT                  (0x1 << 5)
#define RG_INT_STATUS_ACCDET_EINT0_ADDR                \
	MT6359_AUD_TOP_INT_STATUS0
#define RG_INT_STATUS_ACCDET_EINT0_SFT                 6
#define RG_INT_STATUS_ACCDET_EINT0_MASK                0x1
#define RG_INT_STATUS_ACCDET_EINT0_MASK_SFT            (0x1 << 6)
#define RG_INT_STATUS_ACCDET_EINT1_ADDR                \
	MT6359_AUD_TOP_INT_STATUS0
#define RG_INT_STATUS_ACCDET_EINT1_SFT                 7
#define RG_INT_STATUS_ACCDET_EINT1_MASK                0x1
#define RG_INT_STATUS_ACCDET_EINT1_MASK_SFT            (0x1 << 7)

#define RG_INT_RAW_STATUS_ACCDET_ADDR                  \
	MT6359_AUD_TOP_INT_RAW_STATUS0
#define RG_INT_RAW_STATUS_ACCDET_SFT                   5
#define RG_INT_RAW_STATUS_ACCDET_MASK                  0x1
#define RG_INT_RAW_STATUS_ACCDET_MASK_SFT              (0x1 << 5)
#define RG_INT_RAW_STATUS_ACCDET_EINT0_ADDR            \
	MT6359_AUD_TOP_INT_RAW_STATUS0
#define RG_INT_RAW_STATUS_ACCDET_EINT0_SFT             6
#define RG_INT_RAW_STATUS_ACCDET_EINT0_MASK            0x1
#define RG_INT_RAW_STATUS_ACCDET_EINT0_MASK_SFT        (0x1 << 6)
#define RG_INT_RAW_STATUS_ACCDET_EINT1_ADDR            \
	MT6359_AUD_TOP_INT_RAW_STATUS0
#define RG_INT_RAW_STATUS_ACCDET_EINT1_SFT             7
#define RG_INT_RAW_STATUS_ACCDET_EINT1_MASK            0x1
#define RG_INT_RAW_STATUS_ACCDET_EINT1_MASK_SFT        (0x1 << 7)

#define RG_AUDACCDETMICBIAS0PULLLOW_ADDR               \
	MT6359_AUDENC_ANA_CON18
#define RG_AUDACCDETMICBIAS0PULLLOW_SFT                0
#define RG_AUDACCDETMICBIAS0PULLLOW_MASK               0x1
#define RG_AUDACCDETMICBIAS0PULLLOW_MASK_SFT           (0x1 << 0)
#define RG_AUDACCDETMICBIAS1PULLLOW_ADDR               \
	MT6359_AUDENC_ANA_CON18
#define RG_AUDACCDETMICBIAS1PULLLOW_SFT                1
#define RG_AUDACCDETMICBIAS1PULLLOW_MASK               0x1
#define RG_AUDACCDETMICBIAS1PULLLOW_MASK_SFT           (0x1 << 1)
#define RG_AUDACCDETMICBIAS2PULLLOW_ADDR               \
	MT6359_AUDENC_ANA_CON18
#define RG_AUDACCDETMICBIAS2PULLLOW_SFT                2
#define RG_AUDACCDETMICBIAS2PULLLOW_MASK               0x1
#define RG_AUDACCDETMICBIAS2PULLLOW_MASK_SFT           (0x1 << 2)
#define RG_AUDACCDETVIN1PULLLOW_ADDR                   \
	MT6359_AUDENC_ANA_CON18
#define RG_AUDACCDETVIN1PULLLOW_SFT                    3
#define RG_AUDACCDETVIN1PULLLOW_MASK                   0x1
#define RG_AUDACCDETVIN1PULLLOW_MASK_SFT               (0x1 << 3)
#define RG_AUDACCDETVTHACAL_ADDR                       \
	MT6359_AUDENC_ANA_CON18
#define RG_AUDACCDETVTHACAL_SFT                        4
#define RG_AUDACCDETVTHACAL_MASK                       0x1
#define RG_AUDACCDETVTHACAL_MASK_SFT                   (0x1 << 4)
#define RG_AUDACCDETVTHBCAL_ADDR                       \
	MT6359_AUDENC_ANA_CON18
#define RG_AUDACCDETVTHBCAL_SFT                        5
#define RG_AUDACCDETVTHBCAL_MASK                       0x1
#define RG_AUDACCDETVTHBCAL_MASK_SFT                   (0x1 << 5)
#define RG_AUDACCDETTVDET_ADDR                         \
	MT6359_AUDENC_ANA_CON18
#define RG_AUDACCDETTVDET_SFT                          6
#define RG_AUDACCDETTVDET_MASK                         0x1
#define RG_AUDACCDETTVDET_MASK_SFT                     (0x1 << 6)
#define RG_ACCDETSEL_ADDR                              \
	MT6359_AUDENC_ANA_CON18
#define RG_ACCDETSEL_SFT                               7
#define RG_ACCDETSEL_MASK                              0x1
#define RG_ACCDETSEL_MASK_SFT                          (0x1 << 7)

#define RG_AUDPWDBMICBIAS1_ADDR                        \
	MT6359_AUDENC_ANA_CON16
#define RG_AUDPWDBMICBIAS1_SFT                         0
#define RG_AUDPWDBMICBIAS1_MASK                        0x1
#define RG_AUDPWDBMICBIAS1_MASK_SFT                    (0x1 << 0)
#define RG_AUDMICBIAS1BYPASSEN_ADDR                    \
	MT6359_AUDENC_ANA_CON16
#define RG_AUDMICBIAS1BYPASSEN_SFT                     1
#define RG_AUDMICBIAS1BYPASSEN_MASK                    0x1
#define RG_AUDMICBIAS1BYPASSEN_MASK_SFT                (0x1 << 1)
#define RG_AUDMICBIAS1LOWPEN_ADDR                      \
	MT6359_AUDENC_ANA_CON16
#define RG_AUDMICBIAS1LOWPEN_SFT                       2
#define RG_AUDMICBIAS1LOWPEN_MASK                      0x1
#define RG_AUDMICBIAS1LOWPEN_MASK_SFT                  (0x1 << 2)
#define RG_AUDMICBIAS1VREF_ADDR                        \
	MT6359_AUDENC_ANA_CON16
#define RG_AUDMICBIAS1VREF_SFT                         4
#define RG_AUDMICBIAS1VREF_MASK                        0x7
#define RG_AUDMICBIAS1VREF_MASK_SFT                    (0x7 << 4)
#define RG_AUDMICBIAS1DCSW1PEN_ADDR                    \
	MT6359_AUDENC_ANA_CON16
#define RG_AUDMICBIAS1DCSW1PEN_SFT                     8
#define RG_AUDMICBIAS1DCSW1PEN_MASK                    0x1
#define RG_AUDMICBIAS1DCSW1PEN_MASK_SFT                (0x1 << 8)
#define RG_AUDMICBIAS1DCSW1NEN_ADDR                    \
	MT6359_AUDENC_ANA_CON16
#define RG_AUDMICBIAS1DCSW1NEN_SFT                     9
#define RG_AUDMICBIAS1DCSW1NEN_MASK                    0x1
#define RG_AUDMICBIAS1DCSW1NEN_MASK_SFT                (0x1 << 9)
#define RG_BANDGAPGEN_ADDR                             \
	MT6359_AUDENC_ANA_CON16
#define RG_BANDGAPGEN_SFT                              10
#define RG_BANDGAPGEN_MASK                             0x1
#define RG_BANDGAPGEN_MASK_SFT                         (0x1 << 10)
#define RG_AUDMICBIAS1HVEN_ADDR                        \
	MT6359_AUDENC_ANA_CON16
#define RG_AUDMICBIAS1HVEN_SFT                         12
#define RG_AUDMICBIAS1HVEN_MASK                        0x1
#define RG_AUDMICBIAS1HVEN_MASK_SFT                    (0x1 << 12)
#define RG_AUDMICBIAS1HVVREF_ADDR                      \
	MT6359_AUDENC_ANA_CON16
#define RG_AUDMICBIAS1HVVREF_SFT                       13
#define RG_AUDMICBIAS1HVVREF_MASK                      0x1
#define RG_AUDMICBIAS1HVVREF_MASK_SFT                  (0x1 << 13)

#define RG_EINT0NOHYS_ADDR                             \
	MT6359_AUDENC_ANA_CON18
#define RG_EINT0NOHYS_SFT                              10
#define RG_EINT0NOHYS_MASK                             0x1
#define RG_EINT0NOHYS_MASK_SFT                         (0x1 << 10)
#define RG_EINT0CONFIGACCDET_ADDR                      \
	MT6359_AUDENC_ANA_CON18
#define RG_EINT0CONFIGACCDET_SFT                       11
#define RG_EINT0CONFIGACCDET_MASK                      0x1
#define RG_EINT0CONFIGACCDET_MASK_SFT                  (0x1 << 11)
#define RG_EINT0HIRENB_ADDR                            \
	MT6359_AUDENC_ANA_CON18
#define RG_EINT0HIRENB_SFT                             12
#define RG_EINT0HIRENB_MASK                            0x1
#define RG_EINT0HIRENB_MASK_SFT                        (0x1 << 12)
#define RG_ACCDET2AUXRESBYPASS_ADDR                    \
	MT6359_AUDENC_ANA_CON18
#define RG_ACCDET2AUXRESBYPASS_SFT                     13
#define RG_ACCDET2AUXRESBYPASS_MASK                    0x1
#define RG_ACCDET2AUXRESBYPASS_MASK_SFT                (0x1 << 13)
#define RG_ACCDET2AUXSWEN_ADDR                         \
	MT6359_AUDENC_ANA_CON18
#define RG_ACCDET2AUXSWEN_SFT                          14
#define RG_ACCDET2AUXSWEN_MASK                         0x1
#define RG_ACCDET2AUXSWEN_MASK_SFT                     (0x1 << 14)
#define RG_AUDACCDETMICBIAS3PULLLOW_ADDR               \
	MT6359_AUDENC_ANA_CON18
#define RG_AUDACCDETMICBIAS3PULLLOW_SFT                15
#define RG_AUDACCDETMICBIAS3PULLLOW_MASK               0x1
#define RG_AUDACCDETMICBIAS3PULLLOW_MASK_SFT           (0x1 << 15)
#define RG_EINT1CONFIGACCDET_ADDR                      \
	MT6359_AUDENC_ANA_CON19
#define RG_EINT1CONFIGACCDET_SFT                       0
#define RG_EINT1CONFIGACCDET_MASK                      0x1
#define RG_EINT1CONFIGACCDET_MASK_SFT                  (0x1 << 0)
#define RG_EINT1HIRENB_ADDR                            \
	MT6359_AUDENC_ANA_CON19
#define RG_EINT1HIRENB_SFT                             1
#define RG_EINT1HIRENB_MASK                            0x1
#define RG_EINT1HIRENB_MASK_SFT                        (0x1 << 1)
#define RG_EINT1NOHYS_ADDR                             \
	MT6359_AUDENC_ANA_CON19
#define RG_EINT1NOHYS_SFT                              2
#define RG_EINT1NOHYS_MASK                             0x1
#define RG_EINT1NOHYS_MASK_SFT                         (0x1 << 2)
#define RG_EINTCOMPVTH_ADDR                            \
	MT6359_AUDENC_ANA_CON19
#define RG_MTEST_EN_ADDR                               \
	MT6359_AUDENC_ANA_CON19
#define RG_MTEST_EN_SFT                                8
#define RG_MTEST_EN_MASK                               0x1
#define RG_MTEST_EN_MASK_SFT                           (0x1 << 8)
#define RG_MTEST_SEL_ADDR                              \
	MT6359_AUDENC_ANA_CON19
#define RG_MTEST_SEL_SFT                               9
#define RG_MTEST_SEL_MASK                              0x1
#define RG_MTEST_SEL_MASK_SFT                          (0x1 << 9)
#define RG_MTEST_CURRENT_ADDR                          \
	MT6359_AUDENC_ANA_CON19
#define RG_MTEST_CURRENT_SFT                           10
#define RG_MTEST_CURRENT_MASK                          0x1
#define RG_MTEST_CURRENT_MASK_SFT                      (0x1 << 10)
#define RG_ANALOGFDEN_ADDR                             \
	MT6359_AUDENC_ANA_CON19
#define RG_ANALOGFDEN_SFT                              12
#define RG_ANALOGFDEN_MASK                             0x1
#define RG_ANALOGFDEN_MASK_SFT                         (0x1 << 12)
#define RG_FDVIN1PPULLLOW_ADDR                         \
	MT6359_AUDENC_ANA_CON19
#define RG_FDVIN1PPULLLOW_SFT                          13
#define RG_FDVIN1PPULLLOW_MASK                         0x1
#define RG_FDVIN1PPULLLOW_MASK_SFT                     (0x1 << 13)
#define RG_FDEINT0TYPE_ADDR                            \
	MT6359_AUDENC_ANA_CON19
#define RG_FDEINT0TYPE_SFT                             14
#define RG_FDEINT0TYPE_MASK                            0x1
#define RG_FDEINT0TYPE_MASK_SFT                        (0x1 << 14)
#define RG_FDEINT1TYPE_ADDR                            \
	MT6359_AUDENC_ANA_CON19
#define RG_FDEINT1TYPE_SFT                             15
#define RG_FDEINT1TYPE_MASK                            0x1
#define RG_FDEINT1TYPE_MASK_SFT                        (0x1 << 15)
#define RG_EINT0CMPEN_ADDR                             \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT0CMPEN_SFT                              0
#define RG_EINT0CMPEN_MASK                             0x1
#define RG_EINT0CMPEN_MASK_SFT                         (0x1 << 0)
#define RG_EINT0CMPMEN_ADDR                            \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT0CMPMEN_SFT                             1
#define RG_EINT0CMPMEN_MASK                            0x1
#define RG_EINT0CMPMEN_MASK_SFT                        (0x1 << 1)
#define RG_EINT0EN_ADDR                                \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT0EN_SFT                                 2
#define RG_EINT0EN_MASK                                0x1
#define RG_EINT0EN_MASK_SFT                            (0x1 << 2)
#define RG_EINT0CEN_ADDR                               \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT0CEN_SFT                                3
#define RG_EINT0CEN_MASK                               0x1
#define RG_EINT0CEN_MASK_SFT                           (0x1 << 3)
#define RG_EINT0INVEN_ADDR                             \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT0INVEN_SFT                              4
#define RG_EINT0INVEN_MASK                             0x1
#define RG_EINT0INVEN_MASK_SFT                         (0x1 << 4)
#define RG_EINT0CTURBO_ADDR                            \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT0CTURBO_SFT                             5
#define RG_EINT0CTURBO_MASK                            0x7
#define RG_EINT0CTURBO_MASK_SFT                        (0x7 << 5)
#define RG_EINT1CMPEN_ADDR                             \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT1CMPEN_SFT                              8
#define RG_EINT1CMPEN_MASK                             0x1
#define RG_EINT1CMPEN_MASK_SFT                         (0x1 << 8)
#define RG_EINT1CMPMEN_ADDR                            \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT1CMPMEN_SFT                             9
#define RG_EINT1CMPMEN_MASK                            0x1
#define RG_EINT1CMPMEN_MASK_SFT                        (0x1 << 9)
#define RG_EINT1EN_ADDR                                \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT1EN_SFT                                 10
#define RG_EINT1EN_MASK                                0x1
#define RG_EINT1EN_MASK_SFT                            (0x1 << 10)
#define RG_EINT1CEN_ADDR                               \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT1CEN_SFT                                11
#define RG_EINT1CEN_MASK                               0x1
#define RG_EINT1CEN_MASK_SFT                           (0x1 << 11)
#define RG_EINT1INVEN_ADDR                             \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT1INVEN_SFT                              12
#define RG_EINT1INVEN_MASK                             0x1
#define RG_EINT1INVEN_MASK_SFT                         (0x1 << 12)
#define RG_EINT1CTURBO_ADDR                            \
	MT6359_AUDENC_ANA_CON20
#define RG_EINT1CTURBO_SFT                             13
#define RG_EINT1CTURBO_MASK                            0x7
#define RG_EINT1CTURBO_MASK_SFT                        (0x7 << 13)
#define RG_ACCDETSPARE_ADDR                            \
	MT6359_AUDENC_ANA_CON21

#define ACCDET_ANA_ID_ADDR                             \
	MT6359_ACCDET_DSN_DIG_ID
#define ACCDET_ANA_ID_SFT                              0
#define ACCDET_ANA_ID_MASK                             0xFF
#define ACCDET_ANA_ID_MASK_SFT                         (0xFF << 0)
#define ACCDET_DIG_ID_ADDR                             \
	MT6359_ACCDET_DSN_DIG_ID
#define ACCDET_DIG_ID_SFT                              8
#define ACCDET_DIG_ID_MASK                             0xFF
#define ACCDET_DIG_ID_MASK_SFT                         (0xFF << 8)
#define ACCDET_ANA_MINOR_REV_ADDR                      \
	MT6359_ACCDET_DSN_DIG_REV0
#define ACCDET_ANA_MINOR_REV_SFT                       0
#define ACCDET_ANA_MINOR_REV_MASK                      0xF
#define ACCDET_ANA_MINOR_REV_MASK_SFT                  (0xF << 0)
#define ACCDET_ANA_MAJOR_REV_ADDR                      \
	MT6359_ACCDET_DSN_DIG_REV0
#define ACCDET_ANA_MAJOR_REV_SFT                       4
#define ACCDET_ANA_MAJOR_REV_MASK                      0xF
#define ACCDET_ANA_MAJOR_REV_MASK_SFT                  (0xF << 4)
#define ACCDET_DIG_MINOR_REV_ADDR                      \
	MT6359_ACCDET_DSN_DIG_REV0
#define ACCDET_DIG_MINOR_REV_SFT                       8
#define ACCDET_DIG_MINOR_REV_MASK                      0xF
#define ACCDET_DIG_MINOR_REV_MASK_SFT                  (0xF << 8)
#define ACCDET_DIG_MAJOR_REV_ADDR                      \
	MT6359_ACCDET_DSN_DIG_REV0
#define ACCDET_DIG_MAJOR_REV_SFT                       12
#define ACCDET_DIG_MAJOR_REV_MASK                      0xF
#define ACCDET_DIG_MAJOR_REV_MASK_SFT                  (0xF << 12)
#define ACCDET_DSN_CBS_ADDR                            \
	MT6359_ACCDET_DSN_DBI
#define ACCDET_DSN_CBS_SFT                             0
#define ACCDET_DSN_CBS_MASK                            0x3
#define ACCDET_DSN_CBS_MASK_SFT                        (0x3 << 0)
#define ACCDET_DSN_BIX_ADDR                            \
	MT6359_ACCDET_DSN_DBI
#define ACCDET_DSN_BIX_SFT                             2
#define ACCDET_DSN_BIX_MASK                            0x3
#define ACCDET_DSN_BIX_MASK_SFT                        (0x3 << 2)
#define ACCDET_ESP_ADDR                                \
	MT6359_ACCDET_DSN_DBI
#define ACCDET_ESP_SFT                                 8
#define ACCDET_ESP_MASK                                0xFF
#define ACCDET_ESP_MASK_SFT                            (0xFF << 8)
#define ACCDET_DSN_FPI_ADDR                            \
	MT6359_ACCDET_DSN_FPI
#define ACCDET_DSN_FPI_SFT                             0
#define ACCDET_DSN_FPI_MASK                            0xFF
#define ACCDET_DSN_FPI_MASK_SFT                        (0xFF << 0)
#define ACCDET_AUXADC_SEL_ADDR                         \
	MT6359_ACCDET_CON0
#define ACCDET_AUXADC_SEL_SFT                          0
#define ACCDET_AUXADC_SEL_MASK                         0x1
#define ACCDET_AUXADC_SEL_MASK_SFT                     (0x1 << 0)
#define ACCDET_AUXADC_SW_ADDR                          \
	MT6359_ACCDET_CON0
#define ACCDET_AUXADC_SW_SFT                           1
#define ACCDET_AUXADC_SW_MASK                          0x1
#define ACCDET_AUXADC_SW_MASK_SFT                      (0x1 << 1)
#define ACCDET_TEST_AUXADC_ADDR                        \
	MT6359_ACCDET_CON0
#define ACCDET_TEST_AUXADC_SFT                         2
#define ACCDET_TEST_AUXADC_MASK                        0x1
#define ACCDET_TEST_AUXADC_MASK_SFT                    (0x1 << 2)
#define ACCDET_AUXADC_ANASWCTRL_SEL_ADDR               \
	MT6359_ACCDET_CON0
#define ACCDET_AUXADC_ANASWCTRL_SEL_SFT                8
#define ACCDET_AUXADC_ANASWCTRL_SEL_MASK               0x1
#define ACCDET_AUXADC_ANASWCTRL_SEL_MASK_SFT           (0x1 << 8)
#define AUDACCDETAUXADCSWCTRL_SEL_ADDR                 \
	MT6359_ACCDET_CON0
#define AUDACCDETAUXADCSWCTRL_SEL_SFT                  9
#define AUDACCDETAUXADCSWCTRL_SEL_MASK                 0x1
#define AUDACCDETAUXADCSWCTRL_SEL_MASK_SFT             (0x1 << 9)
#define AUDACCDETAUXADCSWCTRL_SW_ADDR                  \
	MT6359_ACCDET_CON0
#define AUDACCDETAUXADCSWCTRL_SW_SFT                   10
#define AUDACCDETAUXADCSWCTRL_SW_MASK                  0x1
#define AUDACCDETAUXADCSWCTRL_SW_MASK_SFT              (0x1 << 10)
#define ACCDET_TEST_ANA_ADDR                           \
	MT6359_ACCDET_CON0
#define ACCDET_TEST_ANA_SFT                            11
#define ACCDET_TEST_ANA_MASK                           0x1
#define ACCDET_TEST_ANA_MASK_SFT                       (0x1 << 11)
#define RG_AUDACCDETRSV_ADDR                           \
	MT6359_ACCDET_CON0
#define RG_AUDACCDETRSV_SFT                            13
#define RG_AUDACCDETRSV_MASK                           0x3
#define RG_AUDACCDETRSV_MASK_SFT                       (0x3 << 13)
#define ACCDET_SW_EN_ADDR                              \
	MT6359_ACCDET_CON1
#define ACCDET_SW_EN_SFT                               0
#define ACCDET_SW_EN_MASK                              0x1
#define ACCDET_SW_EN_MASK_SFT                          (0x1 << 0)
#define ACCDET_SEQ_INIT_ADDR                           \
	MT6359_ACCDET_CON1
#define ACCDET_SEQ_INIT_SFT                            1
#define ACCDET_SEQ_INIT_MASK                           0x1
#define ACCDET_SEQ_INIT_MASK_SFT                       (0x1 << 1)
#define ACCDET_EINT0_SW_EN_ADDR                        \
	MT6359_ACCDET_CON1
#define ACCDET_EINT0_SW_EN_SFT                         2
#define ACCDET_EINT0_SW_EN_MASK                        0x1
#define ACCDET_EINT0_SW_EN_MASK_SFT                    (0x1 << 2)
#define ACCDET_EINT0_SEQ_INIT_ADDR                     \
	MT6359_ACCDET_CON1
#define ACCDET_EINT0_SEQ_INIT_SFT                      3
#define ACCDET_EINT0_SEQ_INIT_MASK                     0x1
#define ACCDET_EINT0_SEQ_INIT_MASK_SFT                 (0x1 << 3)
#define ACCDET_EINT1_SW_EN_ADDR                        \
	MT6359_ACCDET_CON1
#define ACCDET_EINT1_SW_EN_SFT                         4
#define ACCDET_EINT1_SW_EN_MASK                        0x1
#define ACCDET_EINT1_SW_EN_MASK_SFT                    (0x1 << 4)
#define ACCDET_EINT1_SEQ_INIT_ADDR                     \
	MT6359_ACCDET_CON1
#define ACCDET_EINT1_SEQ_INIT_SFT                      5
#define ACCDET_EINT1_SEQ_INIT_MASK                     0x1
#define ACCDET_EINT1_SEQ_INIT_MASK_SFT                 (0x1 << 5)
#define ACCDET_EINT0_INVERTER_SW_EN_ADDR               \
	MT6359_ACCDET_CON1
#define ACCDET_EINT0_INVERTER_SW_EN_SFT                6
#define ACCDET_EINT0_INVERTER_SW_EN_MASK               0x1
#define ACCDET_EINT0_INVERTER_SW_EN_MASK_SFT           (0x1 << 6)
#define ACCDET_EINT0_INVERTER_SEQ_INIT_ADDR            \
	MT6359_ACCDET_CON1
#define ACCDET_EINT0_INVERTER_SEQ_INIT_SFT             7
#define ACCDET_EINT0_INVERTER_SEQ_INIT_MASK            0x1
#define ACCDET_EINT0_INVERTER_SEQ_INIT_MASK_SFT        (0x1 << 7)
#define ACCDET_EINT1_INVERTER_SW_EN_ADDR               \
	MT6359_ACCDET_CON1
#define ACCDET_EINT1_INVERTER_SW_EN_SFT                8
#define ACCDET_EINT1_INVERTER_SW_EN_MASK               0x1
#define ACCDET_EINT1_INVERTER_SW_EN_MASK_SFT           (0x1 << 8)
#define ACCDET_EINT1_INVERTER_SEQ_INIT_ADDR            \
	MT6359_ACCDET_CON1
#define ACCDET_EINT1_INVERTER_SEQ_INIT_SFT             9
#define ACCDET_EINT1_INVERTER_SEQ_INIT_MASK            0x1
#define ACCDET_EINT1_INVERTER_SEQ_INIT_MASK_SFT        (0x1 << 9)
#define ACCDET_EINT0_M_SW_EN_ADDR                      \
	MT6359_ACCDET_CON1
#define ACCDET_EINT0_M_SW_EN_SFT                       10
#define ACCDET_EINT0_M_SW_EN_MASK                      0x1
#define ACCDET_EINT0_M_SW_EN_MASK_SFT                  (0x1 << 10)
#define ACCDET_EINT1_M_SW_EN_ADDR                      \
	MT6359_ACCDET_CON1
#define ACCDET_EINT1_M_SW_EN_SFT                       11
#define ACCDET_EINT1_M_SW_EN_MASK                      0x1
#define ACCDET_EINT1_M_SW_EN_MASK_SFT                  (0x1 << 11)
#define ACCDET_EINT_M_DETECT_EN_ADDR                   \
	MT6359_ACCDET_CON1
#define ACCDET_EINT_M_DETECT_EN_SFT                    12
#define ACCDET_EINT_M_DETECT_EN_MASK                   0x1
#define ACCDET_EINT_M_DETECT_EN_MASK_SFT               (0x1 << 12)
#define ACCDET_CMP_PWM_EN_ADDR                         \
	MT6359_ACCDET_CON2
#define ACCDET_CMP_PWM_EN_SFT                          0
#define ACCDET_CMP_PWM_EN_MASK                         0x1
#define ACCDET_CMP_PWM_EN_MASK_SFT                     (0x1 << 0)
#define ACCDET_VTH_PWM_EN_ADDR                         \
	MT6359_ACCDET_CON2
#define ACCDET_VTH_PWM_EN_SFT                          1
#define ACCDET_VTH_PWM_EN_MASK                         0x1
#define ACCDET_VTH_PWM_EN_MASK_SFT                     (0x1 << 1)
#define ACCDET_MBIAS_PWM_EN_ADDR                       \
	MT6359_ACCDET_CON2
#define ACCDET_MBIAS_PWM_EN_SFT                        2
#define ACCDET_MBIAS_PWM_EN_MASK                       0x1
#define ACCDET_MBIAS_PWM_EN_MASK_SFT                   (0x1 << 2)
#define ACCDET_EINT_EN_PWM_EN_ADDR                     \
	MT6359_ACCDET_CON2
#define ACCDET_EINT_EN_PWM_EN_SFT                      3
#define ACCDET_EINT_EN_PWM_EN_MASK                     0x1
#define ACCDET_EINT_EN_PWM_EN_MASK_SFT                 (0x1 << 3)
#define ACCDET_EINT_CMPEN_PWM_EN_ADDR                  \
	MT6359_ACCDET_CON2
#define ACCDET_EINT_CMPEN_PWM_EN_SFT                   4
#define ACCDET_EINT_CMPEN_PWM_EN_MASK                  0x1
#define ACCDET_EINT_CMPEN_PWM_EN_MASK_SFT              (0x1 << 4)
#define ACCDET_EINT_CMPMEN_PWM_EN_ADDR                 \
	MT6359_ACCDET_CON2
#define ACCDET_EINT_CMPMEN_PWM_EN_SFT                  5
#define ACCDET_EINT_CMPMEN_PWM_EN_MASK                 0x1
#define ACCDET_EINT_CMPMEN_PWM_EN_MASK_SFT             (0x1 << 5)
#define ACCDET_EINT_CTURBO_PWM_EN_ADDR                 \
	MT6359_ACCDET_CON2
#define ACCDET_EINT_CTURBO_PWM_EN_SFT                  6
#define ACCDET_EINT_CTURBO_PWM_EN_MASK                 0x1
#define ACCDET_EINT_CTURBO_PWM_EN_MASK_SFT             (0x1 << 6)
#define ACCDET_CMP_PWM_IDLE_ADDR                       \
	MT6359_ACCDET_CON2
#define ACCDET_CMP_PWM_IDLE_SFT                        8
#define ACCDET_CMP_PWM_IDLE_MASK                       0x1
#define ACCDET_CMP_PWM_IDLE_MASK_SFT                   (0x1 << 8)
#define ACCDET_VTH_PWM_IDLE_ADDR                       \
	MT6359_ACCDET_CON2
#define ACCDET_VTH_PWM_IDLE_SFT                        9
#define ACCDET_VTH_PWM_IDLE_MASK                       0x1
#define ACCDET_VTH_PWM_IDLE_MASK_SFT                   (0x1 << 9)
#define ACCDET_MBIAS_PWM_IDLE_ADDR                     \
	MT6359_ACCDET_CON2
#define ACCDET_MBIAS_PWM_IDLE_SFT                      10
#define ACCDET_MBIAS_PWM_IDLE_MASK                     0x1
#define ACCDET_MBIAS_PWM_IDLE_MASK_SFT                 (0x1 << 10)
#define ACCDET_EINT0_CMPEN_PWM_IDLE_ADDR               \
	MT6359_ACCDET_CON2
#define ACCDET_EINT0_CMPEN_PWM_IDLE_SFT                11
#define ACCDET_EINT0_CMPEN_PWM_IDLE_MASK               0x1
#define ACCDET_EINT0_CMPEN_PWM_IDLE_MASK_SFT           (0x1 << 11)
#define ACCDET_EINT1_CMPEN_PWM_IDLE_ADDR               \
	MT6359_ACCDET_CON2
#define ACCDET_EINT1_CMPEN_PWM_IDLE_SFT                12
#define ACCDET_EINT1_CMPEN_PWM_IDLE_MASK               0x1
#define ACCDET_EINT1_CMPEN_PWM_IDLE_MASK_SFT           (0x1 << 12)
#define ACCDET_PWM_EN_SW_ADDR                          \
	MT6359_ACCDET_CON2
#define ACCDET_PWM_EN_SW_SFT                           13
#define ACCDET_PWM_EN_SW_MASK                          0x1
#define ACCDET_PWM_EN_SW_MASK_SFT                      (0x1 << 13)
#define ACCDET_PWM_EN_SEL_ADDR                         \
	MT6359_ACCDET_CON2
#define ACCDET_PWM_EN_SEL_SFT                          14
#define ACCDET_PWM_EN_SEL_MASK                         0x3
#define ACCDET_PWM_EN_SEL_MASK_SFT                     (0x3 << 14)
#define ACCDET_PWM_WIDTH_ADDR                          \
	MT6359_ACCDET_CON3
#define ACCDET_PWM_WIDTH_SFT                           0
#define ACCDET_PWM_WIDTH_MASK                          0xFFFF
#define ACCDET_PWM_WIDTH_MASK_SFT                      (0xFFFF << 0)
#define ACCDET_PWM_THRESH_ADDR                         \
	MT6359_ACCDET_CON4
#define ACCDET_PWM_THRESH_SFT                          0
#define ACCDET_PWM_THRESH_MASK                         0xFFFF
#define ACCDET_PWM_THRESH_MASK_SFT                     (0xFFFF << 0)
#define ACCDET_RISE_DELAY_ADDR                         \
	MT6359_ACCDET_CON5
#define ACCDET_RISE_DELAY_SFT                          0
#define ACCDET_RISE_DELAY_MASK                         0x7FFF
#define ACCDET_RISE_DELAY_MASK_SFT                     (0x7FFF << 0)
#define ACCDET_FALL_DELAY_ADDR                         \
	MT6359_ACCDET_CON5
#define ACCDET_FALL_DELAY_SFT                          15
#define ACCDET_FALL_DELAY_MASK                         0x1
#define ACCDET_FALL_DELAY_MASK_SFT                     (0x1 << 15)
#define ACCDET_EINT_CMPMEN_PWM_THRESH_ADDR             \
	MT6359_ACCDET_CON6
#define ACCDET_EINT_CMPMEN_PWM_THRESH_SFT              0
#define ACCDET_EINT_CMPMEN_PWM_THRESH_MASK             0x7
#define ACCDET_EINT_CMPMEN_PWM_THRESH_MASK_SFT         (0x7 << 0)
#define ACCDET_EINT_CMPMEN_PWM_WIDTH_ADDR              \
	MT6359_ACCDET_CON6
#define ACCDET_EINT_CMPMEN_PWM_WIDTH_SFT               4
#define ACCDET_EINT_CMPMEN_PWM_WIDTH_MASK              0x7
#define ACCDET_EINT_CMPMEN_PWM_WIDTH_MASK_SFT          (0x7 << 4)
#define ACCDET_EINT_EN_PWM_THRESH_ADDR                 \
	MT6359_ACCDET_CON7
#define ACCDET_EINT_EN_PWM_THRESH_SFT                  0
#define ACCDET_EINT_EN_PWM_THRESH_MASK                 0x7
#define ACCDET_EINT_EN_PWM_THRESH_MASK_SFT             (0x7 << 0)
#define ACCDET_EINT_EN_PWM_WIDTH_ADDR                  \
	MT6359_ACCDET_CON7
#define ACCDET_EINT_EN_PWM_WIDTH_SFT                   4
#define ACCDET_EINT_EN_PWM_WIDTH_MASK                  0x3
#define ACCDET_EINT_EN_PWM_WIDTH_MASK_SFT              (0x3 << 4)
#define ACCDET_EINT_CMPEN_PWM_THRESH_ADDR              \
	MT6359_ACCDET_CON7
#define ACCDET_EINT_CMPEN_PWM_THRESH_SFT               8
#define ACCDET_EINT_CMPEN_PWM_THRESH_MASK              0x7
#define ACCDET_EINT_CMPEN_PWM_THRESH_MASK_SFT          (0x7 << 8)
#define ACCDET_EINT_CMPEN_PWM_WIDTH_ADDR               \
	MT6359_ACCDET_CON7
#define ACCDET_EINT_CMPEN_PWM_WIDTH_SFT                12
#define ACCDET_EINT_CMPEN_PWM_WIDTH_MASK               0x3
#define ACCDET_EINT_CMPEN_PWM_WIDTH_MASK_SFT           (0x3 << 12)
#define ACCDET_DEBOUNCE0_ADDR                          \
	MT6359_ACCDET_CON8
#define ACCDET_DEBOUNCE0_SFT                           0
#define ACCDET_DEBOUNCE0_MASK                          0xFFFF
#define ACCDET_DEBOUNCE0_MASK_SFT                      (0xFFFF << 0)
#define ACCDET_DEBOUNCE1_ADDR                          \
	MT6359_ACCDET_CON9
#define ACCDET_DEBOUNCE1_SFT                           0
#define ACCDET_DEBOUNCE1_MASK                          0xFFFF
#define ACCDET_DEBOUNCE1_MASK_SFT                      (0xFFFF << 0)
#define ACCDET_DEBOUNCE2_ADDR                          \
	MT6359_ACCDET_CON10
#define ACCDET_DEBOUNCE2_SFT                           0
#define ACCDET_DEBOUNCE2_MASK                          0xFFFF
#define ACCDET_DEBOUNCE2_MASK_SFT                      (0xFFFF << 0)
#define ACCDET_DEBOUNCE3_ADDR                          \
	MT6359_ACCDET_CON11
#define ACCDET_DEBOUNCE3_SFT                           0
#define ACCDET_DEBOUNCE3_MASK                          0xFFFF
#define ACCDET_DEBOUNCE3_MASK_SFT                      (0xFFFF << 0)
#define ACCDET_CONNECT_AUXADC_TIME_DIG_ADDR            \
	MT6359_ACCDET_CON12
#define ACCDET_CONNECT_AUXADC_TIME_DIG_SFT             0
#define ACCDET_CONNECT_AUXADC_TIME_DIG_MASK            0xFFFF
#define ACCDET_CONNECT_AUXADC_TIME_DIG_MASK_SFT        (0xFFFF << 0)
#define ACCDET_CONNECT_AUXADC_TIME_ANA_ADDR            \
	MT6359_ACCDET_CON13
#define ACCDET_CONNECT_AUXADC_TIME_ANA_SFT             0
#define ACCDET_CONNECT_AUXADC_TIME_ANA_MASK            0xFFFF
#define ACCDET_CONNECT_AUXADC_TIME_ANA_MASK_SFT        (0xFFFF << 0)
#define ACCDET_EINT_DEBOUNCE0_ADDR                     \
	MT6359_ACCDET_CON14
#define ACCDET_EINT_DEBOUNCE0_SFT                      0
#define ACCDET_EINT_DEBOUNCE0_MASK                     0xF
#define ACCDET_EINT_DEBOUNCE0_MASK_SFT                 (0xF << 0)
#define ACCDET_EINT_DEBOUNCE1_ADDR                     \
	MT6359_ACCDET_CON14
#define ACCDET_EINT_DEBOUNCE1_SFT                      4
#define ACCDET_EINT_DEBOUNCE1_MASK                     0xF
#define ACCDET_EINT_DEBOUNCE1_MASK_SFT                 (0xF << 4)
#define ACCDET_EINT_DEBOUNCE2_ADDR                     \
	MT6359_ACCDET_CON14
#define ACCDET_EINT_DEBOUNCE2_SFT                      8
#define ACCDET_EINT_DEBOUNCE2_MASK                     0xF
#define ACCDET_EINT_DEBOUNCE2_MASK_SFT                 (0xF << 8)
#define ACCDET_EINT_DEBOUNCE3_ADDR                     \
	MT6359_ACCDET_CON14
#define ACCDET_EINT_DEBOUNCE3_SFT                      12
#define ACCDET_EINT_DEBOUNCE3_MASK                     0xF
#define ACCDET_EINT_DEBOUNCE3_MASK_SFT                 (0xF << 12)
#define ACCDET_EINT_INVERTER_DEBOUNCE_ADDR             \
	MT6359_ACCDET_CON15
#define ACCDET_EINT_INVERTER_DEBOUNCE_SFT              0
#define ACCDET_EINT_INVERTER_DEBOUNCE_MASK             0xF
#define ACCDET_EINT_INVERTER_DEBOUNCE_MASK_SFT         (0xF << 0)
#define ACCDET_IVAL_CUR_IN_ADDR                        \
	MT6359_ACCDET_CON16
#define ACCDET_IVAL_CUR_IN_SFT                         0
#define ACCDET_IVAL_CUR_IN_MASK                        0x3
#define ACCDET_IVAL_CUR_IN_MASK_SFT                    (0x3 << 0)
#define ACCDET_IVAL_SAM_IN_ADDR                        \
	MT6359_ACCDET_CON16
#define ACCDET_IVAL_SAM_IN_SFT                         2
#define ACCDET_IVAL_SAM_IN_MASK                        0x3
#define ACCDET_IVAL_SAM_IN_MASK_SFT                    (0x3 << 2)
#define ACCDET_IVAL_MEM_IN_ADDR                        \
	MT6359_ACCDET_CON16
#define ACCDET_IVAL_MEM_IN_SFT                         4
#define ACCDET_IVAL_MEM_IN_MASK                        0x3
#define ACCDET_IVAL_MEM_IN_MASK_SFT                    (0x3 << 4)
#define ACCDET_EINT_IVAL_CUR_IN_ADDR                   \
	MT6359_ACCDET_CON16
#define ACCDET_EINT_IVAL_CUR_IN_SFT                    6
#define ACCDET_EINT_IVAL_CUR_IN_MASK                   0x3
#define ACCDET_EINT_IVAL_CUR_IN_MASK_SFT               (0x3 << 6)
#define ACCDET_EINT_IVAL_SAM_IN_ADDR                   \
	MT6359_ACCDET_CON16
#define ACCDET_EINT_IVAL_SAM_IN_SFT                    8
#define ACCDET_EINT_IVAL_SAM_IN_MASK                   0x3
#define ACCDET_EINT_IVAL_SAM_IN_MASK_SFT               (0x3 << 8)
#define ACCDET_EINT_IVAL_MEM_IN_ADDR                   \
	MT6359_ACCDET_CON16
#define ACCDET_EINT_IVAL_MEM_IN_SFT                    10
#define ACCDET_EINT_IVAL_MEM_IN_MASK                   0x3
#define ACCDET_EINT_IVAL_MEM_IN_MASK_SFT               (0x3 << 10)
#define ACCDET_IVAL_SEL_ADDR                           \
	MT6359_ACCDET_CON16
#define ACCDET_IVAL_SEL_SFT                            12
#define ACCDET_IVAL_SEL_MASK                           0x1
#define ACCDET_IVAL_SEL_MASK_SFT                       (0x1 << 12)
#define ACCDET_EINT_IVAL_SEL_ADDR                      \
	MT6359_ACCDET_CON16
#define ACCDET_EINT_IVAL_SEL_SFT                       13
#define ACCDET_EINT_IVAL_SEL_MASK                      0x1
#define ACCDET_EINT_IVAL_SEL_MASK_SFT                  (0x1 << 13)
#define ACCDET_EINT_INVERTER_IVAL_CUR_IN_ADDR          \
	MT6359_ACCDET_CON17
#define ACCDET_EINT_INVERTER_IVAL_CUR_IN_SFT           0
#define ACCDET_EINT_INVERTER_IVAL_CUR_IN_MASK          0x1
#define ACCDET_EINT_INVERTER_IVAL_CUR_IN_MASK_SFT      (0x1 << 0)
#define ACCDET_EINT_INVERTER_IVAL_SAM_IN_ADDR          \
	MT6359_ACCDET_CON17
#define ACCDET_EINT_INVERTER_IVAL_SAM_IN_SFT           1
#define ACCDET_EINT_INVERTER_IVAL_SAM_IN_MASK          0x1
#define ACCDET_EINT_INVERTER_IVAL_SAM_IN_MASK_SFT      (0x1 << 1)
#define ACCDET_EINT_INVERTER_IVAL_MEM_IN_ADDR          \
	MT6359_ACCDET_CON17
#define ACCDET_EINT_INVERTER_IVAL_MEM_IN_SFT           2
#define ACCDET_EINT_INVERTER_IVAL_MEM_IN_MASK          0x1
#define ACCDET_EINT_INVERTER_IVAL_MEM_IN_MASK_SFT      (0x1 << 2)
#define ACCDET_EINT_INVERTER_IVAL_SEL_ADDR             \
	MT6359_ACCDET_CON17
#define ACCDET_EINT_INVERTER_IVAL_SEL_SFT              3
#define ACCDET_EINT_INVERTER_IVAL_SEL_MASK             0x1
#define ACCDET_EINT_INVERTER_IVAL_SEL_MASK_SFT         (0x1 << 3)
#define ACCDET_IRQ_ADDR                                \
	MT6359_ACCDET_CON18
#define ACCDET_IRQ_SFT                                 0
#define ACCDET_IRQ_MASK                                0x1
#define ACCDET_IRQ_MASK_SFT                            (0x1 << 0)
#define ACCDET_EINT0_IRQ_ADDR                          \
	MT6359_ACCDET_CON18
#define ACCDET_EINT0_IRQ_SFT                           2
#define ACCDET_EINT0_IRQ_MASK                          0x1
#define ACCDET_EINT0_IRQ_MASK_SFT                      (0x1 << 2)
#define ACCDET_EINT1_IRQ_ADDR                          \
	MT6359_ACCDET_CON18
#define ACCDET_EINT1_IRQ_SFT                           3
#define ACCDET_EINT1_IRQ_MASK                          0x1
#define ACCDET_EINT1_IRQ_MASK_SFT                      (0x1 << 3)
#define ACCDET_EINT_IN_INVERSE_ADDR                    \
	MT6359_ACCDET_CON18
#define ACCDET_EINT_IN_INVERSE_SFT                     4
#define ACCDET_EINT_IN_INVERSE_MASK                    0x1
#define ACCDET_EINT_IN_INVERSE_MASK_SFT                (0x1 << 4)
#define ACCDET_IRQ_CLR_ADDR                            \
	MT6359_ACCDET_CON18
#define ACCDET_IRQ_CLR_SFT                             8
#define ACCDET_IRQ_CLR_MASK                            0x1
#define ACCDET_IRQ_CLR_MASK_SFT                        (0x1 << 8)
#define ACCDET_EINT0_IRQ_CLR_ADDR                      \
	MT6359_ACCDET_CON18
#define ACCDET_EINT0_IRQ_CLR_SFT                       10
#define ACCDET_EINT0_IRQ_CLR_MASK                      0x1
#define ACCDET_EINT0_IRQ_CLR_MASK_SFT                  (0x1 << 10)
#define ACCDET_EINT1_IRQ_CLR_ADDR                      \
	MT6359_ACCDET_CON18
#define ACCDET_EINT1_IRQ_CLR_SFT                       11
#define ACCDET_EINT1_IRQ_CLR_MASK                      0x1
#define ACCDET_EINT1_IRQ_CLR_MASK_SFT                  (0x1 << 11)
#define ACCDET_EINT_M_PLUG_IN_NUM_ADDR                 \
	MT6359_ACCDET_CON18
#define ACCDET_EINT_M_PLUG_IN_NUM_SFT                  12
#define ACCDET_EINT_M_PLUG_IN_NUM_MASK                 0x7
#define ACCDET_EINT_M_PLUG_IN_NUM_MASK_SFT             (0x7 << 12)
#define ACCDET_DA_STABLE_ADDR                          \
	MT6359_ACCDET_CON19
#define ACCDET_DA_STABLE_SFT                           0
#define ACCDET_DA_STABLE_MASK                          0x1
#define ACCDET_DA_STABLE_MASK_SFT                      (0x1 << 0)
#define ACCDET_EINT0_EN_STABLE_ADDR                    \
	MT6359_ACCDET_CON19
#define ACCDET_EINT0_EN_STABLE_SFT                     1
#define ACCDET_EINT0_EN_STABLE_MASK                    0x1
#define ACCDET_EINT0_EN_STABLE_MASK_SFT                (0x1 << 1)
#define ACCDET_EINT0_CMPEN_STABLE_ADDR                 \
	MT6359_ACCDET_CON19
#define ACCDET_EINT0_CMPEN_STABLE_SFT                  2
#define ACCDET_EINT0_CMPEN_STABLE_MASK                 0x1
#define ACCDET_EINT0_CMPEN_STABLE_MASK_SFT             (0x1 << 2)
#define ACCDET_EINT0_CMPMEN_STABLE_ADDR                \
	MT6359_ACCDET_CON19
#define ACCDET_EINT0_CMPMEN_STABLE_SFT                 3
#define ACCDET_EINT0_CMPMEN_STABLE_MASK                0x1
#define ACCDET_EINT0_CMPMEN_STABLE_MASK_SFT            (0x1 << 3)
#define ACCDET_EINT0_CTURBO_STABLE_ADDR                \
	MT6359_ACCDET_CON19
#define ACCDET_EINT0_CTURBO_STABLE_SFT                 4
#define ACCDET_EINT0_CTURBO_STABLE_MASK                0x1
#define ACCDET_EINT0_CTURBO_STABLE_MASK_SFT            (0x1 << 4)
#define ACCDET_EINT0_CEN_STABLE_ADDR                   \
	MT6359_ACCDET_CON19
#define ACCDET_EINT0_CEN_STABLE_SFT                    5
#define ACCDET_EINT0_CEN_STABLE_MASK                   0x1
#define ACCDET_EINT0_CEN_STABLE_MASK_SFT               (0x1 << 5)
#define ACCDET_EINT1_EN_STABLE_ADDR                    \
	MT6359_ACCDET_CON19
#define ACCDET_EINT1_EN_STABLE_SFT                     6
#define ACCDET_EINT1_EN_STABLE_MASK                    0x1
#define ACCDET_EINT1_EN_STABLE_MASK_SFT                (0x1 << 6)
#define ACCDET_EINT1_CMPEN_STABLE_ADDR                 \
	MT6359_ACCDET_CON19
#define ACCDET_EINT1_CMPEN_STABLE_SFT                  7
#define ACCDET_EINT1_CMPEN_STABLE_MASK                 0x1
#define ACCDET_EINT1_CMPEN_STABLE_MASK_SFT             (0x1 << 7)
#define ACCDET_EINT1_CMPMEN_STABLE_ADDR                \
	MT6359_ACCDET_CON19
#define ACCDET_EINT1_CMPMEN_STABLE_SFT                 8
#define ACCDET_EINT1_CMPMEN_STABLE_MASK                0x1
#define ACCDET_EINT1_CMPMEN_STABLE_MASK_SFT            (0x1 << 8)
#define ACCDET_EINT1_CTURBO_STABLE_ADDR                \
	MT6359_ACCDET_CON19
#define ACCDET_EINT1_CTURBO_STABLE_SFT                 9
#define ACCDET_EINT1_CTURBO_STABLE_MASK                0x1
#define ACCDET_EINT1_CTURBO_STABLE_MASK_SFT            (0x1 << 9)
#define ACCDET_EINT1_CEN_STABLE_ADDR                   \
	MT6359_ACCDET_CON19
#define ACCDET_EINT1_CEN_STABLE_SFT                    10
#define ACCDET_EINT1_CEN_STABLE_MASK                   0x1
#define ACCDET_EINT1_CEN_STABLE_MASK_SFT               (0x1 << 10)
#define ACCDET_HWMODE_EN_ADDR                          \
	MT6359_ACCDET_CON20
#define ACCDET_HWMODE_EN_SFT                           0
#define ACCDET_HWMODE_EN_MASK                          0x1
#define ACCDET_HWMODE_EN_MASK_SFT                      (0x1 << 0)
#define ACCDET_HWMODE_SEL_ADDR                         \
	MT6359_ACCDET_CON20
#define ACCDET_HWMODE_SEL_SFT                          1
#define ACCDET_HWMODE_SEL_MASK                         0x3
#define ACCDET_HWMODE_SEL_MASK_SFT                     (0x3 << 1)
#define ACCDET_PLUG_OUT_DETECT_ADDR                    \
	MT6359_ACCDET_CON20
#define ACCDET_PLUG_OUT_DETECT_SFT                     3
#define ACCDET_PLUG_OUT_DETECT_MASK                    0x1
#define ACCDET_PLUG_OUT_DETECT_MASK_SFT                (0x1 << 3)
#define ACCDET_EINT0_REVERSE_ADDR                      \
	MT6359_ACCDET_CON20
#define ACCDET_EINT0_REVERSE_SFT                       4
#define ACCDET_EINT0_REVERSE_MASK                      0x1
#define ACCDET_EINT0_REVERSE_MASK_SFT                  (0x1 << 4)
#define ACCDET_EINT1_REVERSE_ADDR                      \
	MT6359_ACCDET_CON20
#define ACCDET_EINT1_REVERSE_SFT                       5
#define ACCDET_EINT1_REVERSE_MASK                      0x1
#define ACCDET_EINT1_REVERSE_MASK_SFT                  (0x1 << 5)
#define ACCDET_EINT_HWMODE_EN_ADDR                     \
	MT6359_ACCDET_CON20
#define ACCDET_EINT_HWMODE_EN_SFT                      8
#define ACCDET_EINT_HWMODE_EN_MASK                     0x1
#define ACCDET_EINT_HWMODE_EN_MASK_SFT                 (0x1 << 8)
#define ACCDET_EINT_PLUG_OUT_BYPASS_DEB_ADDR           \
	MT6359_ACCDET_CON20
#define ACCDET_EINT_PLUG_OUT_BYPASS_DEB_SFT            9
#define ACCDET_EINT_PLUG_OUT_BYPASS_DEB_MASK           0x1
#define ACCDET_EINT_PLUG_OUT_BYPASS_DEB_MASK_SFT       (0x1 << 9)
#define ACCDET_EINT_M_PLUG_IN_EN_ADDR                  \
	MT6359_ACCDET_CON20
#define ACCDET_EINT_M_PLUG_IN_EN_SFT                   10
#define ACCDET_EINT_M_PLUG_IN_EN_MASK                  0x1
#define ACCDET_EINT_M_PLUG_IN_EN_MASK_SFT              (0x1 << 10)
#define ACCDET_EINT_M_HWMODE_EN_ADDR                   \
	MT6359_ACCDET_CON20
#define ACCDET_EINT_M_HWMODE_EN_SFT                    11
#define ACCDET_EINT_M_HWMODE_EN_MASK                   0x1
#define ACCDET_EINT_M_HWMODE_EN_MASK_SFT               (0x1 << 11)
#define ACCDET_TEST_CMPEN_ADDR                         \
	MT6359_ACCDET_CON21
#define ACCDET_TEST_CMPEN_SFT                          0
#define ACCDET_TEST_CMPEN_MASK                         0x1
#define ACCDET_TEST_CMPEN_MASK_SFT                     (0x1 << 0)
#define ACCDET_TEST_VTHEN_ADDR                         \
	MT6359_ACCDET_CON21
#define ACCDET_TEST_VTHEN_SFT                          1
#define ACCDET_TEST_VTHEN_MASK                         0x1
#define ACCDET_TEST_VTHEN_MASK_SFT                     (0x1 << 1)
#define ACCDET_TEST_MBIASEN_ADDR                       \
	MT6359_ACCDET_CON21
#define ACCDET_TEST_MBIASEN_SFT                        2
#define ACCDET_TEST_MBIASEN_MASK                       0x1
#define ACCDET_TEST_MBIASEN_MASK_SFT                   (0x1 << 2)
#define ACCDET_EINT_TEST_EN_ADDR                       \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_EN_SFT                        3
#define ACCDET_EINT_TEST_EN_MASK                       0x1
#define ACCDET_EINT_TEST_EN_MASK_SFT                   (0x1 << 3)
#define ACCDET_EINT_TEST_INVEN_ADDR                    \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_INVEN_SFT                     4
#define ACCDET_EINT_TEST_INVEN_MASK                    0x1
#define ACCDET_EINT_TEST_INVEN_MASK_SFT                (0x1 << 4)
#define ACCDET_EINT_TEST_CMPEN_ADDR                    \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_CMPEN_SFT                     5
#define ACCDET_EINT_TEST_CMPEN_MASK                    0x1
#define ACCDET_EINT_TEST_CMPEN_MASK_SFT                (0x1 << 5)
#define ACCDET_EINT_TEST_CMPMEN_ADDR                   \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_CMPMEN_SFT                    6
#define ACCDET_EINT_TEST_CMPMEN_MASK                   0x1
#define ACCDET_EINT_TEST_CMPMEN_MASK_SFT               (0x1 << 6)
#define ACCDET_EINT_TEST_CTURBO_ADDR                   \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_CTURBO_SFT                    7
#define ACCDET_EINT_TEST_CTURBO_MASK                   0x1
#define ACCDET_EINT_TEST_CTURBO_MASK_SFT               (0x1 << 7)
#define ACCDET_EINT_TEST_CEN_ADDR                      \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_CEN_SFT                       8
#define ACCDET_EINT_TEST_CEN_MASK                      0x1
#define ACCDET_EINT_TEST_CEN_MASK_SFT                  (0x1 << 8)
#define ACCDET_TEST_B_ADDR                             \
	MT6359_ACCDET_CON21
#define ACCDET_TEST_B_SFT                              9
#define ACCDET_TEST_B_MASK                             0x1
#define ACCDET_TEST_B_MASK_SFT                         (0x1 << 9)
#define ACCDET_TEST_A_ADDR                             \
	MT6359_ACCDET_CON21
#define ACCDET_TEST_A_SFT                              10
#define ACCDET_TEST_A_MASK                             0x1
#define ACCDET_TEST_A_MASK_SFT                         (0x1 << 10)
#define ACCDET_EINT_TEST_CMPOUT_ADDR                   \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_CMPOUT_SFT                    11
#define ACCDET_EINT_TEST_CMPOUT_MASK                   0x1
#define ACCDET_EINT_TEST_CMPOUT_MASK_SFT               (0x1 << 11)
#define ACCDET_EINT_TEST_CMPMOUT_ADDR                  \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_CMPMOUT_SFT                   12
#define ACCDET_EINT_TEST_CMPMOUT_MASK                  0x1
#define ACCDET_EINT_TEST_CMPMOUT_MASK_SFT              (0x1 << 12)
#define ACCDET_EINT_TEST_INVOUT_ADDR                   \
	MT6359_ACCDET_CON21
#define ACCDET_EINT_TEST_INVOUT_SFT                    13
#define ACCDET_EINT_TEST_INVOUT_MASK                   0x1
#define ACCDET_EINT_TEST_INVOUT_MASK_SFT               (0x1 << 13)
#define ACCDET_CMPEN_SEL_ADDR                          \
	MT6359_ACCDET_CON22
#define ACCDET_CMPEN_SEL_SFT                           0
#define ACCDET_CMPEN_SEL_MASK                          0x1
#define ACCDET_CMPEN_SEL_MASK_SFT                      (0x1 << 0)
#define ACCDET_VTHEN_SEL_ADDR                          \
	MT6359_ACCDET_CON22
#define ACCDET_VTHEN_SEL_SFT                           1
#define ACCDET_VTHEN_SEL_MASK                          0x1
#define ACCDET_VTHEN_SEL_MASK_SFT                      (0x1 << 1)
#define ACCDET_MBIASEN_SEL_ADDR                        \
	MT6359_ACCDET_CON22
#define ACCDET_MBIASEN_SEL_SFT                         2
#define ACCDET_MBIASEN_SEL_MASK                        0x1
#define ACCDET_MBIASEN_SEL_MASK_SFT                    (0x1 << 2)
#define ACCDET_EINT_EN_SEL_ADDR                        \
	MT6359_ACCDET_CON22
#define ACCDET_EINT_EN_SEL_SFT                         3
#define ACCDET_EINT_EN_SEL_MASK                        0x1
#define ACCDET_EINT_EN_SEL_MASK_SFT                    (0x1 << 3)
#define ACCDET_EINT_INVEN_SEL_ADDR                     \
	MT6359_ACCDET_CON22
#define ACCDET_EINT_INVEN_SEL_SFT                      4
#define ACCDET_EINT_INVEN_SEL_MASK                     0x1
#define ACCDET_EINT_INVEN_SEL_MASK_SFT                 (0x1 << 4)
#define ACCDET_EINT_CMPEN_SEL_ADDR                     \
	MT6359_ACCDET_CON22
#define ACCDET_EINT_CMPEN_SEL_SFT                      5
#define ACCDET_EINT_CMPEN_SEL_MASK                     0x1
#define ACCDET_EINT_CMPEN_SEL_MASK_SFT                 (0x1 << 5)
#define ACCDET_EINT_CMPMEN_SEL_ADDR                    \
	MT6359_ACCDET_CON22
#define ACCDET_EINT_CMPMEN_SEL_SFT                     6
#define ACCDET_EINT_CMPMEN_SEL_MASK                    0x1
#define ACCDET_EINT_CMPMEN_SEL_MASK_SFT                (0x1 << 6)
#define ACCDET_EINT_CTURBO_SEL_ADDR                    \
	MT6359_ACCDET_CON22
#define ACCDET_EINT_CTURBO_SEL_SFT                     7
#define ACCDET_EINT_CTURBO_SEL_MASK                    0x1
#define ACCDET_EINT_CTURBO_SEL_MASK_SFT                (0x1 << 7)
#define ACCDET_B_SEL_ADDR                              \
	MT6359_ACCDET_CON22
#define ACCDET_B_SEL_SFT                               9
#define ACCDET_B_SEL_MASK                              0x1
#define ACCDET_B_SEL_MASK_SFT                          (0x1 << 9)
#define ACCDET_A_SEL_ADDR                              \
	MT6359_ACCDET_CON22
#define ACCDET_A_SEL_SFT                               10
#define ACCDET_A_SEL_MASK                              0x1
#define ACCDET_A_SEL_MASK_SFT                          (0x1 << 10)
#define ACCDET_EINT_CMPOUT_SEL_ADDR                    \
	MT6359_ACCDET_CON22
#define ACCDET_EINT_CMPOUT_SEL_SFT                     11
#define ACCDET_EINT_CMPOUT_SEL_MASK                    0x1
#define ACCDET_EINT_CMPOUT_SEL_MASK_SFT                (0x1 << 11)
#define ACCDET_EINT_CMPMOUT_SEL_ADDR                   \
	MT6359_ACCDET_CON22
#define ACCDET_EINT_CMPMOUT_SEL_SFT                    12
#define ACCDET_EINT_CMPMOUT_SEL_MASK                   0x1
#define ACCDET_EINT_CMPMOUT_SEL_MASK_SFT               (0x1 << 12)
#define ACCDET_EINT_INVOUT_SEL_ADDR                    \
	MT6359_ACCDET_CON22
#define ACCDET_EINT_INVOUT_SEL_SFT                     13
#define ACCDET_EINT_INVOUT_SEL_MASK                    0x1
#define ACCDET_EINT_INVOUT_SEL_MASK_SFT                (0x1 << 13)
#define ACCDET_CMPEN_SW_ADDR                           \
	MT6359_ACCDET_CON23
#define ACCDET_CMPEN_SW_SFT                            0
#define ACCDET_CMPEN_SW_MASK                           0x1
#define ACCDET_CMPEN_SW_MASK_SFT                       (0x1 << 0)
#define ACCDET_VTHEN_SW_ADDR                           \
	MT6359_ACCDET_CON23
#define ACCDET_VTHEN_SW_SFT                            1
#define ACCDET_VTHEN_SW_MASK                           0x1
#define ACCDET_VTHEN_SW_MASK_SFT                       (0x1 << 1)
#define ACCDET_MBIASEN_SW_ADDR                         \
	MT6359_ACCDET_CON23
#define ACCDET_MBIASEN_SW_SFT                          2
#define ACCDET_MBIASEN_SW_MASK                         0x1
#define ACCDET_MBIASEN_SW_MASK_SFT                     (0x1 << 2)
#define ACCDET_EINT0_EN_SW_ADDR                        \
	MT6359_ACCDET_CON23
#define ACCDET_EINT0_EN_SW_SFT                         3
#define ACCDET_EINT0_EN_SW_MASK                        0x1
#define ACCDET_EINT0_EN_SW_MASK_SFT                    (0x1 << 3)
#define ACCDET_EINT0_INVEN_SW_ADDR                     \
	MT6359_ACCDET_CON23
#define ACCDET_EINT0_INVEN_SW_SFT                      4
#define ACCDET_EINT0_INVEN_SW_MASK                     0x1
#define ACCDET_EINT0_INVEN_SW_MASK_SFT                 (0x1 << 4)
#define ACCDET_EINT0_CMPEN_SW_ADDR                     \
	MT6359_ACCDET_CON23
#define ACCDET_EINT0_CMPEN_SW_SFT                      5
#define ACCDET_EINT0_CMPEN_SW_MASK                     0x1
#define ACCDET_EINT0_CMPEN_SW_MASK_SFT                 (0x1 << 5)
#define ACCDET_EINT0_CMPMEN_SW_ADDR                    \
	MT6359_ACCDET_CON23
#define ACCDET_EINT0_CMPMEN_SW_SFT                     6
#define ACCDET_EINT0_CMPMEN_SW_MASK                    0x1
#define ACCDET_EINT0_CMPMEN_SW_MASK_SFT                (0x1 << 6)
#define ACCDET_EINT0_CTURBO_SW_ADDR                    \
	MT6359_ACCDET_CON23
#define ACCDET_EINT0_CTURBO_SW_SFT                     7
#define ACCDET_EINT0_CTURBO_SW_MASK                    0x1
#define ACCDET_EINT0_CTURBO_SW_MASK_SFT                (0x1 << 7)
#define ACCDET_EINT1_EN_SW_ADDR                        \
	MT6359_ACCDET_CON23
#define ACCDET_EINT1_EN_SW_SFT                         8
#define ACCDET_EINT1_EN_SW_MASK                        0x1
#define ACCDET_EINT1_EN_SW_MASK_SFT                    (0x1 << 8)
#define ACCDET_EINT1_INVEN_SW_ADDR                     \
	MT6359_ACCDET_CON23
#define ACCDET_EINT1_INVEN_SW_SFT                      9
#define ACCDET_EINT1_INVEN_SW_MASK                     0x1
#define ACCDET_EINT1_INVEN_SW_MASK_SFT                 (0x1 << 9)
#define ACCDET_EINT1_CMPEN_SW_ADDR                     \
	MT6359_ACCDET_CON23
#define ACCDET_EINT1_CMPEN_SW_SFT                      10
#define ACCDET_EINT1_CMPEN_SW_MASK                     0x1
#define ACCDET_EINT1_CMPEN_SW_MASK_SFT                 (0x1 << 10)
#define ACCDET_EINT1_CMPMEN_SW_ADDR                    \
	MT6359_ACCDET_CON23
#define ACCDET_EINT1_CMPMEN_SW_SFT                     11
#define ACCDET_EINT1_CMPMEN_SW_MASK                    0x1
#define ACCDET_EINT1_CMPMEN_SW_MASK_SFT                (0x1 << 11)
#define ACCDET_EINT1_CTURBO_SW_ADDR                    \
	MT6359_ACCDET_CON23
#define ACCDET_EINT1_CTURBO_SW_SFT                     12
#define ACCDET_EINT1_CTURBO_SW_MASK                    0x1
#define ACCDET_EINT1_CTURBO_SW_MASK_SFT                (0x1 << 12)
#define ACCDET_B_SW_ADDR                               \
	MT6359_ACCDET_CON24
#define ACCDET_B_SW_SFT                                0
#define ACCDET_B_SW_MASK                               0x1
#define ACCDET_B_SW_MASK_SFT                           (0x1 << 0)
#define ACCDET_A_SW_ADDR                               \
	MT6359_ACCDET_CON24
#define ACCDET_A_SW_SFT                                1
#define ACCDET_A_SW_MASK                               0x1
#define ACCDET_A_SW_MASK_SFT                           (0x1 << 1)
#define ACCDET_EINT0_CMPOUT_SW_ADDR                    \
	MT6359_ACCDET_CON24
#define ACCDET_EINT0_CMPOUT_SW_SFT                     2
#define ACCDET_EINT0_CMPOUT_SW_MASK                    0x1
#define ACCDET_EINT0_CMPOUT_SW_MASK_SFT                (0x1 << 2)
#define ACCDET_EINT0_CMPMOUT_SW_ADDR                   \
	MT6359_ACCDET_CON24
#define ACCDET_EINT0_CMPMOUT_SW_SFT                    3
#define ACCDET_EINT0_CMPMOUT_SW_MASK                   0x1
#define ACCDET_EINT0_CMPMOUT_SW_MASK_SFT               (0x1 << 3)
#define ACCDET_EINT0_INVOUT_SW_ADDR                    \
	MT6359_ACCDET_CON24
#define ACCDET_EINT0_INVOUT_SW_SFT                     4
#define ACCDET_EINT0_INVOUT_SW_MASK                    0x1
#define ACCDET_EINT0_INVOUT_SW_MASK_SFT                (0x1 << 4)
#define ACCDET_EINT1_CMPOUT_SW_ADDR                    \
	MT6359_ACCDET_CON24
#define ACCDET_EINT1_CMPOUT_SW_SFT                     5
#define ACCDET_EINT1_CMPOUT_SW_MASK                    0x1
#define ACCDET_EINT1_CMPOUT_SW_MASK_SFT                (0x1 << 5)
#define ACCDET_EINT1_CMPMOUT_SW_ADDR                   \
	MT6359_ACCDET_CON24
#define ACCDET_EINT1_CMPMOUT_SW_SFT                    6
#define ACCDET_EINT1_CMPMOUT_SW_MASK                   0x1
#define ACCDET_EINT1_CMPMOUT_SW_MASK_SFT               (0x1 << 6)
#define ACCDET_EINT1_INVOUT_SW_ADDR                    \
	MT6359_ACCDET_CON24
#define ACCDET_EINT1_INVOUT_SW_SFT                     7
#define ACCDET_EINT1_INVOUT_SW_MASK                    0x1
#define ACCDET_EINT1_INVOUT_SW_MASK_SFT                (0x1 << 7)
#define AD_AUDACCDETCMPOB_ADDR                         \
	MT6359_ACCDET_CON25
#define AD_AUDACCDETCMPOB_SFT                          0
#define AD_AUDACCDETCMPOB_MASK                         0x1
#define AD_AUDACCDETCMPOB_MASK_SFT                     (0x1 << 0)
#define AD_AUDACCDETCMPOA_ADDR                         \
	MT6359_ACCDET_CON25
#define AD_AUDACCDETCMPOA_SFT                          1
#define AD_AUDACCDETCMPOA_MASK                         0x1
#define AD_AUDACCDETCMPOA_MASK_SFT                     (0x1 << 1)
#define ACCDET_CUR_IN_ADDR                             \
	MT6359_ACCDET_CON25
#define ACCDET_CUR_IN_SFT                              2
#define ACCDET_CUR_IN_MASK                             0x3
#define ACCDET_CUR_IN_MASK_SFT                         (0x3 << 2)
#define ACCDET_SAM_IN_ADDR                             \
	MT6359_ACCDET_CON25
#define ACCDET_SAM_IN_SFT                              4
#define ACCDET_SAM_IN_MASK                             0x3
#define ACCDET_SAM_IN_MASK_SFT                         (0x3 << 4)
#define ACCDET_MEM_IN_ADDR                             \
	MT6359_ACCDET_CON25
#define ACCDET_MEM_IN_SFT                              6
#define ACCDET_MEM_IN_MASK                             0x3
#define ACCDET_MEM_IN_MASK_SFT                         (0x3 << 6)
#define ACCDET_STATE_ADDR                              \
	MT6359_ACCDET_CON25
#define ACCDET_STATE_SFT                               8
#define ACCDET_STATE_MASK                              0x7
#define ACCDET_STATE_MASK_SFT                          (0x7 << 8)
#define DA_AUDACCDETMBIASCLK_ADDR                      \
	MT6359_ACCDET_CON25
#define DA_AUDACCDETMBIASCLK_SFT                       12
#define DA_AUDACCDETMBIASCLK_MASK                      0x1
#define DA_AUDACCDETMBIASCLK_MASK_SFT                  (0x1 << 12)
#define DA_AUDACCDETVTHCLK_ADDR                        \
	MT6359_ACCDET_CON25
#define DA_AUDACCDETVTHCLK_SFT                         13
#define DA_AUDACCDETVTHCLK_MASK                        0x1
#define DA_AUDACCDETVTHCLK_MASK_SFT                    (0x1 << 13)
#define DA_AUDACCDETCMPCLK_ADDR                        \
	MT6359_ACCDET_CON25
#define DA_AUDACCDETCMPCLK_SFT                         14
#define DA_AUDACCDETCMPCLK_MASK                        0x1
#define DA_AUDACCDETCMPCLK_MASK_SFT                    (0x1 << 14)
#define DA_AUDACCDETAUXADCSWCTRL_ADDR                  \
	MT6359_ACCDET_CON25
#define DA_AUDACCDETAUXADCSWCTRL_SFT                   15
#define DA_AUDACCDETAUXADCSWCTRL_MASK                  0x1
#define DA_AUDACCDETAUXADCSWCTRL_MASK_SFT              (0x1 << 15)
#define AD_EINT0CMPMOUT_ADDR                           \
	MT6359_ACCDET_CON26
#define AD_EINT0CMPMOUT_SFT                            0
#define AD_EINT0CMPMOUT_MASK                           0x1
#define AD_EINT0CMPMOUT_MASK_SFT                       (0x1 << 0)
#define AD_EINT0CMPOUT_ADDR                            \
	MT6359_ACCDET_CON26
#define AD_EINT0CMPOUT_SFT                             1
#define AD_EINT0CMPOUT_MASK                            0x1
#define AD_EINT0CMPOUT_MASK_SFT                        (0x1 << 1)
#define ACCDET_EINT0_CUR_IN_ADDR                       \
	MT6359_ACCDET_CON26
#define ACCDET_EINT0_CUR_IN_SFT                        2
#define ACCDET_EINT0_CUR_IN_MASK                       0x3
#define ACCDET_EINT0_CUR_IN_MASK_SFT                   (0x3 << 2)
#define ACCDET_EINT0_SAM_IN_ADDR                       \
	MT6359_ACCDET_CON26
#define ACCDET_EINT0_SAM_IN_SFT                        4
#define ACCDET_EINT0_SAM_IN_MASK                       0x3
#define ACCDET_EINT0_SAM_IN_MASK_SFT                   (0x3 << 4)
#define ACCDET_EINT0_MEM_IN_ADDR                       \
	MT6359_ACCDET_CON26
#define ACCDET_EINT0_MEM_IN_SFT                        6
#define ACCDET_EINT0_MEM_IN_MASK                       0x3
#define ACCDET_EINT0_MEM_IN_MASK_SFT                   (0x3 << 6)
#define ACCDET_EINT0_STATE_ADDR                        \
	MT6359_ACCDET_CON26
#define ACCDET_EINT0_STATE_SFT                         8
#define ACCDET_EINT0_STATE_MASK                        0x7
#define ACCDET_EINT0_STATE_MASK_SFT                    (0x7 << 8)
#define DA_EINT0CMPEN_ADDR                             \
	MT6359_ACCDET_CON26
#define DA_EINT0CMPEN_SFT                              13
#define DA_EINT0CMPEN_MASK                             0x1
#define DA_EINT0CMPEN_MASK_SFT                         (0x1 << 13)
#define DA_EINT0CMPMEN_ADDR                            \
	MT6359_ACCDET_CON26
#define DA_EINT0CMPMEN_SFT                             14
#define DA_EINT0CMPMEN_MASK                            0x1
#define DA_EINT0CMPMEN_MASK_SFT                        (0x1 << 14)
#define DA_EINT0CTURBO_ADDR                            \
	MT6359_ACCDET_CON26
#define DA_EINT0CTURBO_SFT                             15
#define DA_EINT0CTURBO_MASK                            0x1
#define DA_EINT0CTURBO_MASK_SFT                        (0x1 << 15)
#define AD_EINT1CMPMOUT_ADDR                           \
	MT6359_ACCDET_CON27
#define AD_EINT1CMPMOUT_SFT                            0
#define AD_EINT1CMPMOUT_MASK                           0x1
#define AD_EINT1CMPMOUT_MASK_SFT                       (0x1 << 0)
#define AD_EINT1CMPOUT_ADDR                            \
	MT6359_ACCDET_CON27
#define AD_EINT1CMPOUT_SFT                             1
#define AD_EINT1CMPOUT_MASK                            0x1
#define AD_EINT1CMPOUT_MASK_SFT                        (0x1 << 1)
#define ACCDET_EINT1_CUR_IN_ADDR                       \
	MT6359_ACCDET_CON27
#define ACCDET_EINT1_CUR_IN_SFT                        2
#define ACCDET_EINT1_CUR_IN_MASK                       0x3
#define ACCDET_EINT1_CUR_IN_MASK_SFT                   (0x3 << 2)
#define ACCDET_EINT1_SAM_IN_ADDR                       \
	MT6359_ACCDET_CON27
#define ACCDET_EINT1_SAM_IN_SFT                        4
#define ACCDET_EINT1_SAM_IN_MASK                       0x3
#define ACCDET_EINT1_SAM_IN_MASK_SFT                   (0x3 << 4)
#define ACCDET_EINT1_MEM_IN_ADDR                       \
	MT6359_ACCDET_CON27
#define ACCDET_EINT1_MEM_IN_SFT                        6
#define ACCDET_EINT1_MEM_IN_MASK                       0x3
#define ACCDET_EINT1_MEM_IN_MASK_SFT                   (0x3 << 6)
#define ACCDET_EINT1_STATE_ADDR                        \
	MT6359_ACCDET_CON27
#define ACCDET_EINT1_STATE_SFT                         8
#define ACCDET_EINT1_STATE_MASK                        0x7
#define ACCDET_EINT1_STATE_MASK_SFT                    (0x7 << 8)
#define DA_EINT1CMPEN_ADDR                             \
	MT6359_ACCDET_CON27
#define DA_EINT1CMPEN_SFT                              13
#define DA_EINT1CMPEN_MASK                             0x1
#define DA_EINT1CMPEN_MASK_SFT                         (0x1 << 13)
#define DA_EINT1CMPMEN_ADDR                            \
	MT6359_ACCDET_CON27
#define DA_EINT1CMPMEN_SFT                             14
#define DA_EINT1CMPMEN_MASK                            0x1
#define DA_EINT1CMPMEN_MASK_SFT                        (0x1 << 14)
#define DA_EINT1CTURBO_ADDR                            \
	MT6359_ACCDET_CON27
#define DA_EINT1CTURBO_SFT                             15
#define DA_EINT1CTURBO_MASK                            0x1
#define DA_EINT1CTURBO_MASK_SFT                        (0x1 << 15)
#define AD_EINT0INVOUT_ADDR                            \
	MT6359_ACCDET_CON28
#define AD_EINT0INVOUT_SFT                             0
#define AD_EINT0INVOUT_MASK                            0x1
#define AD_EINT0INVOUT_MASK_SFT                        (0x1 << 0)
#define ACCDET_EINT0_INVERTER_CUR_IN_ADDR              \
	MT6359_ACCDET_CON28
#define ACCDET_EINT0_INVERTER_CUR_IN_SFT               1
#define ACCDET_EINT0_INVERTER_CUR_IN_MASK              0x1
#define ACCDET_EINT0_INVERTER_CUR_IN_MASK_SFT          (0x1 << 1)
#define ACCDET_EINT0_INVERTER_SAM_IN_ADDR              \
	MT6359_ACCDET_CON28
#define ACCDET_EINT0_INVERTER_SAM_IN_SFT               2
#define ACCDET_EINT0_INVERTER_SAM_IN_MASK              0x1
#define ACCDET_EINT0_INVERTER_SAM_IN_MASK_SFT          (0x1 << 2)
#define ACCDET_EINT0_INVERTER_MEM_IN_ADDR              \
	MT6359_ACCDET_CON28
#define ACCDET_EINT0_INVERTER_MEM_IN_SFT               3
#define ACCDET_EINT0_INVERTER_MEM_IN_MASK              0x1
#define ACCDET_EINT0_INVERTER_MEM_IN_MASK_SFT          (0x1 << 3)
#define ACCDET_EINT0_INVERTER_STATE_ADDR               \
	MT6359_ACCDET_CON28
#define ACCDET_EINT0_INVERTER_STATE_SFT                8
#define ACCDET_EINT0_INVERTER_STATE_MASK               0x7
#define ACCDET_EINT0_INVERTER_STATE_MASK_SFT           (0x7 << 8)
#define DA_EINT0EN_ADDR                                \
	MT6359_ACCDET_CON28
#define DA_EINT0EN_SFT                                 12
#define DA_EINT0EN_MASK                                0x1
#define DA_EINT0EN_MASK_SFT                            (0x1 << 12)
#define DA_EINT0INVEN_ADDR                             \
	MT6359_ACCDET_CON28
#define DA_EINT0INVEN_SFT                              13
#define DA_EINT0INVEN_MASK                             0x1
#define DA_EINT0INVEN_MASK_SFT                         (0x1 << 13)
#define DA_EINT0CEN_ADDR                               \
	MT6359_ACCDET_CON28
#define DA_EINT0CEN_SFT                                14
#define DA_EINT0CEN_MASK                               0x1
#define DA_EINT0CEN_MASK_SFT                           (0x1 << 14)
#define AD_EINT1INVOUT_ADDR                            \
	MT6359_ACCDET_CON29
#define AD_EINT1INVOUT_SFT                             0
#define AD_EINT1INVOUT_MASK                            0x1
#define AD_EINT1INVOUT_MASK_SFT                        (0x1 << 0)
#define ACCDET_EINT1_INVERTER_CUR_IN_ADDR              \
	MT6359_ACCDET_CON29
#define ACCDET_EINT1_INVERTER_CUR_IN_SFT               1
#define ACCDET_EINT1_INVERTER_CUR_IN_MASK              0x1
#define ACCDET_EINT1_INVERTER_CUR_IN_MASK_SFT          (0x1 << 1)
#define ACCDET_EINT1_INVERTER_SAM_IN_ADDR              \
	MT6359_ACCDET_CON29
#define ACCDET_EINT1_INVERTER_SAM_IN_SFT               2
#define ACCDET_EINT1_INVERTER_SAM_IN_MASK              0x1
#define ACCDET_EINT1_INVERTER_SAM_IN_MASK_SFT          (0x1 << 2)
#define ACCDET_EINT1_INVERTER_MEM_IN_ADDR              \
	MT6359_ACCDET_CON29
#define ACCDET_EINT1_INVERTER_MEM_IN_SFT               3
#define ACCDET_EINT1_INVERTER_MEM_IN_MASK              0x1
#define ACCDET_EINT1_INVERTER_MEM_IN_MASK_SFT          (0x1 << 3)
#define ACCDET_EINT1_INVERTER_STATE_ADDR               \
	MT6359_ACCDET_CON29
#define ACCDET_EINT1_INVERTER_STATE_SFT                8
#define ACCDET_EINT1_INVERTER_STATE_MASK               0x7
#define ACCDET_EINT1_INVERTER_STATE_MASK_SFT           (0x7 << 8)
#define DA_EINT1EN_ADDR                                \
	MT6359_ACCDET_CON29
#define DA_EINT1EN_SFT                                 12
#define DA_EINT1EN_MASK                                0x1
#define DA_EINT1EN_MASK_SFT                            (0x1 << 12)
#define DA_EINT1INVEN_ADDR                             \
	MT6359_ACCDET_CON29
#define DA_EINT1INVEN_SFT                              13
#define DA_EINT1INVEN_MASK                             0x1
#define DA_EINT1INVEN_MASK_SFT                         (0x1 << 13)
#define DA_EINT1CEN_ADDR                               \
	MT6359_ACCDET_CON29
#define DA_EINT1CEN_SFT                                14
#define DA_EINT1CEN_MASK                               0x1
#define DA_EINT1CEN_MASK_SFT                           (0x1 << 14)
#define ACCDET_EN_ADDR                                 \
	MT6359_ACCDET_CON30
#define ACCDET_EN_SFT                                  0
#define ACCDET_EN_MASK                                 0x1
#define ACCDET_EN_MASK_SFT                             (0x1 << 0)
#define ACCDET_EINT0_EN_ADDR                           \
	MT6359_ACCDET_CON30
#define ACCDET_EINT0_EN_SFT                            1
#define ACCDET_EINT0_EN_MASK                           0x1
#define ACCDET_EINT0_EN_MASK_SFT                       (0x1 << 1)
#define ACCDET_EINT1_EN_ADDR                           \
	MT6359_ACCDET_CON30
#define ACCDET_EINT1_EN_SFT                            2
#define ACCDET_EINT1_EN_MASK                           0x1
#define ACCDET_EINT1_EN_MASK_SFT                       (0x1 << 2)
#define ACCDET_EINT0_M_EN_ADDR                         \
	MT6359_ACCDET_CON30
#define ACCDET_EINT0_M_EN_SFT                          3
#define ACCDET_EINT0_M_EN_MASK                         0x1
#define ACCDET_EINT0_M_EN_MASK_SFT                     (0x1 << 3)
#define ACCDET_EINT0_DETECT_MOISTURE_ADDR              \
	MT6359_ACCDET_CON30
#define ACCDET_EINT0_DETECT_MOISTURE_SFT               4
#define ACCDET_EINT0_DETECT_MOISTURE_MASK              0x1
#define ACCDET_EINT0_DETECT_MOISTURE_MASK_SFT          (0x1 << 4)
#define ACCDET_EINT0_PLUG_IN_ADDR                      \
	MT6359_ACCDET_CON30
#define ACCDET_EINT0_PLUG_IN_SFT                       5
#define ACCDET_EINT0_PLUG_IN_MASK                      0x1
#define ACCDET_EINT0_PLUG_IN_MASK_SFT                  (0x1 << 5)
#define ACCDET_EINT0_M_PLUG_IN_ADDR                    \
	MT6359_ACCDET_CON30
#define ACCDET_EINT0_M_PLUG_IN_SFT                     6
#define ACCDET_EINT0_M_PLUG_IN_MASK                    0x1
#define ACCDET_EINT0_M_PLUG_IN_MASK_SFT                (0x1 << 6)
#define ACCDET_EINT1_M_EN_ADDR                         \
	MT6359_ACCDET_CON30
#define ACCDET_EINT1_M_EN_SFT                          7
#define ACCDET_EINT1_M_EN_MASK                         0x1
#define ACCDET_EINT1_M_EN_MASK_SFT                     (0x1 << 7)
#define ACCDET_EINT1_DETECT_MOISTURE_ADDR              \
	MT6359_ACCDET_CON30
#define ACCDET_EINT1_DETECT_MOISTURE_SFT               8
#define ACCDET_EINT1_DETECT_MOISTURE_MASK              0x1
#define ACCDET_EINT1_DETECT_MOISTURE_MASK_SFT          (0x1 << 8)
#define ACCDET_EINT1_PLUG_IN_ADDR                      \
	MT6359_ACCDET_CON30
#define ACCDET_EINT1_PLUG_IN_SFT                       9
#define ACCDET_EINT1_PLUG_IN_MASK                      0x1
#define ACCDET_EINT1_PLUG_IN_MASK_SFT                  (0x1 << 9)
#define ACCDET_EINT1_M_PLUG_IN_ADDR                    \
	MT6359_ACCDET_CON30
#define ACCDET_EINT1_M_PLUG_IN_SFT                     10
#define ACCDET_EINT1_M_PLUG_IN_MASK                    0x1
#define ACCDET_EINT1_M_PLUG_IN_MASK_SFT                (0x1 << 10)
#define ACCDET_CUR_DEB_ADDR                            \
	MT6359_ACCDET_CON31
#define ACCDET_CUR_DEB_SFT                             0
#define ACCDET_CUR_DEB_MASK                            0xFFFF
#define ACCDET_CUR_DEB_MASK_SFT                        (0xFFFF << 0)
#define ACCDET_EINT0_CUR_DEB_ADDR                      \
	MT6359_ACCDET_CON32
#define ACCDET_EINT0_CUR_DEB_SFT                       0
#define ACCDET_EINT0_CUR_DEB_MASK                      0x7FFF
#define ACCDET_EINT0_CUR_DEB_MASK_SFT                  (0x7FFF << 0)
#define ACCDET_EINT1_CUR_DEB_ADDR                      \
	MT6359_ACCDET_CON33
#define ACCDET_EINT1_CUR_DEB_SFT                       0
#define ACCDET_EINT1_CUR_DEB_MASK                      0x7FFF
#define ACCDET_EINT1_CUR_DEB_MASK_SFT                  (0x7FFF << 0)
#define ACCDET_EINT0_INVERTER_CUR_DEB_ADDR             \
	MT6359_ACCDET_CON34
#define ACCDET_EINT0_INVERTER_CUR_DEB_SFT              0
#define ACCDET_EINT0_INVERTER_CUR_DEB_MASK             0x7FFF
#define ACCDET_EINT0_INVERTER_CUR_DEB_MASK_SFT         (0x7FFF << 0)
#define ACCDET_EINT1_INVERTER_CUR_DEB_ADDR             \
	MT6359_ACCDET_CON35
#define ACCDET_EINT1_INVERTER_CUR_DEB_SFT              0
#define ACCDET_EINT1_INVERTER_CUR_DEB_MASK             0x7FFF
#define ACCDET_EINT1_INVERTER_CUR_DEB_MASK_SFT         (0x7FFF << 0)
#define AD_AUDACCDETCMPOB_MON_ADDR                     \
	MT6359_ACCDET_CON36
#define AD_AUDACCDETCMPOB_MON_SFT                      0
#define AD_AUDACCDETCMPOB_MON_MASK                     0x1
#define AD_AUDACCDETCMPOB_MON_MASK_SFT                 (0x1 << 0)
#define AD_AUDACCDETCMPOA_MON_ADDR                     \
	MT6359_ACCDET_CON36
#define AD_AUDACCDETCMPOA_MON_SFT                      1
#define AD_AUDACCDETCMPOA_MON_MASK                     0x1
#define AD_AUDACCDETCMPOA_MON_MASK_SFT                 (0x1 << 1)
#define AD_EINT0CMPMOUT_MON_ADDR                       \
	MT6359_ACCDET_CON36
#define AD_EINT0CMPMOUT_MON_SFT                        2
#define AD_EINT0CMPMOUT_MON_MASK                       0x1
#define AD_EINT0CMPMOUT_MON_MASK_SFT                   (0x1 << 2)
#define AD_EINT0CMPOUT_MON_ADDR                        \
	MT6359_ACCDET_CON36
#define AD_EINT0CMPOUT_MON_SFT                         3
#define AD_EINT0CMPOUT_MON_MASK                        0x1
#define AD_EINT0CMPOUT_MON_MASK_SFT                    (0x1 << 3)
#define AD_EINT0INVOUT_MON_ADDR                        \
	MT6359_ACCDET_CON36
#define AD_EINT0INVOUT_MON_SFT                         4
#define AD_EINT0INVOUT_MON_MASK                        0x1
#define AD_EINT0INVOUT_MON_MASK_SFT                    (0x1 << 4)
#define AD_EINT1CMPMOUT_MON_ADDR                       \
	MT6359_ACCDET_CON36
#define AD_EINT1CMPMOUT_MON_SFT                        5
#define AD_EINT1CMPMOUT_MON_MASK                       0x1
#define AD_EINT1CMPMOUT_MON_MASK_SFT                   (0x1 << 5)
#define AD_EINT1CMPOUT_MON_ADDR                        \
	MT6359_ACCDET_CON36
#define AD_EINT1CMPOUT_MON_SFT                         6
#define AD_EINT1CMPOUT_MON_MASK                        0x1
#define AD_EINT1CMPOUT_MON_MASK_SFT                    (0x1 << 6)
#define AD_EINT1INVOUT_MON_ADDR                        \
	MT6359_ACCDET_CON36
#define AD_EINT1INVOUT_MON_SFT                         7
#define AD_EINT1INVOUT_MON_MASK                        0x1
#define AD_EINT1INVOUT_MON_MASK_SFT                    (0x1 << 7)
#define DA_AUDACCDETCMPCLK_MON_ADDR                    \
	MT6359_ACCDET_CON37
#define DA_AUDACCDETCMPCLK_MON_SFT                     0
#define DA_AUDACCDETCMPCLK_MON_MASK                    0x1
#define DA_AUDACCDETCMPCLK_MON_MASK_SFT                (0x1 << 0)
#define DA_AUDACCDETVTHCLK_MON_ADDR                    \
	MT6359_ACCDET_CON37
#define DA_AUDACCDETVTHCLK_MON_SFT                     1
#define DA_AUDACCDETVTHCLK_MON_MASK                    0x1
#define DA_AUDACCDETVTHCLK_MON_MASK_SFT                (0x1 << 1)
#define DA_AUDACCDETMBIASCLK_MON_ADDR                  \
	MT6359_ACCDET_CON37
#define DA_AUDACCDETMBIASCLK_MON_SFT                   2
#define DA_AUDACCDETMBIASCLK_MON_MASK                  0x1
#define DA_AUDACCDETMBIASCLK_MON_MASK_SFT              (0x1 << 2)
#define DA_AUDACCDETAUXADCSWCTRL_MON_ADDR              \
	MT6359_ACCDET_CON37
#define DA_AUDACCDETAUXADCSWCTRL_MON_SFT               3
#define DA_AUDACCDETAUXADCSWCTRL_MON_MASK              0x1
#define DA_AUDACCDETAUXADCSWCTRL_MON_MASK_SFT          (0x1 << 3)
#define DA_EINT0CTURBO_MON_ADDR                        \
	MT6359_ACCDET_CON38
#define DA_EINT0CTURBO_MON_SFT                         0
#define DA_EINT0CTURBO_MON_MASK                        0x1
#define DA_EINT0CTURBO_MON_MASK_SFT                    (0x1 << 0)
#define DA_EINT0CMPMEN_MON_ADDR                        \
	MT6359_ACCDET_CON38
#define DA_EINT0CMPMEN_MON_SFT                         1
#define DA_EINT0CMPMEN_MON_MASK                        0x1
#define DA_EINT0CMPMEN_MON_MASK_SFT                    (0x1 << 1)
#define DA_EINT0CMPEN_MON_ADDR                         \
	MT6359_ACCDET_CON38
#define DA_EINT0CMPEN_MON_SFT                          2
#define DA_EINT0CMPEN_MON_MASK                         0x1
#define DA_EINT0CMPEN_MON_MASK_SFT                     (0x1 << 2)
#define DA_EINT0INVEN_MON_ADDR                         \
	MT6359_ACCDET_CON38
#define DA_EINT0INVEN_MON_SFT                          3
#define DA_EINT0INVEN_MON_MASK                         0x1
#define DA_EINT0INVEN_MON_MASK_SFT                     (0x1 << 3)
#define DA_EINT0CEN_MON_ADDR                           \
	MT6359_ACCDET_CON38
#define DA_EINT0CEN_MON_SFT                            4
#define DA_EINT0CEN_MON_MASK                           0x1
#define DA_EINT0CEN_MON_MASK_SFT                       (0x1 << 4)
#define DA_EINT0EN_MON_ADDR                            \
	MT6359_ACCDET_CON38
#define DA_EINT0EN_MON_SFT                             5
#define DA_EINT0EN_MON_MASK                            0x1
#define DA_EINT0EN_MON_MASK_SFT                        (0x1 << 5)
#define DA_EINT1CTURBO_MON_ADDR                        \
	MT6359_ACCDET_CON38
#define DA_EINT1CTURBO_MON_SFT                         8
#define DA_EINT1CTURBO_MON_MASK                        0x1
#define DA_EINT1CTURBO_MON_MASK_SFT                    (0x1 << 8)
#define DA_EINT1CMPMEN_MON_ADDR                        \
	MT6359_ACCDET_CON38
#define DA_EINT1CMPMEN_MON_SFT                         9
#define DA_EINT1CMPMEN_MON_MASK                        0x1
#define DA_EINT1CMPMEN_MON_MASK_SFT                    (0x1 << 9)
#define DA_EINT1CMPEN_MON_ADDR                         \
	MT6359_ACCDET_CON38
#define DA_EINT1CMPEN_MON_SFT                          10
#define DA_EINT1CMPEN_MON_MASK                         0x1
#define DA_EINT1CMPEN_MON_MASK_SFT                     (0x1 << 10)
#define DA_EINT1INVEN_MON_ADDR                         \
	MT6359_ACCDET_CON38
#define DA_EINT1INVEN_MON_SFT                          11
#define DA_EINT1INVEN_MON_MASK                         0x1
#define DA_EINT1INVEN_MON_MASK_SFT                     (0x1 << 11)
#define DA_EINT1CEN_MON_ADDR                           \
	MT6359_ACCDET_CON38
#define DA_EINT1CEN_MON_SFT                            12
#define DA_EINT1CEN_MON_MASK                           0x1
#define DA_EINT1CEN_MON_MASK_SFT                       (0x1 << 12)
#define DA_EINT1EN_MON_ADDR                            \
	MT6359_ACCDET_CON38
#define DA_EINT1EN_MON_SFT                             13
#define DA_EINT1EN_MON_MASK                            0x1
#define DA_EINT1EN_MON_MASK_SFT                        (0x1 << 13)
#define ACCDET_EINT0_M_PLUG_IN_COUNT_ADDR              \
	MT6359_ACCDET_CON39
#define ACCDET_EINT0_M_PLUG_IN_COUNT_SFT               0
#define ACCDET_EINT0_M_PLUG_IN_COUNT_MASK              0x7
#define ACCDET_EINT0_M_PLUG_IN_COUNT_MASK_SFT          (0x7 << 0)
#define ACCDET_EINT1_M_PLUG_IN_COUNT_ADDR              \
	MT6359_ACCDET_CON39
#define ACCDET_EINT1_M_PLUG_IN_COUNT_SFT               4
#define ACCDET_EINT1_M_PLUG_IN_COUNT_MASK              0x7
#define ACCDET_EINT1_M_PLUG_IN_COUNT_MASK_SFT          (0x7 << 4)
#define ACCDET_MON_FLAG_EN_ADDR                        \
	MT6359_ACCDET_CON40
#define ACCDET_MON_FLAG_EN_SFT                         0
#define ACCDET_MON_FLAG_EN_MASK                        0x1
#define ACCDET_MON_FLAG_EN_MASK_SFT                    (0x1 << 0)
#define ACCDET_MON_FLAG_SEL_ADDR                       \
	MT6359_ACCDET_CON40
#define ACCDET_MON_FLAG_SEL_SFT                        4
#define ACCDET_MON_FLAG_SEL_MASK                       0xF
#define ACCDET_MON_FLAG_SEL_MASK_SFT                   (0xF << 4)

#define RG_AUDPWDBMICBIAS0_ADDR                        \
	MT6359_AUDENC_ANA_CON15
#define RG_AUDPWDBMICBIAS0_SFT                         0
#define RG_AUDPWDBMICBIAS0_MASK                        0x1
#define RG_AUDPWDBMICBIAS0_MASK_SFT                    (0x1 << 0)
#define RG_AUDPREAMPLON_ADDR                           \
	MT6359_AUDENC_ANA_CON0
#define RG_AUDPREAMPLON_SFT                            0
#define RG_AUDPREAMPLON_MASK                           0x1
#define RG_AUDPREAMPLON_MASK_SFT                       (0x1 << 0)
#define RG_CLKSQ_EN_ADDR                               \
	MT6359_AUDENC_ANA_CON23
#define RG_CLKSQ_EN_SFT                                0
#define RG_CLKSQ_EN_MASK                               0x1
#define RG_CLKSQ_EN_MASK_SFT                           (0x1 << 0)
#define RG_RTC32K_CK_PDN_ADDR                          \
	MT6359_TOP_CKPDN_CON0
#define RG_RTC32K_CK_PDN_SFT                           15
#define RG_RTC32K_CK_PDN_MASK                          0x1
#define RG_RTC32K_CK_PDN_MASK_SFT                      (0x1 << 15)
#define RG_HPLOUTPUTSTBENH_VAUDP32_ADDR                \
	MT6359_AUDDEC_ANA_CON2
#define RG_HPLOUTPUTSTBENH_VAUDP32_SFT                 0
#define RG_HPLOUTPUTSTBENH_VAUDP32_MASK                0x7
#define RG_HPLOUTPUTSTBENH_VAUDP32_MASK_SFT            (0x7 << 0)
#define AUXADC_RQST_CH5_ADDR                           \
	MT6359_AUXADC_RQST0
#define AUXADC_RQST_CH5_SFT                            5
#define AUXADC_RQST_CH5_MASK                           0x1
#define AUXADC_RQST_CH5_MASK_SFT                       (0x1 << 5)
#define RG_LDO_VUSB_HW0_OP_EN_ADDR                     \
	MT6359_LDO_VUSB_OP_EN
#define RG_LDO_VUSB_HW0_OP_EN_SFT                      0
#define RG_LDO_VUSB_HW0_OP_EN_MASK                     0x1
#define RG_LDO_VUSB_HW0_OP_EN_MASK_SFT                 (0x1 << 0)
#define RG_HPROUTPUTSTBENH_VAUDP32_ADDR                \
	MT6359_AUDDEC_ANA_CON2
#define RG_HPROUTPUTSTBENH_VAUDP32_SFT                 4
#define RG_HPROUTPUTSTBENH_VAUDP32_MASK                0x7
#define RG_HPROUTPUTSTBENH_VAUDP32_MASK_SFT            (0x7 << 4)
#define RG_NCP_PDDIS_EN_ADDR                           \
	MT6359_AFE_NCP_CFG2
#define RG_NCP_PDDIS_EN_SFT                            0
#define RG_NCP_PDDIS_EN_MASK                           0x1
#define RG_NCP_PDDIS_EN_MASK_SFT                       (0x1 << 0)
#define RG_SCK32K_CK_PDN_ADDR                          \
	MT6359_TOP_CKPDN_CON0
#define RG_SCK32K_CK_PDN_SFT                           0
#define RG_SCK32K_CK_PDN_MASK                          0x1
#define RG_SCK32K_CK_PDN_MASK_SFT                      (0x1 << 0)
/* AUDENC_ANA_CON18: */
#define RG_ACCDET_MODE_ANA11_MODE1	(0x000F)
#define RG_ACCDET_MODE_ANA11_MODE2	(0x008F)
#define RG_ACCDET_MODE_ANA11_MODE6	(0x008F)

/* AUXADC_ADC5:  Auxadc CH5 read data */
#define AUXADC_DATA_RDY_CH5		BIT(15)
#define AUXADC_DATA_PROCEED_CH5		BIT(15)
#define AUXADC_DATA_MASK		(0x0FFF)

/* AUXADC_RQST0_SET:  Auxadc CH5 request, relevant 0x07EC */
#define AUXADC_RQST_CH5_SET		BIT(5)
/* AUXADC_RQST0_CLR:  Auxadc CH5 request, relevant 0x07EC */
#define AUXADC_RQST_CH5_CLR		BIT(5)

#define ACCDET_CALI_MASK0		(0xFF)
#define ACCDET_CALI_MASK1		(0xFF << 8)
#define ACCDET_CALI_MASK2		(0xFF)
#define ACCDET_CALI_MASK3		(0xFF << 8)
#define ACCDET_CALI_MASK4		(0xFF)

#define ACCDET_EINT_IRQ_B2_B3		(0x03 << ACCDET_EINT0_IRQ_SFT)

/* ACCDET_CON25: RO, accdet FSM state,etc.*/
#define ACCDET_STATE_MEM_IN_OFFSET	(ACCDET_MEM_IN_SFT)
#define ACCDET_STATE_AB_MASK		(0x03)
#define ACCDET_STATE_AB_00		(0x00)
#define ACCDET_STATE_AB_01		(0x01)
#define ACCDET_STATE_AB_10		(0x02)
#define ACCDET_STATE_AB_11		(0x03)

/* ACCDET_CON19 */
#define ACCDET_EINT0_STABLE_VAL ((ACCDET_DA_STABLE_MASK_SFT) | \
				(ACCDET_EINT0_EN_STABLE_MASK_SFT) | \
				(ACCDET_EINT0_CMPEN_STABLE_MASK_SFT) | \
				(ACCDET_EINT0_CEN_STABLE_MASK_SFT))

#define ACCDET_EINT1_STABLE_VAL ((ACCDET_DA_STABLE_MASK_SFT) | \
				(ACCDET_EINT1_EN_STABLE_MASK_SFT) | \
				(ACCDET_EINT1_CMPEN_STABLE_MASK_SFT) | \
				(ACCDET_EINT1_CEN_STABLE_MASK_SFT))
/* The following are used for mt6359.c */
/* MT6359_DCXO_CW12 */
#define RG_XO_AUDIO_EN_M_SFT				13

/* AUD_TOP_CKPDN_CON0 */
#define RG_VOW13M_CK_PDN_SFT				13
#define RG_VOW13M_CK_PDN_MASK				0x1
#define RG_VOW13M_CK_PDN_MASK_SFT			(0x1 << 13)
#define RG_VOW32K_CK_PDN_SFT				12
#define RG_VOW32K_CK_PDN_MASK				0x1
#define RG_VOW32K_CK_PDN_MASK_SFT			(0x1 << 12)
#define RG_AUD_INTRP_CK_PDN_SFT				8
#define RG_AUD_INTRP_CK_PDN_MASK			0x1
#define RG_AUD_INTRP_CK_PDN_MASK_SFT			(0x1 << 8)
#define RG_PAD_AUD_CLK_MISO_CK_PDN_SFT			7
#define RG_PAD_AUD_CLK_MISO_CK_PDN_MASK			0x1
#define RG_PAD_AUD_CLK_MISO_CK_PDN_MASK_SFT		(0x1 << 7)
#define RG_AUDNCP_CK_PDN_SFT				6
#define RG_AUDNCP_CK_PDN_MASK				0x1
#define RG_AUDNCP_CK_PDN_MASK_SFT			(0x1 << 6)
#define RG_ZCD13M_CK_PDN_SFT				5
#define RG_ZCD13M_CK_PDN_MASK				0x1
#define RG_ZCD13M_CK_PDN_MASK_SFT			(0x1 << 5)
#define RG_AUDIF_CK_PDN_SFT				2
#define RG_AUDIF_CK_PDN_MASK				0x1
#define RG_AUDIF_CK_PDN_MASK_SFT			(0x1 << 2)
#define RG_AUD_CK_PDN_SFT				1
#define RG_AUD_CK_PDN_MASK				0x1
#define RG_AUD_CK_PDN_MASK_SFT				(0x1 << 1)
#define RG_ACCDET_CK_PDN_SFT				0
#define RG_ACCDET_CK_PDN_MASK				0x1
#define RG_ACCDET_CK_PDN_MASK_SFT			(0x1 << 0)

/* AUD_TOP_CKPDN_CON0_SET */
#define RG_AUD_TOP_CKPDN_CON0_SET_SFT			0
#define RG_AUD_TOP_CKPDN_CON0_SET_MASK			0x3fff
#define RG_AUD_TOP_CKPDN_CON0_SET_MASK_SFT		(0x3fff << 0)

/* AUD_TOP_CKPDN_CON0_CLR */
#define RG_AUD_TOP_CKPDN_CON0_CLR_SFT			0
#define RG_AUD_TOP_CKPDN_CON0_CLR_MASK			0x3fff
#define RG_AUD_TOP_CKPDN_CON0_CLR_MASK_SFT		(0x3fff << 0)

/* AUD_TOP_CKSEL_CON0 */
#define RG_AUDIF_CK_CKSEL_SFT				3
#define RG_AUDIF_CK_CKSEL_MASK				0x1
#define RG_AUDIF_CK_CKSEL_MASK_SFT			(0x1 << 3)
#define RG_AUD_CK_CKSEL_SFT				2
#define RG_AUD_CK_CKSEL_MASK				0x1
#define RG_AUD_CK_CKSEL_MASK_SFT			(0x1 << 2)

/* AUD_TOP_CKSEL_CON0_SET */
#define RG_AUD_TOP_CKSEL_CON0_SET_SFT			0
#define RG_AUD_TOP_CKSEL_CON0_SET_MASK			0xf
#define RG_AUD_TOP_CKSEL_CON0_SET_MASK_SFT		(0xf << 0)

/* AUD_TOP_CKSEL_CON0_CLR */
#define RG_AUD_TOP_CKSEL_CON0_CLR_SFT			0
#define RG_AUD_TOP_CKSEL_CON0_CLR_MASK			0xf
#define RG_AUD_TOP_CKSEL_CON0_CLR_MASK_SFT		(0xf << 0)

/* AUD_TOP_CKTST_CON0 */
#define RG_VOW13M_CK_TSTSEL_SFT				9
#define RG_VOW13M_CK_TSTSEL_MASK			0x1
#define RG_VOW13M_CK_TSTSEL_MASK_SFT			(0x1 << 9)
#define RG_VOW13M_CK_TST_DIS_SFT			8
#define RG_VOW13M_CK_TST_DIS_MASK			0x1
#define RG_VOW13M_CK_TST_DIS_MASK_SFT			(0x1 << 8)
#define RG_AUD26M_CK_TSTSEL_SFT				4
#define RG_AUD26M_CK_TSTSEL_MASK			0x1
#define RG_AUD26M_CK_TSTSEL_MASK_SFT			(0x1 << 4)
#define RG_AUDIF_CK_TSTSEL_SFT				3
#define RG_AUDIF_CK_TSTSEL_MASK				0x1
#define RG_AUDIF_CK_TSTSEL_MASK_SFT			(0x1 << 3)
#define RG_AUD_CK_TSTSEL_SFT				2
#define RG_AUD_CK_TSTSEL_MASK				0x1
#define RG_AUD_CK_TSTSEL_MASK_SFT			(0x1 << 2)
#define RG_AUD26M_CK_TST_DIS_SFT			0
#define RG_AUD26M_CK_TST_DIS_MASK			0x1
#define RG_AUD26M_CK_TST_DIS_MASK_SFT			(0x1 << 0)

/* AUD_TOP_CLK_HWEN_CON0 */
#define RG_AUD_INTRP_CK_PDN_HWEN_SFT			0
#define RG_AUD_INTRP_CK_PDN_HWEN_MASK			0x1
#define RG_AUD_INTRP_CK_PDN_HWEN_MASK_SFT		(0x1 << 0)

/* AUD_TOP_CLK_HWEN_CON0_SET */
#define RG_AUD_INTRP_CK_PND_HWEN_CON0_SET_SFT		0
#define RG_AUD_INTRP_CK_PND_HWEN_CON0_SET_MASK		0xffff
#define RG_AUD_INTRP_CK_PND_HWEN_CON0_SET_MASK_SFT	(0xffff << 0)

/* AUD_TOP_CLK_HWEN_CON0_CLR */
#define RG_AUD_INTRP_CLK_PDN_HWEN_CON0_CLR_SFT		0
#define RG_AUD_INTRP_CLK_PDN_HWEN_CON0_CLR_MASK		0xffff
#define RG_AUD_INTRP_CLK_PDN_HWEN_CON0_CLR_MASK_SFT	(0xffff << 0)

/* AUD_TOP_RST_CON0 */
#define RG_AUDNCP_RST_SFT				3
#define RG_AUDNCP_RST_MASK				0x1
#define RG_AUDNCP_RST_MASK_SFT				(0x1 << 3)
#define RG_ZCD_RST_SFT					2
#define RG_ZCD_RST_MASK					0x1
#define RG_ZCD_RST_MASK_SFT				(0x1 << 2)
#define RG_ACCDET_RST_SFT				1
#define RG_ACCDET_RST_MASK				0x1
#define RG_ACCDET_RST_MASK_SFT				(0x1 << 1)
#define RG_AUDIO_RST_SFT				0
#define RG_AUDIO_RST_MASK				0x1
#define RG_AUDIO_RST_MASK_SFT				(0x1 << 0)

/* AUD_TOP_RST_CON0_SET */
#define RG_AUD_TOP_RST_CON0_SET_SFT			0
#define RG_AUD_TOP_RST_CON0_SET_MASK			0xf
#define RG_AUD_TOP_RST_CON0_SET_MASK_SFT		(0xf << 0)

/* AUD_TOP_RST_CON0_CLR */
#define RG_AUD_TOP_RST_CON0_CLR_SFT			0
#define RG_AUD_TOP_RST_CON0_CLR_MASK			0xf
#define RG_AUD_TOP_RST_CON0_CLR_MASK_SFT		(0xf << 0)

/* AUD_TOP_RST_BANK_CON0 */
#define BANK_AUDZCD_SWRST_SFT				2
#define BANK_AUDZCD_SWRST_MASK				0x1
#define BANK_AUDZCD_SWRST_MASK_SFT			(0x1 << 2)
#define BANK_AUDIO_SWRST_SFT				1
#define BANK_AUDIO_SWRST_MASK				0x1
#define BANK_AUDIO_SWRST_MASK_SFT			(0x1 << 1)
#define BANK_ACCDET_SWRST_SFT				0
#define BANK_ACCDET_SWRST_MASK				0x1
#define BANK_ACCDET_SWRST_MASK_SFT			(0x1 << 0)

/* AFE_UL_DL_CON0 */
#define AFE_UL_LR_SWAP_SFT				15
#define AFE_UL_LR_SWAP_MASK				0x1
#define AFE_UL_LR_SWAP_MASK_SFT				(0x1 << 15)
#define AFE_DL_LR_SWAP_SFT				14
#define AFE_DL_LR_SWAP_MASK				0x1
#define AFE_DL_LR_SWAP_MASK_SFT				(0x1 << 14)
#define AFE_ON_SFT					0
#define AFE_ON_MASK					0x1
#define AFE_ON_MASK_SFT					(0x1 << 0)

/* AFE_DL_SRC2_CON0_L */
#define DL_2_SRC_ON_TMP_CTL_PRE_SFT			0
#define DL_2_SRC_ON_TMP_CTL_PRE_MASK			0x1
#define DL_2_SRC_ON_TMP_CTL_PRE_MASK_SFT		(0x1 << 0)

/* AFE_UL_SRC_CON0_H */
#define C_DIGMIC_PHASE_SEL_CH1_CTL_SFT			11
#define C_DIGMIC_PHASE_SEL_CH1_CTL_MASK			0x7
#define C_DIGMIC_PHASE_SEL_CH1_CTL_MASK_SFT		(0x7 << 11)
#define C_DIGMIC_PHASE_SEL_CH2_CTL_SFT			8
#define C_DIGMIC_PHASE_SEL_CH2_CTL_MASK			0x7
#define C_DIGMIC_PHASE_SEL_CH2_CTL_MASK_SFT		(0x7 << 8)
#define C_TWO_DIGITAL_MIC_CTL_SFT			7
#define C_TWO_DIGITAL_MIC_CTL_MASK			0x1
#define C_TWO_DIGITAL_MIC_CTL_MASK_SFT			(0x1 << 7)

/* AFE_UL_SRC_CON0_L */
#define DMIC_LOW_POWER_MODE_CTL_SFT			14
#define DMIC_LOW_POWER_MODE_CTL_MASK			0x3
#define DMIC_LOW_POWER_MODE_CTL_MASK_SFT		(0x3 << 14)
#define DIGMIC_4P33M_SEL_CTL_SFT			6
#define DIGMIC_4P33M_SEL_CTL_MASK			0x1
#define DIGMIC_4P33M_SEL_CTL_MASK_SFT			(0x1 << 6)
#define DIGMIC_3P25M_1P625M_SEL_CTL_SFT			5
#define DIGMIC_3P25M_1P625M_SEL_CTL_MASK		0x1
#define DIGMIC_3P25M_1P625M_SEL_CTL_MASK_SFT		(0x1 << 5)
#define UL_LOOP_BACK_MODE_CTL_SFT			2
#define UL_LOOP_BACK_MODE_CTL_MASK			0x1
#define UL_LOOP_BACK_MODE_CTL_MASK_SFT			(0x1 << 2)
#define UL_SDM_3_LEVEL_CTL_SFT				1
#define UL_SDM_3_LEVEL_CTL_MASK				0x1
#define UL_SDM_3_LEVEL_CTL_MASK_SFT			(0x1 << 1)
#define UL_SRC_ON_TMP_CTL_SFT				0
#define UL_SRC_ON_TMP_CTL_MASK				0x1
#define UL_SRC_ON_TMP_CTL_MASK_SFT			(0x1 << 0)

/* AFE_ADDA6_L_SRC_CON0_H */
#define ADDA6_C_DIGMIC_PHASE_SEL_CH1_CTL_SFT		11
#define ADDA6_C_DIGMIC_PHASE_SEL_CH1_CTL_MASK		0x7
#define ADDA6_C_DIGMIC_PHASE_SEL_CH1_CTL_MASK_SFT	(0x7 << 11)
#define ADDA6_C_DIGMIC_PHASE_SEL_CH2_CTL_SFT		8
#define ADDA6_C_DIGMIC_PHASE_SEL_CH2_CTL_MASK		0x7
#define ADDA6_C_DIGMIC_PHASE_SEL_CH2_CTL_MASK_SFT	(0x7 << 8)
#define ADDA6_C_TWO_DIGITAL_MIC_CTL_SFT			7
#define ADDA6_C_TWO_DIGITAL_MIC_CTL_MASK		0x1
#define ADDA6_C_TWO_DIGITAL_MIC_CTL_MASK_SFT		(0x1 << 7)

/* AFE_ADDA6_UL_SRC_CON0_L */
#define ADDA6_DMIC_LOW_POWER_MODE_CTL_SFT		14
#define ADDA6_DMIC_LOW_POWER_MODE_CTL_MASK		0x3
#define ADDA6_DMIC_LOW_POWER_MODE_CTL_MASK_SFT		(0x3 << 14)
#define ADDA6_DIGMIC_4P33M_SEL_CTL_SFT			6
#define ADDA6_DIGMIC_4P33M_SEL_CTL_MASK			0x1
#define ADDA6_DIGMIC_4P33M_SEL_CTL_MASK_SFT		(0x1 << 6)
#define ADDA6_DIGMIC_3P25M_1P625M_SEL_CTL_SFT		5
#define ADDA6_DIGMIC_3P25M_1P625M_SEL_CTL_MASK		0x1
#define ADDA6_DIGMIC_3P25M_1P625M_SEL_CTL_MASK_SFT	(0x1 << 5)
#define ADDA6_UL_LOOP_BACK_MODE_CTL_SFT			2
#define ADDA6_UL_LOOP_BACK_MODE_CTL_MASK		0x1
#define ADDA6_UL_LOOP_BACK_MODE_CTL_MASK_SFT		(0x1 << 2)
#define ADDA6_UL_SDM_3_LEVEL_CTL_SFT			1
#define ADDA6_UL_SDM_3_LEVEL_CTL_MASK			0x1
#define ADDA6_UL_SDM_3_LEVEL_CTL_MASK_SFT		(0x1 << 1)
#define ADDA6_UL_SRC_ON_TMP_CTL_SFT			0
#define ADDA6_UL_SRC_ON_TMP_CTL_MASK			0x1
#define ADDA6_UL_SRC_ON_TMP_CTL_MASK_SFT		(0x1 << 0)

/* AFE_TOP_CON0 */
#define ADDA6_MTKAIF_SINE_ON_SFT			4
#define ADDA6_MTKAIF_SINE_ON_MASK			0x1
#define ADDA6_MTKAIF_SINE_ON_MASK_SFT			(0x1 << 4)
#define ADDA6_UL_SINE_ON_SFT				3
#define ADDA6_UL_SINE_ON_MASK				0x1
#define ADDA6_UL_SINE_ON_MASK_SFT			(0x1 << 3)
#define MTKAIF_SINE_ON_SFT				2
#define MTKAIF_SINE_ON_MASK				0x1
#define MTKAIF_SINE_ON_MASK_SFT				(0x1 << 2)
#define UL_SINE_ON_SFT					1
#define UL_SINE_ON_MASK					0x1
#define UL_SINE_ON_MASK_SFT				(0x1 << 1)
#define DL_SINE_ON_SFT					0
#define DL_SINE_ON_MASK					0x1
#define DL_SINE_ON_MASK_SFT				(0x1 << 0)

/* AUDIO_TOP_CON0 */
#define PDN_AFE_CTL_SFT					7
#define PDN_AFE_CTL_MASK				0x1
#define PDN_AFE_CTL_MASK_SFT				(0x1 << 7)
#define PDN_DAC_CTL_SFT					6
#define PDN_DAC_CTL_MASK				0x1
#define PDN_DAC_CTL_MASK_SFT				(0x1 << 6)
#define PDN_ADC_CTL_SFT					5
#define PDN_ADC_CTL_MASK				0x1
#define PDN_ADC_CTL_MASK_SFT				(0x1 << 5)
#define PDN_ADDA6_ADC_CTL_SFT				4
#define PDN_ADDA6_ADC_CTL_MASK				0x1
#define PDN_ADDA6_ADC_CTL_MASK_SFT			(0x1 << 4)
#define PDN_I2S_DL_CTL_SFT				3
#define PDN_I2S_DL_CTL_MASK				0x1
#define PDN_I2S_DL_CTL_MASK_SFT				(0x1 << 3)
#define PWR_CLK_DIS_CTL_SFT				2
#define PWR_CLK_DIS_CTL_MASK				0x1
#define PWR_CLK_DIS_CTL_MASK_SFT			(0x1 << 2)
#define PDN_AFE_TESTMODEL_CTL_SFT			1
#define PDN_AFE_TESTMODEL_CTL_MASK			0x1
#define PDN_AFE_TESTMODEL_CTL_MASK_SFT			(0x1 << 1)
#define PDN_RESERVED_SFT				0
#define PDN_RESERVED_MASK				0x1
#define PDN_RESERVED_MASK_SFT				(0x1 << 0)

/* AFE_MON_DEBUG0 */
#define AUDIO_SYS_TOP_MON_SWAP_SFT			14
#define AUDIO_SYS_TOP_MON_SWAP_MASK			0x3
#define AUDIO_SYS_TOP_MON_SWAP_MASK_SFT			(0x3 << 14)
#define AUDIO_SYS_TOP_MON_SEL_SFT			8
#define AUDIO_SYS_TOP_MON_SEL_MASK			0x1f
#define AUDIO_SYS_TOP_MON_SEL_MASK_SFT			(0x1f << 8)
#define AFE_MON_SEL_SFT					0
#define AFE_MON_SEL_MASK				0xff
#define AFE_MON_SEL_MASK_SFT				(0xff << 0)

/* AFUNC_AUD_CON0 */
#define CCI_AUD_ANACK_SEL_SFT				15
#define CCI_AUD_ANACK_SEL_MASK				0x1
#define CCI_AUD_ANACK_SEL_MASK_SFT			(0x1 << 15)
#define CCI_AUDIO_FIFO_WPTR_SFT				12
#define CCI_AUDIO_FIFO_WPTR_MASK			0x7
#define CCI_AUDIO_FIFO_WPTR_MASK_SFT			(0x7 << 12)
#define CCI_SCRAMBLER_CG_EN_SFT				11
#define CCI_SCRAMBLER_CG_EN_MASK			0x1
#define CCI_SCRAMBLER_CG_EN_MASK_SFT			(0x1 << 11)
#define CCI_LCH_INV_SFT					10
#define CCI_LCH_INV_MASK				0x1
#define CCI_LCH_INV_MASK_SFT				(0x1 << 10)
#define CCI_RAND_EN_SFT					9
#define CCI_RAND_EN_MASK				0x1
#define CCI_RAND_EN_MASK_SFT				(0x1 << 9)
#define CCI_SPLT_SCRMB_CLK_ON_SFT			8
#define CCI_SPLT_SCRMB_CLK_ON_MASK			0x1
#define CCI_SPLT_SCRMB_CLK_ON_MASK_SFT			(0x1 << 8)
#define CCI_SPLT_SCRMB_ON_SFT				7
#define CCI_SPLT_SCRMB_ON_MASK				0x1
#define CCI_SPLT_SCRMB_ON_MASK_SFT			(0x1 << 7)
#define CCI_AUD_IDAC_TEST_EN_SFT			6
#define CCI_AUD_IDAC_TEST_EN_MASK			0x1
#define CCI_AUD_IDAC_TEST_EN_MASK_SFT			(0x1 << 6)
#define CCI_ZERO_PAD_DISABLE_SFT			5
#define CCI_ZERO_PAD_DISABLE_MASK			0x1
#define CCI_ZERO_PAD_DISABLE_MASK_SFT			(0x1 << 5)
#define CCI_AUD_SPLIT_TEST_EN_SFT			4
#define CCI_AUD_SPLIT_TEST_EN_MASK			0x1
#define CCI_AUD_SPLIT_TEST_EN_MASK_SFT			(0x1 << 4)
#define CCI_AUD_SDM_MUTEL_SFT				3
#define CCI_AUD_SDM_MUTEL_MASK				0x1
#define CCI_AUD_SDM_MUTEL_MASK_SFT			(0x1 << 3)
#define CCI_AUD_SDM_MUTER_SFT				2
#define CCI_AUD_SDM_MUTER_MASK				0x1
#define CCI_AUD_SDM_MUTER_MASK_SFT			(0x1 << 2)
#define CCI_AUD_SDM_7BIT_SEL_SFT			1
#define CCI_AUD_SDM_7BIT_SEL_MASK			0x1
#define CCI_AUD_SDM_7BIT_SEL_MASK_SFT			(0x1 << 1)
#define CCI_SCRAMBLER_EN_SFT				0
#define CCI_SCRAMBLER_EN_MASK				0x1
#define CCI_SCRAMBLER_EN_MASK_SFT			(0x1 << 0)

/* AFUNC_AUD_CON1 */
#define AUD_SDM_TEST_L_SFT				8
#define AUD_SDM_TEST_L_MASK				0xff
#define AUD_SDM_TEST_L_MASK_SFT				(0xff << 8)
#define AUD_SDM_TEST_R_SFT				0
#define AUD_SDM_TEST_R_MASK				0xff
#define AUD_SDM_TEST_R_MASK_SFT				(0xff << 0)

/* AFUNC_AUD_CON2 */
#define CCI_AUD_DAC_ANA_MUTE_SFT			7
#define CCI_AUD_DAC_ANA_MUTE_MASK			0x1
#define CCI_AUD_DAC_ANA_MUTE_MASK_SFT			(0x1 << 7)
#define CCI_AUD_DAC_ANA_RSTB_SEL_SFT			6
#define CCI_AUD_DAC_ANA_RSTB_SEL_MASK			0x1
#define CCI_AUD_DAC_ANA_RSTB_SEL_MASK_SFT		(0x1 << 6)
#define CCI_AUDIO_FIFO_CLKIN_INV_SFT			4
#define CCI_AUDIO_FIFO_CLKIN_INV_MASK			0x1
#define CCI_AUDIO_FIFO_CLKIN_INV_MASK_SFT		(0x1 << 4)
#define CCI_AUDIO_FIFO_ENABLE_SFT			3
#define CCI_AUDIO_FIFO_ENABLE_MASK			0x1
#define CCI_AUDIO_FIFO_ENABLE_MASK_SFT			(0x1 << 3)
#define CCI_ACD_MODE_SFT				2
#define CCI_ACD_MODE_MASK				0x1
#define CCI_ACD_MODE_MASK_SFT				(0x1 << 2)
#define CCI_AFIFO_CLK_PWDB_SFT				1
#define CCI_AFIFO_CLK_PWDB_MASK				0x1
#define CCI_AFIFO_CLK_PWDB_MASK_SFT			(0x1 << 1)
#define CCI_ACD_FUNC_RSTB_SFT				0
#define CCI_ACD_FUNC_RSTB_MASK				0x1
#define CCI_ACD_FUNC_RSTB_MASK_SFT			(0x1 << 0)

/* AFUNC_AUD_CON3 */
#define SDM_ANA13M_TESTCK_SEL_SFT			15
#define SDM_ANA13M_TESTCK_SEL_MASK			0x1
#define SDM_ANA13M_TESTCK_SEL_MASK_SFT			(0x1 << 15)
#define SDM_ANA13M_TESTCK_SRC_SEL_SFT			12
#define SDM_ANA13M_TESTCK_SRC_SEL_MASK			0x7
#define SDM_ANA13M_TESTCK_SRC_SEL_MASK_SFT		(0x7 << 12)
#define SDM_TESTCK_SRC_SEL_SFT				8
#define SDM_TESTCK_SRC_SEL_MASK				0x7
#define SDM_TESTCK_SRC_SEL_MASK_SFT			(0x7 << 8)
#define DIGMIC_TESTCK_SRC_SEL_SFT			4
#define DIGMIC_TESTCK_SRC_SEL_MASK			0x7
#define DIGMIC_TESTCK_SRC_SEL_MASK_SFT			(0x7 << 4)
#define DIGMIC_TESTCK_SEL_SFT				0
#define DIGMIC_TESTCK_SEL_MASK				0x1
#define DIGMIC_TESTCK_SEL_MASK_SFT			(0x1 << 0)

/* AFUNC_AUD_CON4 */
#define UL_FIFO_WCLK_INV_SFT				8
#define UL_FIFO_WCLK_INV_MASK				0x1
#define UL_FIFO_WCLK_INV_MASK_SFT			(0x1 << 8)
#define UL_FIFO_DIGMIC_WDATA_TESTSRC_SEL_SFT		6
#define UL_FIFO_DIGMIC_WDATA_TESTSRC_SEL_MASK		0x1
#define UL_FIFO_DIGMIC_WDATA_TESTSRC_SEL_MASK_SFT	(0x1 << 6)
#define UL_FIFO_WDATA_TESTEN_SFT			5
#define UL_FIFO_WDATA_TESTEN_MASK			0x1
#define UL_FIFO_WDATA_TESTEN_MASK_SFT			(0x1 << 5)
#define UL_FIFO_WDATA_TESTSRC_SEL_SFT			4
#define UL_FIFO_WDATA_TESTSRC_SEL_MASK			0x1
#define UL_FIFO_WDATA_TESTSRC_SEL_MASK_SFT		(0x1 << 4)
#define UL_FIFO_WCLK_6P5M_TESTCK_SEL_SFT		 3
#define UL_FIFO_WCLK_6P5M_TESTCK_SEL_MASK		0x1
#define UL_FIFO_WCLK_6P5M_TESTCK_SEL_MASK_SFT		(0x1 << 3)
#define UL_FIFO_WCLK_6P5M_TESTCK_SRC_SEL_SFT		0
#define UL_FIFO_WCLK_6P5M_TESTCK_SRC_SEL_MASK		0x7
#define UL_FIFO_WCLK_6P5M_TESTCK_SRC_SEL_MASK_SFT	(0x7 << 0)

/* AFUNC_AUD_CON5 */
#define R_AUD_DAC_POS_LARGE_MONO_SFT			8
#define R_AUD_DAC_POS_LARGE_MONO_MASK			0xff
#define R_AUD_DAC_POS_LARGE_MONO_MASK_SFT		(0xff << 8)
#define R_AUD_DAC_NEG_LARGE_MONO_SFT			0
#define R_AUD_DAC_NEG_LARGE_MONO_MASK			0xff
#define R_AUD_DAC_NEG_LARGE_MONO_MASK_SFT		(0xff << 0)

/* AFUNC_AUD_CON6 */
#define R_AUD_DAC_POS_SMALL_MONO_SFT			12
#define R_AUD_DAC_POS_SMALL_MONO_MASK			0xf
#define R_AUD_DAC_POS_SMALL_MONO_MASK_SFT		(0xf << 12)
#define R_AUD_DAC_NEG_SMALL_MONO_SFT			8
#define R_AUD_DAC_NEG_SMALL_MONO_MASK			0xf
#define R_AUD_DAC_NEG_SMALL_MONO_MASK_SFT		(0xf << 8)
#define R_AUD_DAC_POS_TINY_MONO_SFT			6
#define R_AUD_DAC_POS_TINY_MONO_MASK			0x3
#define R_AUD_DAC_POS_TINY_MONO_MASK_SFT		(0x3 << 6)
#define R_AUD_DAC_NEG_TINY_MONO_SFT			4
#define R_AUD_DAC_NEG_TINY_MONO_MASK			0x3
#define R_AUD_DAC_NEG_TINY_MONO_MASK_SFT		(0x3 << 4)
#define R_AUD_DAC_MONO_SEL_SFT				3
#define R_AUD_DAC_MONO_SEL_MASK				0x1
#define R_AUD_DAC_MONO_SEL_MASK_SFT			(0x1 << 3)
#define R_AUD_DAC_3TH_SEL_SFT				1
#define R_AUD_DAC_3TH_SEL_MASK				0x1
#define R_AUD_DAC_3TH_SEL_MASK_SFT			(0x1 << 1)
#define R_AUD_DAC_SW_RSTB_SFT				0
#define R_AUD_DAC_SW_RSTB_MASK				0x1
#define R_AUD_DAC_SW_RSTB_MASK_SFT			(0x1 << 0)

/* AFUNC_AUD_CON7 */
#define UL2_DIGMIC_TESTCK_SRC_SEL_SFT			10
#define UL2_DIGMIC_TESTCK_SRC_SEL_MASK			0x7
#define UL2_DIGMIC_TESTCK_SRC_SEL_MASK_SFT		(0x7 << 10)
#define UL2_DIGMIC_TESTCK_SEL_SFT			9
#define UL2_DIGMIC_TESTCK_SEL_MASK			0x1
#define UL2_DIGMIC_TESTCK_SEL_MASK_SFT			(0x1 << 9)
#define UL2_FIFO_WCLK_INV_SFT				8
#define UL2_FIFO_WCLK_INV_MASK				0x1
#define UL2_FIFO_WCLK_INV_MASK_SFT			(0x1 << 8)
#define UL2_FIFO_DIGMIC_WDATA_TESTSRC_SEL_SFT		6
#define UL2_FIFO_DIGMIC_WDATA_TESTSRC_SEL_MASK		0x1
#define UL2_FIFO_DIGMIC_WDATA_TESTSRC_SEL_MASK_SFT	(0x1 << 6)
#define UL2_FIFO_WDATA_TESTEN_SFT			5
#define UL2_FIFO_WDATA_TESTEN_MASK			0x1
#define UL2_FIFO_WDATA_TESTEN_MASK_SFT			(0x1 << 5)
#define UL2_FIFO_WDATA_TESTSRC_SEL_SFT			4
#define UL2_FIFO_WDATA_TESTSRC_SEL_MASK			0x1
#define UL2_FIFO_WDATA_TESTSRC_SEL_MASK_SFT		(0x1 << 4)
#define UL2_FIFO_WCLK_6P5M_TESTCK_SEL_SFT		3
#define UL2_FIFO_WCLK_6P5M_TESTCK_SEL_MASK		0x1
#define UL2_FIFO_WCLK_6P5M_TESTCK_SEL_MASK_SFT		(0x1 << 3)
#define UL2_FIFO_WCLK_6P5M_TESTCK_SRC_SEL_SFT		0
#define UL2_FIFO_WCLK_6P5M_TESTCK_SRC_SEL_MASK		0x7
#define UL2_FIFO_WCLK_6P5M_TESTCK_SRC_SEL_MASK_SFT	(0x7 << 0)

/* AFUNC_AUD_CON8 */
#define SPLITTER2_DITHER_EN_SFT				9
#define SPLITTER2_DITHER_EN_MASK			0x1
#define SPLITTER2_DITHER_EN_MASK_SFT			(0x1 << 9)
#define SPLITTER1_DITHER_EN_SFT				8
#define SPLITTER1_DITHER_EN_MASK			0x1
#define SPLITTER1_DITHER_EN_MASK_SFT			(0x1 << 8)
#define SPLITTER2_DITHER_GAIN_SFT			4
#define SPLITTER2_DITHER_GAIN_MASK			0xf
#define SPLITTER2_DITHER_GAIN_MASK_SFT			(0xf << 4)
#define SPLITTER1_DITHER_GAIN_SFT			0
#define SPLITTER1_DITHER_GAIN_MASK			0xf
#define SPLITTER1_DITHER_GAIN_MASK_SFT			(0xf << 0)

/* AFUNC_AUD_CON9 */
#define CCI_AUD_ANACK_SEL_2ND_SFT			15
#define CCI_AUD_ANACK_SEL_2ND_MASK			0x1
#define CCI_AUD_ANACK_SEL_2ND_MASK_SFT			(0x1 << 15)
#define CCI_AUDIO_FIFO_WPTR_2ND_SFT			12
#define CCI_AUDIO_FIFO_WPTR_2ND_MASK			0x7
#define CCI_AUDIO_FIFO_WPTR_2ND_MASK_SFT		(0x7 << 12)
#define CCI_SCRAMBLER_CG_EN_2ND_SFT			11
#define CCI_SCRAMBLER_CG_EN_2ND_MASK			0x1
#define CCI_SCRAMBLER_CG_EN_2ND_MASK_SFT		 (0x1 << 11)
#define CCI_LCH_INV_2ND_SFT				10
#define CCI_LCH_INV_2ND_MASK				0x1
#define CCI_LCH_INV_2ND_MASK_SFT			(0x1 << 10)
#define CCI_RAND_EN_2ND_SFT				9
#define CCI_RAND_EN_2ND_MASK				0x1
#define CCI_RAND_EN_2ND_MASK_SFT			(0x1 << 9)
#define CCI_SPLT_SCRMB_CLK_ON_2ND_SFT			8
#define CCI_SPLT_SCRMB_CLK_ON_2ND_MASK			0x1
#define CCI_SPLT_SCRMB_CLK_ON_2ND_MASK_SFT		(0x1 << 8)
#define CCI_SPLT_SCRMB_ON_2ND_SFT			7
#define CCI_SPLT_SCRMB_ON_2ND_MASK			0x1
#define CCI_SPLT_SCRMB_ON_2ND_MASK_SFT			(0x1 << 7)
#define CCI_AUD_IDAC_TEST_EN_2ND_SFT			6
#define CCI_AUD_IDAC_TEST_EN_2ND_MASK			0x1
#define CCI_AUD_IDAC_TEST_EN_2ND_MASK_SFT		(0x1 << 6)
#define CCI_ZERO_PAD_DISABLE_2ND_SFT			5
#define CCI_ZERO_PAD_DISABLE_2ND_MASK			0x1
#define CCI_ZERO_PAD_DISABLE_2ND_MASK_SFT		(0x1 << 5)
#define CCI_AUD_SPLIT_TEST_EN_2ND_SFT			4
#define CCI_AUD_SPLIT_TEST_EN_2ND_MASK			0x1
#define CCI_AUD_SPLIT_TEST_EN_2ND_MASK_SFT		(0x1 << 4)
#define CCI_AUD_SDM_MUTEL_2ND_SFT			3
#define CCI_AUD_SDM_MUTEL_2ND_MASK			0x1
#define CCI_AUD_SDM_MUTEL_2ND_MASK_SFT			(0x1 << 3)
#define CCI_AUD_SDM_MUTER_2ND_SFT			2
#define CCI_AUD_SDM_MUTER_2ND_MASK			0x1
#define CCI_AUD_SDM_MUTER_2ND_MASK_SFT			(0x1 << 2)
#define CCI_AUD_SDM_7BIT_SEL_2ND_SFT			1
#define CCI_AUD_SDM_7BIT_SEL_2ND_MASK			0x1
#define CCI_AUD_SDM_7BIT_SEL_2ND_MASK_SFT		(0x1 << 1)
#define CCI_SCRAMBLER_EN_2ND_SFT			0
#define CCI_SCRAMBLER_EN_2ND_MASK			0x1
#define CCI_SCRAMBLER_EN_2ND_MASK_SFT			(0x1 << 0)

/* AFUNC_AUD_CON10 */
#define AUD_SDM_TEST_L_2ND_SFT				8
#define AUD_SDM_TEST_L_2ND_MASK				0xff
#define AUD_SDM_TEST_L_2ND_MASK_SFT			(0xff << 8)
#define AUD_SDM_TEST_R_2ND_SFT				0
#define AUD_SDM_TEST_R_2ND_MASK				0xff
#define AUD_SDM_TEST_R_2ND_MASK_SFT			(0xff << 0)

/* AFUNC_AUD_CON11 */
#define CCI_AUD_DAC_ANA_MUTE_2ND_SFT			7
#define CCI_AUD_DAC_ANA_MUTE_2ND_MASK			0x1
#define CCI_AUD_DAC_ANA_MUTE_2ND_MASK_SFT		(0x1 << 7)
#define CCI_AUD_DAC_ANA_RSTB_SEL_2ND_SFT		6
#define CCI_AUD_DAC_ANA_RSTB_SEL_2ND_MASK		0x1
#define CCI_AUD_DAC_ANA_RSTB_SEL_2ND_MASK_SFT		(0x1 << 6)
#define CCI_AUDIO_FIFO_CLKIN_INV_2ND_SFT		4
#define CCI_AUDIO_FIFO_CLKIN_INV_2ND_MASK		0x1
#define CCI_AUDIO_FIFO_CLKIN_INV_2ND_MASK_SFT		(0x1 << 4)
#define CCI_AUDIO_FIFO_ENABLE_2ND_SFT			3
#define CCI_AUDIO_FIFO_ENABLE_2ND_MASK			0x1
#define CCI_AUDIO_FIFO_ENABLE_2ND_MASK_SFT		(0x1 << 3)
#define CCI_ACD_MODE_2ND_SFT				2
#define CCI_ACD_MODE_2ND_MASK				0x1
#define CCI_ACD_MODE_2ND_MASK_SFT			(0x1 << 2)
#define CCI_AFIFO_CLK_PWDB_2ND_SFT			1
#define CCI_AFIFO_CLK_PWDB_2ND_MASK			0x1
#define CCI_AFIFO_CLK_PWDB_2ND_MASK_SFT			(0x1 << 1)
#define CCI_ACD_FUNC_RSTB_2ND_SFT			0
#define CCI_ACD_FUNC_RSTB_2ND_MASK			0x1
#define CCI_ACD_FUNC_RSTB_2ND_MASK_SFT			(0x1 << 0)

/* AFUNC_AUD_CON12 */
#define SPLITTER2_DITHER_EN_2ND_SFT			9
#define SPLITTER2_DITHER_EN_2ND_MASK			0x1
#define SPLITTER2_DITHER_EN_2ND_MASK_SFT		(0x1 << 9)
#define SPLITTER1_DITHER_EN_2ND_SFT			8
#define SPLITTER1_DITHER_EN_2ND_MASK			0x1
#define SPLITTER1_DITHER_EN_2ND_MASK_SFT		(0x1 << 8)
#define SPLITTER2_DITHER_GAIN_2ND_SFT			4
#define SPLITTER2_DITHER_GAIN_2ND_MASK			0xf
#define SPLITTER2_DITHER_GAIN_2ND_MASK_SFT		(0xf << 4)
#define SPLITTER1_DITHER_GAIN_2ND_SFT			0
#define SPLITTER1_DITHER_GAIN_2ND_MASK			0xf
#define SPLITTER1_DITHER_GAIN_2ND_MASK_SFT		(0xf << 0)

/* AFUNC_AUD_MON0 */
#define AUD_SCR_OUT_L_SFT				8
#define AUD_SCR_OUT_L_MASK				0xff
#define AUD_SCR_OUT_L_MASK_SFT				(0xff << 8)
#define AUD_SCR_OUT_R_SFT				0
#define AUD_SCR_OUT_R_MASK				0xff
#define AUD_SCR_OUT_R_MASK_SFT				(0xff << 0)

/* AFUNC_AUD_MON1 */
#define AUD_SCR_OUT_L_2ND_SFT				8
#define AUD_SCR_OUT_L_2ND_MASK				0xff
#define AUD_SCR_OUT_L_2ND_MASK_SFT			(0xff << 8)
#define AUD_SCR_OUT_R_2ND_SFT				0
#define AUD_SCR_OUT_R_2ND_MASK				0xff
#define AUD_SCR_OUT_R_2ND_MASK_SFT			(0xff << 0)

/* AUDRC_TUNE_MON0 */
#define ASYNC_TEST_OUT_BCK_SFT				15
#define ASYNC_TEST_OUT_BCK_MASK				0x1
#define ASYNC_TEST_OUT_BCK_MASK_SFT			(0x1 << 15)
#define RGS_AUDRCTUNE1READ_SFT				8
#define RGS_AUDRCTUNE1READ_MASK				0x1f
#define RGS_AUDRCTUNE1READ_MASK_SFT			(0x1f << 8)
#define RGS_AUDRCTUNE0READ_SFT				0
#define RGS_AUDRCTUNE0READ_MASK				0x1f
#define RGS_AUDRCTUNE0READ_MASK_SFT			(0x1f << 0)

/* AFE_ADDA_MTKAIF_FIFO_CFG0 */
#define AFE_RESERVED_SFT				1
#define AFE_RESERVED_MASK				0x7fff
#define AFE_RESERVED_MASK_SFT				(0x7fff << 1)
#define RG_MTKAIF_RXIF_FIFO_INTEN_SFT			0
#define RG_MTKAIF_RXIF_FIFO_INTEN_MASK			0x1
#define RG_MTKAIF_RXIF_FIFO_INTEN_MASK_SFT		(0x1 << 0)

/* AFE_ADDA_MTKAIF_FIFO_LOG_MON1 */
#define MTKAIF_RXIF_WR_FULL_STATUS_SFT			1
#define MTKAIF_RXIF_WR_FULL_STATUS_MASK			0x1
#define MTKAIF_RXIF_WR_FULL_STATUS_MASK_SFT		(0x1 << 1)
#define MTKAIF_RXIF_RD_EMPTY_STATUS_SFT			0
#define MTKAIF_RXIF_RD_EMPTY_STATUS_MASK		0x1
#define MTKAIF_RXIF_RD_EMPTY_STATUS_MASK_SFT		(0x1 << 0)

/* AFE_ADDA_MTKAIF_MON0 */
#define MTKAIFTX_V3_SYNC_OUT_SFT			15
#define MTKAIFTX_V3_SYNC_OUT_MASK			0x1
#define MTKAIFTX_V3_SYNC_OUT_MASK_SFT			(0x1 << 15)
#define MTKAIFTX_V3_SDATA_OUT3_SFT			14
#define MTKAIFTX_V3_SDATA_OUT3_MASK			0x1
#define MTKAIFTX_V3_SDATA_OUT3_MASK_SFT			(0x1 << 14)
#define MTKAIFTX_V3_SDATA_OUT2_SFT			13
#define MTKAIFTX_V3_SDATA_OUT2_MASK			0x1
#define MTKAIFTX_V3_SDATA_OUT2_MASK_SFT			(0x1 << 13)
#define MTKAIFTX_V3_SDATA_OUT1_SFT			12
#define MTKAIFTX_V3_SDATA_OUT1_MASK			0x1
#define MTKAIFTX_V3_SDATA_OUT1_MASK_SFT			(0x1 << 12)
#define MTKAIF_RXIF_FIFO_STATUS_SFT			0
#define MTKAIF_RXIF_FIFO_STATUS_MASK			0xfff
#define MTKAIF_RXIF_FIFO_STATUS_MASK_SFT		(0xfff << 0)

/* AFE_ADDA_MTKAIF_MON1 */
#define MTKAIFRX_V3_SYNC_IN_SFT				15
#define MTKAIFRX_V3_SYNC_IN_MASK			0x1
#define MTKAIFRX_V3_SYNC_IN_MASK_SFT			(0x1 << 15)
#define MTKAIFRX_V3_SDATA_IN3_SFT			14
#define MTKAIFRX_V3_SDATA_IN3_MASK			0x1
#define MTKAIFRX_V3_SDATA_IN3_MASK_SFT			(0x1 << 14)
#define MTKAIFRX_V3_SDATA_IN2_SFT			13
#define MTKAIFRX_V3_SDATA_IN2_MASK			0x1
#define MTKAIFRX_V3_SDATA_IN2_MASK_SFT			(0x1 << 13)
#define MTKAIFRX_V3_SDATA_IN1_SFT			12
#define MTKAIFRX_V3_SDATA_IN1_MASK			0x1
#define MTKAIFRX_V3_SDATA_IN1_MASK_SFT			(0x1 << 12)
#define MTKAIF_RXIF_SEARCH_FAIL_FLAG_SFT		11
#define MTKAIF_RXIF_SEARCH_FAIL_FLAG_MASK		0x1
#define MTKAIF_RXIF_SEARCH_FAIL_FLAG_MASK_SFT		(0x1 << 11)
#define MTKAIF_RXIF_INVALID_FLAG_SFT			8
#define MTKAIF_RXIF_INVALID_FLAG_MASK			0x1
#define MTKAIF_RXIF_INVALID_FLAG_MASK_SFT		(0x1 << 8)
#define MTKAIF_RXIF_INVALID_CYCLE_SFT			0
#define MTKAIF_RXIF_INVALID_CYCLE_MASK			0xff
#define MTKAIF_RXIF_INVALID_CYCLE_MASK_SFT		(0xff << 0)

/* AFE_ADDA_MTKAIF_MON2 */
#define MTKAIF_TXIF_IN_CH2_SFT				8
#define MTKAIF_TXIF_IN_CH2_MASK				0xff
#define MTKAIF_TXIF_IN_CH2_MASK_SFT			(0xff << 8)
#define MTKAIF_TXIF_IN_CH1_SFT				0
#define MTKAIF_TXIF_IN_CH1_MASK				0xff
#define MTKAIF_TXIF_IN_CH1_MASK_SFT			(0xff << 0)

/* AFE_ADDA6_MTKAIF_MON3 */
#define ADDA6_MTKAIF_TXIF_IN_CH2_SFT			8
#define ADDA6_MTKAIF_TXIF_IN_CH2_MASK			0xff
#define ADDA6_MTKAIF_TXIF_IN_CH2_MASK_SFT		(0xff << 8)
#define ADDA6_MTKAIF_TXIF_IN_CH1_SFT			0
#define ADDA6_MTKAIF_TXIF_IN_CH1_MASK			0xff
#define ADDA6_MTKAIF_TXIF_IN_CH1_MASK_SFT		(0xff << 0)

/* AFE_ADDA_MTKAIF_MON4 */
#define MTKAIF_RXIF_OUT_CH2_SFT				8
#define MTKAIF_RXIF_OUT_CH2_MASK			0xff
#define MTKAIF_RXIF_OUT_CH2_MASK_SFT			(0xff << 8)
#define MTKAIF_RXIF_OUT_CH1_SFT				0
#define MTKAIF_RXIF_OUT_CH1_MASK			0xff
#define MTKAIF_RXIF_OUT_CH1_MASK_SFT			(0xff << 0)

/* AFE_ADDA_MTKAIF_MON5 */
#define MTKAIF_RXIF_OUT_CH3_SFT				0
#define MTKAIF_RXIF_OUT_CH3_MASK			0xff
#define MTKAIF_RXIF_OUT_CH3_MASK_SFT			(0xff << 0)

/* AFE_ADDA_MTKAIF_CFG0 */
#define RG_MTKAIF_RXIF_CLKINV_SFT			15
#define RG_MTKAIF_RXIF_CLKINV_MASK			0x1
#define RG_MTKAIF_RXIF_CLKINV_MASK_SFT			(0x1 << 15)
#define RG_ADDA6_MTKAIF_TXIF_PROTOCOL2_SFT		9
#define RG_ADDA6_MTKAIF_TXIF_PROTOCOL2_MASK		0x1
#define RG_ADDA6_MTKAIF_TXIF_PROTOCOL2_MASK_SFT		(0x1 << 9)
#define RG_MTKAIF_RXIF_PROTOCOL2_SFT			8
#define RG_MTKAIF_RXIF_PROTOCOL2_MASK			0x1
#define RG_MTKAIF_RXIF_PROTOCOL2_MASK_SFT		(0x1 << 8)
#define RG_MTKAIF_BYPASS_SRC_MODE_SFT			6
#define RG_MTKAIF_BYPASS_SRC_MODE_MASK			0x3
#define RG_MTKAIF_BYPASS_SRC_MODE_MASK_SFT		(0x3 << 6)
#define RG_MTKAIF_BYPASS_SRC_TEST_SFT			5
#define RG_MTKAIF_BYPASS_SRC_TEST_MASK			0x1
#define RG_MTKAIF_BYPASS_SRC_TEST_MASK_SFT		(0x1 << 5)
#define RG_MTKAIF_TXIF_PROTOCOL2_SFT			4
#define RG_MTKAIF_TXIF_PROTOCOL2_MASK			0x1
#define RG_MTKAIF_TXIF_PROTOCOL2_MASK_SFT		(0x1 << 4)
#define RG_ADDA6_MTKAIF_PMIC_TXIF_8TO5_SFT		3
#define RG_ADDA6_MTKAIF_PMIC_TXIF_8TO5_MASK		0x1
#define RG_ADDA6_MTKAIF_PMIC_TXIF_8TO5_MASK_SFT		(0x1 << 3)
#define RG_MTKAIF_PMIC_TXIF_8TO5_SFT			2
#define RG_MTKAIF_PMIC_TXIF_8TO5_MASK			0x1
#define RG_MTKAIF_PMIC_TXIF_8TO5_MASK_SFT		(0x1 << 2)
#define RG_MTKAIF_LOOPBACK_TEST2_SFT			1
#define RG_MTKAIF_LOOPBACK_TEST2_MASK			0x1
#define RG_MTKAIF_LOOPBACK_TEST2_MASK_SFT		(0x1 << 1)
#define RG_MTKAIF_LOOPBACK_TEST1_SFT			0
#define RG_MTKAIF_LOOPBACK_TEST1_MASK			0x1
#define RG_MTKAIF_LOOPBACK_TEST1_MASK_SFT		(0x1 << 0)

/* AFE_ADDA_MTKAIF_RX_CFG0 */
#define RG_MTKAIF_RXIF_VOICE_MODE_SFT			12
#define RG_MTKAIF_RXIF_VOICE_MODE_MASK			0xf
#define RG_MTKAIF_RXIF_VOICE_MODE_MASK_SFT		(0xf << 12)
#define RG_MTKAIF_RXIF_DATA_BIT_SFT			8
#define RG_MTKAIF_RXIF_DATA_BIT_MASK			0x7
#define RG_MTKAIF_RXIF_DATA_BIT_MASK_SFT		(0x7 << 8)
#define RG_MTKAIF_RXIF_FIFO_RSP_SFT			4
#define RG_MTKAIF_RXIF_FIFO_RSP_MASK			0x7
#define RG_MTKAIF_RXIF_FIFO_RSP_MASK_SFT		(0x7 << 4)
#define RG_MTKAIF_RXIF_DETECT_ON_SFT			3
#define RG_MTKAIF_RXIF_DETECT_ON_MASK			0x1
#define RG_MTKAIF_RXIF_DETECT_ON_MASK_SFT		(0x1 << 3)
#define RG_MTKAIF_RXIF_DATA_MODE_SFT			0
#define RG_MTKAIF_RXIF_DATA_MODE_MASK			0x1
#define RG_MTKAIF_RXIF_DATA_MODE_MASK_SFT		(0x1 << 0)

/* AFE_ADDA_MTKAIF_RX_CFG1 */
#define RG_MTKAIF_RXIF_SYNC_SEARCH_TABLE_SFT		12
#define RG_MTKAIF_RXIF_SYNC_SEARCH_TABLE_MASK		0xf
#define RG_MTKAIF_RXIF_SYNC_SEARCH_TABLE_MASK_SFT	(0xf << 12)
#define RG_MTKAIF_RXIF_INVALID_SYNC_CHECK_ROUND_SFT	8
#define RG_MTKAIF_RXIF_INVALID_SYNC_CHECK_ROUND_MASK	0xf
#define RG_MTKAIF_RXIF_INVALID_SYNC_CHECK_ROUND_MASK_SFT	(0xf << 8)
#define RG_MTKAIF_RXIF_SYNC_CHECK_ROUND_SFT		4
#define RG_MTKAIF_RXIF_SYNC_CHECK_ROUND_MASK		0xf
#define RG_MTKAIF_RXIF_SYNC_CHECK_ROUND_MASK_SFT	(0xf << 4)
#define RG_MTKAIF_RXIF_VOICE_MODE_PROTOCOL2_SFT		0
#define RG_MTKAIF_RXIF_VOICE_MODE_PROTOCOL2_MASK	0xf
#define RG_MTKAIF_RXIF_VOICE_MODE_PROTOCOL2_MASK_SFT	(0xf << 0)

/* AFE_ADDA_MTKAIF_RX_CFG2 */
#define RG_MTKAIF_RXIF_P2_INPUT_SEL_SFT			15
#define RG_MTKAIF_RXIF_P2_INPUT_SEL_MASK		0x1
#define RG_MTKAIF_RXIF_P2_INPUT_SEL_MASK_SFT		(0x1 << 15)
#define RG_MTKAIF_RXIF_SYNC_WORD2_DISABLE_SFT		14
#define RG_MTKAIF_RXIF_SYNC_WORD2_DISABLE_MASK		0x1
#define RG_MTKAIF_RXIF_SYNC_WORD2_DISABLE_MASK_SFT	(0x1 << 14)
#define RG_MTKAIF_RXIF_SYNC_WORD1_DISABLE_SFT		13
#define RG_MTKAIF_RXIF_SYNC_WORD1_DISABLE_MASK		0x1
#define RG_MTKAIF_RXIF_SYNC_WORD1_DISABLE_MASK_SFT	(0x1 << 13)
#define RG_MTKAIF_RXIF_CLEAR_SYNC_FAIL_SFT		12
#define RG_MTKAIF_RXIF_CLEAR_SYNC_FAIL_MASK		0x1
#define RG_MTKAIF_RXIF_CLEAR_SYNC_FAIL_MASK_SFT		(0x1 << 12)
#define RG_MTKAIF_RXIF_SYNC_CNT_TABLE_SFT		0
#define RG_MTKAIF_RXIF_SYNC_CNT_TABLE_MASK		0xfff
#define RG_MTKAIF_RXIF_SYNC_CNT_TABLE_MASK_SFT		(0xfff << 0)

/* AFE_ADDA_MTKAIF_RX_CFG3 */
#define RG_MTKAIF_RXIF_LOOPBACK_USE_NLE_SFT		7
#define RG_MTKAIF_RXIF_LOOPBACK_USE_NLE_MASK		0x1
#define RG_MTKAIF_RXIF_LOOPBACK_USE_NLE_MASK_SFT	(0x1 << 7)
#define RG_MTKAIF_RXIF_FIFO_RSP_PROTOCOL2_SFT		4
#define RG_MTKAIF_RXIF_FIFO_RSP_PROTOCOL2_MASK		0x7
#define RG_MTKAIF_RXIF_FIFO_RSP_PROTOCOL2_MASK_SFT	(0x7 << 4)
#define RG_MTKAIF_RXIF_DETECT_ON_PROTOCOL2_SFT		3
#define RG_MTKAIF_RXIF_DETECT_ON_PROTOCOL2_MASK		0x1
#define RG_MTKAIF_RXIF_DETECT_ON_PROTOCOL2_MASK_SFT	(0x1 << 3)

/* AFE_ADDA_MTKAIF_SYNCWORD_CFG0 */
#define RG_MTKAIF_RX_SYNC_WORD2_SFT			4
#define RG_MTKAIF_RX_SYNC_WORD2_MASK			0x7
#define RG_MTKAIF_RX_SYNC_WORD2_MASK_SFT		(0x7 << 4)
#define RG_MTKAIF_RX_SYNC_WORD1_SFT			0
#define RG_MTKAIF_RX_SYNC_WORD1_MASK			0x7
#define RG_MTKAIF_RX_SYNC_WORD1_MASK_SFT		(0x7 << 0)

/* AFE_ADDA_MTKAIF_SYNCWORD_CFG1 */
#define RG_ADDA6_MTKAIF_TX_SYNC_WORD2_SFT		12
#define RG_ADDA6_MTKAIF_TX_SYNC_WORD2_MASK		0x7
#define RG_ADDA6_MTKAIF_TX_SYNC_WORD2_MASK_SFT		(0x7 << 12)
#define RG_ADDA6_MTKAIF_TX_SYNC_WORD1_SFT		8
#define RG_ADDA6_MTKAIF_TX_SYNC_WORD1_MASK		0x7
#define RG_ADDA6_MTKAIF_TX_SYNC_WORD1_MASK_SFT		(0x7 << 8)
#define RG_ADDA_MTKAIF_TX_SYNC_WORD2_SFT		4
#define RG_ADDA_MTKAIF_TX_SYNC_WORD2_MASK		0x7
#define RG_ADDA_MTKAIF_TX_SYNC_WORD2_MASK_SFT		(0x7 << 4)
#define RG_ADDA_MTKAIF_TX_SYNC_WORD1_SFT		0
#define RG_ADDA_MTKAIF_TX_SYNC_WORD1_MASK		0x7
#define RG_ADDA_MTKAIF_TX_SYNC_WORD1_MASK_SFT		(0x7 << 0)

/* AFE_SGEN_CFG0 */
#define SGEN_AMP_DIV_CH1_CTL_SFT			12
#define SGEN_AMP_DIV_CH1_CTL_MASK			0xf
#define SGEN_AMP_DIV_CH1_CTL_MASK_SFT			(0xf << 12)
#define SGEN_DAC_EN_CTL_SFT				7
#define SGEN_DAC_EN_CTL_MASK				0x1
#define SGEN_DAC_EN_CTL_MASK_SFT			(0x1 << 7)
#define SGEN_MUTE_SW_CTL_SFT				6
#define SGEN_MUTE_SW_CTL_MASK				0x1
#define SGEN_MUTE_SW_CTL_MASK_SFT			(0x1 << 6)
#define R_AUD_SDM_MUTE_L_SFT				5
#define R_AUD_SDM_MUTE_L_MASK				0x1
#define R_AUD_SDM_MUTE_L_MASK_SFT			(0x1 << 5)
#define R_AUD_SDM_MUTE_R_SFT				4
#define R_AUD_SDM_MUTE_R_MASK				0x1
#define R_AUD_SDM_MUTE_R_MASK_SFT			(0x1 << 4)
#define R_AUD_SDM_MUTE_L_2ND_SFT			3
#define R_AUD_SDM_MUTE_L_2ND_MASK			0x1
#define R_AUD_SDM_MUTE_L_2ND_MASK_SFT			(0x1 << 3)
#define R_AUD_SDM_MUTE_R_2ND_SFT			2
#define R_AUD_SDM_MUTE_R_2ND_MASK			0x1
#define R_AUD_SDM_MUTE_R_2ND_MASK_SFT			(0x1 << 2)

/* AFE_SGEN_CFG1 */
#define C_SGEN_RCH_INV_5BIT_SFT				15
#define C_SGEN_RCH_INV_5BIT_MASK			0x1
#define C_SGEN_RCH_INV_5BIT_MASK_SFT			(0x1 << 15)
#define C_SGEN_RCH_INV_8BIT_SFT				14
#define C_SGEN_RCH_INV_8BIT_MASK			0x1
#define C_SGEN_RCH_INV_8BIT_MASK_SFT			(0x1 << 14)
#define SGEN_FREQ_DIV_CH1_CTL_SFT			0
#define SGEN_FREQ_DIV_CH1_CTL_MASK			0x1f
#define SGEN_FREQ_DIV_CH1_CTL_MASK_SFT			(0x1f << 0)

/* AFE_ADC_ASYNC_FIFO_CFG */
#define RG_UL_ASYNC_FIFO_SOFT_RST_EN_SFT		5
#define RG_UL_ASYNC_FIFO_SOFT_RST_EN_MASK		0x1
#define RG_UL_ASYNC_FIFO_SOFT_RST_EN_MASK_SFT		(0x1 << 5)
#define RG_UL_ASYNC_FIFO_SOFT_RST_SFT			4
#define RG_UL_ASYNC_FIFO_SOFT_RST_MASK			0x1
#define RG_UL_ASYNC_FIFO_SOFT_RST_MASK_SFT		(0x1 << 4)
#define RG_AMIC_UL_ADC_CLK_SEL_SFT			1
#define RG_AMIC_UL_ADC_CLK_SEL_MASK			0x1
#define RG_AMIC_UL_ADC_CLK_SEL_MASK_SFT			(0x1 << 1)

/* AFE_ADC_ASYNC_FIFO_CFG1 */
#define RG_UL2_ASYNC_FIFO_SOFT_RST_EN_SFT		5
#define RG_UL2_ASYNC_FIFO_SOFT_RST_EN_MASK		0x1
#define RG_UL2_ASYNC_FIFO_SOFT_RST_EN_MASK_SFT		(0x1 << 5)
#define RG_UL2_ASYNC_FIFO_SOFT_RST_SFT			4
#define RG_UL2_ASYNC_FIFO_SOFT_RST_MASK			0x1
#define RG_UL2_ASYNC_FIFO_SOFT_RST_MASK_SFT		(0x1 << 4)

/* AFE_DCCLK_CFG0 */
#define DCCLK_DIV_SFT					5
#define DCCLK_DIV_MASK					0x7ff
#define DCCLK_DIV_MASK_SFT				(0x7ff << 5)
#define DCCLK_INV_SFT					4
#define DCCLK_INV_MASK					0x1
#define DCCLK_INV_MASK_SFT				(0x1 << 4)
#define DCCLK_REF_CK_SEL_SFT				2
#define DCCLK_REF_CK_SEL_MASK				0x3
#define DCCLK_REF_CK_SEL_MASK_SFT			(0x3 << 2)
#define DCCLK_PDN_SFT					1
#define DCCLK_PDN_MASK					0x1
#define DCCLK_PDN_MASK_SFT				(0x1 << 1)
#define DCCLK_GEN_ON_SFT				0
#define DCCLK_GEN_ON_MASK				0x1
#define DCCLK_GEN_ON_MASK_SFT				(0x1 << 0)

/* AFE_DCCLK_CFG1 */
#define RESYNC_SRC_SEL_SFT				10
#define RESYNC_SRC_SEL_MASK				0x3
#define RESYNC_SRC_SEL_MASK_SFT				(0x3 << 10)
#define RESYNC_SRC_CK_INV_SFT				9
#define RESYNC_SRC_CK_INV_MASK				0x1
#define RESYNC_SRC_CK_INV_MASK_SFT			(0x1 << 9)
#define DCCLK_RESYNC_BYPASS_SFT				8
#define DCCLK_RESYNC_BYPASS_MASK			0x1
#define DCCLK_RESYNC_BYPASS_MASK_SFT			(0x1 << 8)
#define DCCLK_PHASE_SEL_SFT				4
#define DCCLK_PHASE_SEL_MASK				0xf
#define DCCLK_PHASE_SEL_MASK_SFT			(0xf << 4)

/* AUDIO_DIG_CFG */
#define RG_AUD_PAD_TOP_DAT_MISO2_LOOPBACK_SFT		15
#define RG_AUD_PAD_TOP_DAT_MISO2_LOOPBACK_MASK		0x1
#define RG_AUD_PAD_TOP_DAT_MISO2_LOOPBACK_MASK_SFT	(0x1 << 15)
#define RG_AUD_PAD_TOP_PHASE_MODE2_SFT			8
#define RG_AUD_PAD_TOP_PHASE_MODE2_MASK			0x7f
#define RG_AUD_PAD_TOP_PHASE_MODE2_MASK_SFT		(0x7f << 8)
#define RG_AUD_PAD_TOP_DAT_MISO_LOOPBACK_SFT		7
#define RG_AUD_PAD_TOP_DAT_MISO_LOOPBACK_MASK		0x1
#define RG_AUD_PAD_TOP_DAT_MISO_LOOPBACK_MASK_SFT	(0x1 << 7)
#define RG_AUD_PAD_TOP_PHASE_MODE_SFT			0
#define RG_AUD_PAD_TOP_PHASE_MODE_MASK			0x7f
#define RG_AUD_PAD_TOP_PHASE_MODE_MASK_SFT		(0x7f << 0)

/* AUDIO_DIG_CFG1 */
#define RG_AUD_PAD_TOP_DAT_MISO3_LOOPBACK_SFT		7
#define RG_AUD_PAD_TOP_DAT_MISO3_LOOPBACK_MASK		0x1
#define RG_AUD_PAD_TOP_DAT_MISO3_LOOPBACK_MASK_SFT	(0x1 << 7)
#define RG_AUD_PAD_TOP_PHASE_MODE3_SFT			0
#define RG_AUD_PAD_TOP_PHASE_MODE3_MASK			0x7f
#define RG_AUD_PAD_TOP_PHASE_MODE3_MASK_SFT		(0x7f << 0)

/* AFE_AUD_PAD_TOP */
#define RG_AUD_PAD_TOP_TX_FIFO_RSP_SFT			12
#define RG_AUD_PAD_TOP_TX_FIFO_RSP_MASK			0x7
#define RG_AUD_PAD_TOP_TX_FIFO_RSP_MASK_SFT		(0x7 << 12)
#define RG_AUD_PAD_TOP_MTKAIF_CLK_PROTOCOL2_SFT		11
#define RG_AUD_PAD_TOP_MTKAIF_CLK_PROTOCOL2_MASK	0x1
#define RG_AUD_PAD_TOP_MTKAIF_CLK_PROTOCOL2_MASK_SFT	(0x1 << 11)
#define RG_AUD_PAD_TOP_TX_FIFO_ON_SFT			8
#define RG_AUD_PAD_TOP_TX_FIFO_ON_MASK			0x1
#define RG_AUD_PAD_TOP_TX_FIFO_ON_MASK_SFT		(0x1 << 8)

/* AFE_AUD_PAD_TOP_MON */
#define ADDA_AUD_PAD_TOP_MON_SFT			0
#define ADDA_AUD_PAD_TOP_MON_MASK			0xffff
#define ADDA_AUD_PAD_TOP_MON_MASK_SFT			(0xffff << 0)

/* AFE_AUD_PAD_TOP_MON1 */
#define ADDA_AUD_PAD_TOP_MON1_SFT			0
#define ADDA_AUD_PAD_TOP_MON1_MASK			0xffff
#define ADDA_AUD_PAD_TOP_MON1_MASK_SFT			(0xffff << 0)

/* AFE_AUD_PAD_TOP_MON2 */
#define ADDA_AUD_PAD_TOP_MON2_SFT			0
#define ADDA_AUD_PAD_TOP_MON2_MASK			0xffff
#define ADDA_AUD_PAD_TOP_MON2_MASK_SFT			(0xffff << 0)

/* AFE_DL_NLE_CFG */
#define NLE_RCH_HPGAIN_SEL_SFT				10
#define NLE_RCH_HPGAIN_SEL_MASK				0x1
#define NLE_RCH_HPGAIN_SEL_MASK_SFT			(0x1 << 10)
#define NLE_RCH_CH_SEL_SFT				9
#define NLE_RCH_CH_SEL_MASK				0x1
#define NLE_RCH_CH_SEL_MASK_SFT				(0x1 << 9)
#define NLE_RCH_ON_SFT					8
#define NLE_RCH_ON_MASK					0x1
#define NLE_RCH_ON_MASK_SFT				(0x1 << 8)
#define NLE_LCH_HPGAIN_SEL_SFT				2
#define NLE_LCH_HPGAIN_SEL_MASK				0x1
#define NLE_LCH_HPGAIN_SEL_MASK_SFT			(0x1 << 2)
#define NLE_LCH_CH_SEL_SFT				1
#define NLE_LCH_CH_SEL_MASK				0x1
#define NLE_LCH_CH_SEL_MASK_SFT				(0x1 << 1)
#define NLE_LCH_ON_SFT					0
#define NLE_LCH_ON_MASK					0x1
#define NLE_LCH_ON_MASK_SFT				(0x1 << 0)

/* AFE_DL_NLE_MON */
#define NLE_MONITOR_SFT					0
#define NLE_MONITOR_MASK				0x3fff
#define NLE_MONITOR_MASK_SFT				(0x3fff << 0)

/* AFE_CG_EN_MON */
#define CK_CG_EN_MON_SFT				0
#define CK_CG_EN_MON_MASK				0x3f
#define CK_CG_EN_MON_MASK_SFT				(0x3f << 0)

/* AFE_MIC_ARRAY_CFG */
#define RG_AMIC_ADC1_SOURCE_SEL_SFT			10
#define RG_AMIC_ADC1_SOURCE_SEL_MASK			0x3
#define RG_AMIC_ADC1_SOURCE_SEL_MASK_SFT		(0x3 << 10)
#define RG_AMIC_ADC2_SOURCE_SEL_SFT			8
#define RG_AMIC_ADC2_SOURCE_SEL_MASK			0x3
#define RG_AMIC_ADC2_SOURCE_SEL_MASK_SFT		(0x3 << 8)
#define RG_AMIC_ADC3_SOURCE_SEL_SFT			6
#define RG_AMIC_ADC3_SOURCE_SEL_MASK			0x3
#define RG_AMIC_ADC3_SOURCE_SEL_MASK_SFT		(0x3 << 6)
#define RG_DMIC_ADC1_SOURCE_SEL_SFT			4
#define RG_DMIC_ADC1_SOURCE_SEL_MASK			0x3
#define RG_DMIC_ADC1_SOURCE_SEL_MASK_SFT		(0x3 << 4)
#define RG_DMIC_ADC2_SOURCE_SEL_SFT			2
#define RG_DMIC_ADC2_SOURCE_SEL_MASK			0x3
#define RG_DMIC_ADC2_SOURCE_SEL_MASK_SFT		(0x3 << 2)
#define RG_DMIC_ADC3_SOURCE_SEL_SFT			0
#define RG_DMIC_ADC3_SOURCE_SEL_MASK			0x3
#define RG_DMIC_ADC3_SOURCE_SEL_MASK_SFT		(0x3 << 0)

/* AFE_CHOP_CFG0 */
#define RG_CHOP_DIV_SEL_SFT				4
#define RG_CHOP_DIV_SEL_MASK				0x1f
#define RG_CHOP_DIV_SEL_MASK_SFT			(0x1f << 4)
#define RG_CHOP_DIV_EN_SFT				0
#define RG_CHOP_DIV_EN_MASK				0x1
#define RG_CHOP_DIV_EN_MASK_SFT				(0x1 << 0)

/* AFE_MTKAIF_MUX_CFG */
#define RG_ADDA6_EN_SEL_SFT				12
#define RG_ADDA6_EN_SEL_MASK				0x1
#define RG_ADDA6_EN_SEL_MASK_SFT			(0x1 << 12)
#define RG_ADDA6_CH2_SEL_SFT				10
#define RG_ADDA6_CH2_SEL_MASK				0x3
#define RG_ADDA6_CH2_SEL_MASK_SFT			(0x3 << 10)
#define RG_ADDA6_CH1_SEL_SFT				8
#define RG_ADDA6_CH1_SEL_MASK				0x3
#define RG_ADDA6_CH1_SEL_MASK_SFT			(0x3 << 8)
#define RG_ADDA_EN_SEL_SFT				4
#define RG_ADDA_EN_SEL_MASK				0x1
#define RG_ADDA_EN_SEL_MASK_SFT				(0x1 << 4)
#define RG_ADDA_CH2_SEL_SFT				2
#define RG_ADDA_CH2_SEL_MASK				0x3
#define RG_ADDA_CH2_SEL_MASK_SFT			(0x3 << 2)
#define RG_ADDA_CH1_SEL_SFT				0
#define RG_ADDA_CH1_SEL_MASK				0x3
#define RG_ADDA_CH1_SEL_MASK_SFT			(0x3 << 0)

/* AFE_PMIC_NEWIF_CFG3 */
#define RG_UP8X_SYNC_WORD_SFT				0
#define RG_UP8X_SYNC_WORD_MASK				0xffff
#define RG_UP8X_SYNC_WORD_MASK_SFT			(0xffff << 0)

/* AFE_NCP_CFG0 */
#define  RG_NCP_CK1_VALID_CNT_SFT			9
#define  RG_NCP_CK1_VALID_CNT_MASK			0x7f
#define  RG_NCP_CK1_VALID_CNT_MASK_SFT			(0x7f << 9)
#define RG_NCP_ADITH_SFT				8
#define RG_NCP_ADITH_MASK				0x1
#define RG_NCP_ADITH_MASK_SFT				(0x1 << 8)
#define RG_NCP_DITHER_EN_SFT				7
#define RG_NCP_DITHER_EN_MASK				0x1
#define RG_NCP_DITHER_EN_MASK_SFT			(0x1 << 7)
#define RG_NCP_DITHER_FIXED_CK0_ACK1_2P_SFT		4
#define RG_NCP_DITHER_FIXED_CK0_ACK1_2P_MASK		0x7
#define RG_NCP_DITHER_FIXED_CK0_ACK1_2P_MASK_SFT	(0x7 << 4)
#define RG_NCP_DITHER_FIXED_CK0_ACK2_2P_SFT		1
#define RG_NCP_DITHER_FIXED_CK0_ACK2_2P_MASK		0x7
#define RG_NCP_DITHER_FIXED_CK0_ACK2_2P_MASK_SFT	(0x7 << 1)
#define RG_NCP_ON_SFT					0
#define RG_NCP_ON_MASK					0x1
#define RG_NCP_ON_MASK_SFT				(0x1 << 0)

/* AFE_NCP_CFG1 */
#define RG_XY_VAL_CFG_EN_SFT				15
#define RG_XY_VAL_CFG_EN_MASK				0x1
#define RG_XY_VAL_CFG_EN_MASK_SFT			(0x1 << 15)
#define RG_X_VAL_CFG_SFT				8
#define RG_X_VAL_CFG_MASK				0x7f
#define RG_X_VAL_CFG_MASK_SFT				(0x7f << 8)
#define RG_Y_VAL_CFG_SFT				0
#define RG_Y_VAL_CFG_MASK				0x7f
#define RG_Y_VAL_CFG_MASK_SFT				(0x7f << 0)

/* AFE_NCP_CFG2 */
#define RG_NCP_NONCLK_SET_SFT				1
#define RG_NCP_NONCLK_SET_MASK				0x1
#define RG_NCP_NONCLK_SET_MASK_SFT			(0x1 << 1)
#define RG_NCP_PDDIS_EN_SFT				0
#define RG_NCP_PDDIS_EN_MASK				0x1
#define RG_NCP_PDDIS_EN_MASK_SFT			(0x1 << 0)

/* AUDENC_ANA_CON0 */
#define RG_AUDPREAMPLON_SFT				0
#define RG_AUDPREAMPLON_MASK				0x1
#define RG_AUDPREAMPLON_MASK_SFT			(0x1 << 0)
#define RG_AUDPREAMPLDCCEN_SFT				1
#define RG_AUDPREAMPLDCCEN_MASK				0x1
#define RG_AUDPREAMPLDCCEN_MASK_SFT			(0x1 << 1)
#define RG_AUDPREAMPLDCPRECHARGE_SFT			2
#define RG_AUDPREAMPLDCPRECHARGE_MASK			0x1
#define RG_AUDPREAMPLDCPRECHARGE_MASK_SFT		(0x1 << 2)
#define RG_AUDPREAMPLPGATEST_SFT			3
#define RG_AUDPREAMPLPGATEST_MASK			0x1
#define RG_AUDPREAMPLPGATEST_MASK_SFT			(0x1 << 3)
#define RG_AUDPREAMPLVSCALE_SFT				4
#define RG_AUDPREAMPLVSCALE_MASK			0x3
#define RG_AUDPREAMPLVSCALE_MASK_SFT			(0x3 << 4)
#define RG_AUDPREAMPLINPUTSEL_SFT			6
#define RG_AUDPREAMPLINPUTSEL_MASK			0x3
#define RG_AUDPREAMPLINPUTSEL_MASK_SFT			(0x3 << 6)
#define RG_AUDPREAMPLGAIN_SFT				8
#define RG_AUDPREAMPLGAIN_MASK				0x7
#define RG_AUDPREAMPLGAIN_MASK_SFT			(0x7 << 8)
#define RG_BULKL_VCM_EN_SFT				11
#define RG_BULKL_VCM_EN_MASK				0x1
#define RG_BULKL_VCM_EN_MASK_SFT			(0x1 << 11)
#define RG_AUDADCLPWRUP_SFT				12
#define RG_AUDADCLPWRUP_MASK				0x1
#define RG_AUDADCLPWRUP_MASK_SFT			(0x1 << 12)
#define RG_AUDADCLINPUTSEL_SFT				13
#define RG_AUDADCLINPUTSEL_MASK				0x3
#define RG_AUDADCLINPUTSEL_MASK_SFT			(0x3 << 13)

/* AUDENC_ANA_CON1 */
#define RG_AUDPREAMPRON_SFT				0
#define RG_AUDPREAMPRON_MASK				0x1
#define RG_AUDPREAMPRON_MASK_SFT			(0x1 << 0)
#define RG_AUDPREAMPRDCCEN_SFT				1
#define RG_AUDPREAMPRDCCEN_MASK				0x1
#define RG_AUDPREAMPRDCCEN_MASK_SFT			(0x1 << 1)
#define RG_AUDPREAMPRDCPRECHARGE_SFT			2
#define RG_AUDPREAMPRDCPRECHARGE_MASK			0x1
#define RG_AUDPREAMPRDCPRECHARGE_MASK_SFT		(0x1 << 2)
#define RG_AUDPREAMPRPGATEST_SFT			3
#define RG_AUDPREAMPRPGATEST_MASK			0x1
#define RG_AUDPREAMPRPGATEST_MASK_SFT			(0x1 << 3)
#define RG_AUDPREAMPRVSCALE_SFT				4
#define RG_AUDPREAMPRVSCALE_MASK			0x3
#define RG_AUDPREAMPRVSCALE_MASK_SFT			(0x3 << 4)
#define RG_AUDPREAMPRINPUTSEL_SFT			6
#define RG_AUDPREAMPRINPUTSEL_MASK			0x3
#define RG_AUDPREAMPRINPUTSEL_MASK_SFT			(0x3 << 6)
#define RG_AUDPREAMPRGAIN_SFT				8
#define RG_AUDPREAMPRGAIN_MASK				0x7
#define RG_AUDPREAMPRGAIN_MASK_SFT			(0x7 << 8)
#define RG_BULKR_VCM_EN_SFT				11
#define RG_BULKR_VCM_EN_MASK				0x1
#define RG_BULKR_VCM_EN_MASK_SFT			(0x1 << 11)
#define RG_AUDADCRPWRUP_SFT				12
#define RG_AUDADCRPWRUP_MASK				0x1
#define RG_AUDADCRPWRUP_MASK_SFT			(0x1 << 12)
#define RG_AUDADCRINPUTSEL_SFT				13
#define RG_AUDADCRINPUTSEL_MASK				0x3
#define RG_AUDADCRINPUTSEL_MASK_SFT			(0x3 << 13)

/* AUDENC_ANA_CON2 */
#define RG_AUDPREAMP3ON_SFT				0
#define RG_AUDPREAMP3ON_MASK				0x1
#define RG_AUDPREAMP3ON_MASK_SFT			(0x1 << 0)
#define RG_AUDPREAMP3DCCEN_SFT				1
#define RG_AUDPREAMP3DCCEN_MASK				0x1
#define RG_AUDPREAMP3DCCEN_MASK_SFT			(0x1 << 1)
#define RG_AUDPREAMP3DCPRECHARGE_SFT			2
#define RG_AUDPREAMP3DCPRECHARGE_MASK			0x1
#define RG_AUDPREAMP3DCPRECHARGE_MASK_SFT		(0x1 << 2)
#define RG_AUDPREAMP3PGATEST_SFT			3
#define RG_AUDPREAMP3PGATEST_MASK			0x1
#define RG_AUDPREAMP3PGATEST_MASK_SFT			(0x1 << 3)
#define RG_AUDPREAMP3VSCALE_SFT				4
#define RG_AUDPREAMP3VSCALE_MASK			0x3
#define RG_AUDPREAMP3VSCALE_MASK_SFT			(0x3 << 4)
#define RG_AUDPREAMP3INPUTSEL_SFT			6
#define RG_AUDPREAMP3INPUTSEL_MASK			0x3
#define RG_AUDPREAMP3INPUTSEL_MASK_SFT			(0x3 << 6)
#define RG_AUDPREAMP3GAIN_SFT				8
#define RG_AUDPREAMP3GAIN_MASK				0x7
#define RG_AUDPREAMP3GAIN_MASK_SFT			(0x7 << 8)
#define RG_BULK3_VCM_EN_SFT				11
#define RG_BULK3_VCM_EN_MASK				0x1
#define RG_BULK3_VCM_EN_MASK_SFT			(0x1 << 11)
#define RG_AUDADC3PWRUP_SFT				12
#define RG_AUDADC3PWRUP_MASK				0x1
#define RG_AUDADC3PWRUP_MASK_SFT			(0x1 << 12)
#define RG_AUDADC3INPUTSEL_SFT				13
#define RG_AUDADC3INPUTSEL_MASK				0x3
#define RG_AUDADC3INPUTSEL_MASK_SFT			(0x3 << 13)

/* AUDENC_ANA_CON3 */
#define RG_AUDULHALFBIAS_SFT				0
#define RG_AUDULHALFBIAS_MASK				0x1
#define RG_AUDULHALFBIAS_MASK_SFT			(0x1 << 0)
#define RG_AUDGLBVOWLPWEN_SFT				1
#define RG_AUDGLBVOWLPWEN_MASK				0x1
#define RG_AUDGLBVOWLPWEN_MASK_SFT			(0x1 << 1)
#define RG_AUDPREAMPLPEN_SFT				2
#define RG_AUDPREAMPLPEN_MASK				0x1
#define RG_AUDPREAMPLPEN_MASK_SFT			(0x1 << 2)
#define RG_AUDADC1STSTAGELPEN_SFT			3
#define RG_AUDADC1STSTAGELPEN_MASK			0x1
#define RG_AUDADC1STSTAGELPEN_MASK_SFT			(0x1 << 3)
#define RG_AUDADC2NDSTAGELPEN_SFT			4
#define RG_AUDADC2NDSTAGELPEN_MASK			0x1
#define RG_AUDADC2NDSTAGELPEN_MASK_SFT			(0x1 << 4)
#define RG_AUDADCFLASHLPEN_SFT				5
#define RG_AUDADCFLASHLPEN_MASK				0x1
#define RG_AUDADCFLASHLPEN_MASK_SFT			(0x1 << 5)
#define RG_AUDPREAMPIDDTEST_SFT				6
#define RG_AUDPREAMPIDDTEST_MASK			0x3
#define RG_AUDPREAMPIDDTEST_MASK_SFT			(0x3 << 6)
#define RG_AUDADC1STSTAGEIDDTEST_SFT			8
#define RG_AUDADC1STSTAGEIDDTEST_MASK			0x3
#define RG_AUDADC1STSTAGEIDDTEST_MASK_SFT		(0x3 << 8)
#define RG_AUDADC2NDSTAGEIDDTEST_SFT			10
#define RG_AUDADC2NDSTAGEIDDTEST_MASK			0x3
#define RG_AUDADC2NDSTAGEIDDTEST_MASK_SFT		(0x3 << 10)
#define RG_AUDADCREFBUFIDDTEST_SFT			12
#define RG_AUDADCREFBUFIDDTEST_MASK			0x3
#define RG_AUDADCREFBUFIDDTEST_MASK_SFT			(0x3 << 12)
#define RG_AUDADCFLASHIDDTEST_SFT			14
#define RG_AUDADCFLASHIDDTEST_MASK			0x3
#define RG_AUDADCFLASHIDDTEST_MASK_SFT			(0x3 << 14)

/* AUDENC_ANA_CON4 */
#define RG_AUDRULHALFBIAS_SFT				0
#define RG_AUDRULHALFBIAS_MASK				0x1
#define RG_AUDRULHALFBIAS_MASK_SFT			(0x1 << 0)
#define RG_AUDGLBRVOWLPWEN_SFT				1
#define RG_AUDGLBRVOWLPWEN_MASK				0x1
#define RG_AUDGLBRVOWLPWEN_MASK_SFT			(0x1 << 1)
#define RG_AUDRPREAMPLPEN_SFT				2
#define RG_AUDRPREAMPLPEN_MASK				0x1
#define RG_AUDRPREAMPLPEN_MASK_SFT			(0x1 << 2)
#define RG_AUDRADC1STSTAGELPEN_SFT			3
#define RG_AUDRADC1STSTAGELPEN_MASK			0x1
#define RG_AUDRADC1STSTAGELPEN_MASK_SFT			(0x1 << 3)
#define RG_AUDRADC2NDSTAGELPEN_SFT			4
#define RG_AUDRADC2NDSTAGELPEN_MASK			0x1
#define RG_AUDRADC2NDSTAGELPEN_MASK_SFT			(0x1 << 4)
#define RG_AUDRADCFLASHLPEN_SFT				5
#define RG_AUDRADCFLASHLPEN_MASK			0x1
#define RG_AUDRADCFLASHLPEN_MASK_SFT			(0x1 << 5)
#define RG_AUDRPREAMPIDDTEST_SFT			6
#define RG_AUDRPREAMPIDDTEST_MASK			0x3
#define RG_AUDRPREAMPIDDTEST_MASK_SFT			(0x3 << 6)
#define RG_AUDRADC1STSTAGEIDDTEST_SFT			8
#define RG_AUDRADC1STSTAGEIDDTEST_MASK			0x3
#define RG_AUDRADC1STSTAGEIDDTEST_MASK_SFT		(0x3 << 8)
#define RG_AUDRADC2NDSTAGEIDDTEST_SFT			10
#define RG_AUDRADC2NDSTAGEIDDTEST_MASK			0x3
#define RG_AUDRADC2NDSTAGEIDDTEST_MASK_SFT		(0x3 << 10)
#define RG_AUDRADCREFBUFIDDTEST_SFT			12
#define RG_AUDRADCREFBUFIDDTEST_MASK			0x3
#define RG_AUDRADCREFBUFIDDTEST_MASK_SFT		(0x3 << 12)
#define RG_AUDRADCFLASHIDDTEST_SFT			14
#define RG_AUDRADCFLASHIDDTEST_MASK			0x3
#define RG_AUDRADCFLASHIDDTEST_MASK_SFT			(0x3 << 14)

/* AUDENC_ANA_CON5 */
#define RG_AUDADCCLKRSTB_SFT				0
#define RG_AUDADCCLKRSTB_MASK				0x1
#define RG_AUDADCCLKRSTB_MASK_SFT			(0x1 << 0)
#define RG_AUDADCCLKSEL_SFT				1
#define RG_AUDADCCLKSEL_MASK				0x3
#define RG_AUDADCCLKSEL_MASK_SFT			(0x3 << 1)
#define RG_AUDADCCLKSOURCE_SFT				3
#define RG_AUDADCCLKSOURCE_MASK				0x3
#define RG_AUDADCCLKSOURCE_MASK_SFT			(0x3 << 3)
#define RG_AUDADCCLKGENMODE_SFT				5
#define RG_AUDADCCLKGENMODE_MASK			0x3
#define RG_AUDADCCLKGENMODE_MASK_SFT			(0x3 << 5)
#define RG_AUDPREAMP_ACCFS_SFT				7
#define RG_AUDPREAMP_ACCFS_MASK				0x1
#define RG_AUDPREAMP_ACCFS_MASK_SFT			(0x1 << 7)
#define RG_AUDPREAMPAAFEN_SFT				8
#define RG_AUDPREAMPAAFEN_MASK				0x1
#define RG_AUDPREAMPAAFEN_MASK_SFT			(0x1 << 8)
#define RG_DCCVCMBUFLPMODSEL_SFT			9
#define RG_DCCVCMBUFLPMODSEL_MASK			0x1
#define RG_DCCVCMBUFLPMODSEL_MASK_SFT			(0x1 << 9)
#define RG_DCCVCMBUFLPSWEN_SFT				10
#define RG_DCCVCMBUFLPSWEN_MASK				0x1
#define RG_DCCVCMBUFLPSWEN_MASK_SFT			(0x1 << 10)
#define RG_AUDSPAREPGA_SFT				11
#define RG_AUDSPAREPGA_MASK				0x1f
#define RG_AUDSPAREPGA_MASK_SFT				(0x1f << 11)

/* AUDENC_ANA_CON6 */
#define RG_AUDADC1STSTAGESDENB_SFT			0
#define RG_AUDADC1STSTAGESDENB_MASK			0x1
#define RG_AUDADC1STSTAGESDENB_MASK_SFT			(0x1 << 0)
#define RG_AUDADC2NDSTAGERESET_SFT			1
#define RG_AUDADC2NDSTAGERESET_MASK			0x1
#define RG_AUDADC2NDSTAGERESET_MASK_SFT			(0x1 << 1)
#define RG_AUDADC3RDSTAGERESET_SFT			2
#define RG_AUDADC3RDSTAGERESET_MASK			0x1
#define RG_AUDADC3RDSTAGERESET_MASK_SFT			(0x1 << 2)
#define RG_AUDADCFSRESET_SFT				3
#define RG_AUDADCFSRESET_MASK				0x1
#define RG_AUDADCFSRESET_MASK_SFT			(0x1 << 3)
#define RG_AUDADCWIDECM_SFT				4
#define RG_AUDADCWIDECM_MASK				0x1
#define RG_AUDADCWIDECM_MASK_SFT			(0x1 << 4)
#define RG_AUDADCNOPATEST_SFT				5
#define RG_AUDADCNOPATEST_MASK				0x1
#define RG_AUDADCNOPATEST_MASK_SFT			(0x1 << 5)
#define RG_AUDADCBYPASS_SFT				6
#define RG_AUDADCBYPASS_MASK				0x1
#define RG_AUDADCBYPASS_MASK_SFT			(0x1 << 6)
#define RG_AUDADCFFBYPASS_SFT				7
#define RG_AUDADCFFBYPASS_MASK				0x1
#define RG_AUDADCFFBYPASS_MASK_SFT			(0x1 << 7)
#define RG_AUDADCDACFBCURRENT_SFT			8
#define RG_AUDADCDACFBCURRENT_MASK			0x1
#define RG_AUDADCDACFBCURRENT_MASK_SFT			(0x1 << 8)
#define RG_AUDADCDACIDDTEST_SFT				9
#define RG_AUDADCDACIDDTEST_MASK			0x3
#define RG_AUDADCDACIDDTEST_MASK_SFT			(0x3 << 9)
#define RG_AUDADCDACNRZ_SFT				11
#define RG_AUDADCDACNRZ_MASK				0x1
#define RG_AUDADCDACNRZ_MASK_SFT			(0x1 << 11)
#define RG_AUDADCNODEM_SFT				12
#define RG_AUDADCNODEM_MASK				0x1
#define RG_AUDADCNODEM_MASK_SFT				(0x1 << 12)
#define RG_AUDADCDACTEST_SFT				13
#define RG_AUDADCDACTEST_MASK				0x1
#define RG_AUDADCDACTEST_MASK_SFT			(0x1 << 13)
#define RG_AUDADCDAC0P25FS_SFT				14
#define RG_AUDADCDAC0P25FS_MASK				0x1
#define RG_AUDADCDAC0P25FS_MASK_SFT			(0x1 << 14)
#define RG_AUDADCRDAC0P25FS_SFT				15
#define RG_AUDADCRDAC0P25FS_MASK			0x1
#define RG_AUDADCRDAC0P25FS_MASK_SFT			(0x1 << 15)

/* AUDENC_ANA_CON7 */
#define RG_AUDADCTESTDATA_SFT				0
#define RG_AUDADCTESTDATA_MASK				0xffff
#define RG_AUDADCTESTDATA_MASK_SFT			(0xffff << 0)

/* AUDENC_ANA_CON8 */
#define RG_AUDRCTUNEL_SFT				0
#define RG_AUDRCTUNEL_MASK				0x1f
#define RG_AUDRCTUNEL_MASK_SFT				(0x1f << 0)
#define RG_AUDRCTUNELSEL_SFT				5
#define RG_AUDRCTUNELSEL_MASK				0x1
#define RG_AUDRCTUNELSEL_MASK_SFT			(0x1 << 5)
#define RG_AUDRCTUNER_SFT				8
#define RG_AUDRCTUNER_MASK				0x1f
#define RG_AUDRCTUNER_MASK_SFT				(0x1f << 8)
#define RG_AUDRCTUNERSEL_SFT				13
#define RG_AUDRCTUNERSEL_MASK				0x1
#define RG_AUDRCTUNERSEL_MASK_SFT			(0x1 << 13)

/* AUDENC_ANA_CON9 */
#define RG_AUD3CTUNEL_SFT				0
#define RG_AUD3CTUNEL_MASK				0x1f
#define RG_AUD3CTUNEL_MASK_SFT				(0x1f << 0)
#define RG_AUD3CTUNELSEL_SFT				5
#define RG_AUD3CTUNELSEL_MASK				0x1
#define RG_AUD3CTUNELSEL_MASK_SFT			(0x1 << 5)
#define RGS_AUDRCTUNE3READ_SFT				6
#define RGS_AUDRCTUNE3READ_MASK				0x1f
#define RGS_AUDRCTUNE3READ_MASK_SFT			(0x1f << 6)
#define RG_AUD3SPARE_SFT				11
#define RG_AUD3SPARE_MASK				0x1f
#define RG_AUD3SPARE_MASK_SFT				(0x1f << 11)

/* AUDENC_ANA_CON10 */
#define RGS_AUDRCTUNELREAD_SFT				0
#define RGS_AUDRCTUNELREAD_MASK				0x1f
#define RGS_AUDRCTUNELREAD_MASK_SFT			(0x1f << 0)
#define RGS_AUDRCTUNERREAD_SFT				8
#define RGS_AUDRCTUNERREAD_MASK				0x1f
#define RGS_AUDRCTUNERREAD_MASK_SFT			(0x1f << 8)

/* AUDENC_ANA_CON11 */
#define RG_AUDSPAREVA30_SFT				0
#define RG_AUDSPAREVA30_MASK				0xff
#define RG_AUDSPAREVA30_MASK_SFT			(0xff << 0)
#define RG_AUDSPAREVA18_SFT				8
#define RG_AUDSPAREVA18_MASK				0xff
#define RG_AUDSPAREVA18_MASK_SFT			(0xff << 8)

/* AUDENC_ANA_CON12 */
#define RG_AUDPGA_DECAP_SFT				0
#define RG_AUDPGA_DECAP_MASK				0x1
#define RG_AUDPGA_DECAP_MASK_SFT			(0x1 << 0)
#define RG_AUDPGA_CAPRA_SFT				1
#define RG_AUDPGA_CAPRA_MASK				0x1
#define RG_AUDPGA_CAPRA_MASK_SFT			(0x1 << 1)
#define RG_AUDPGA_ACCCMP_SFT				2
#define RG_AUDPGA_ACCCMP_MASK				0x1
#define RG_AUDPGA_ACCCMP_MASK_SFT			(0x1 << 2)
#define RG_AUDENC_SPARE2_SFT				3
#define RG_AUDENC_SPARE2_MASK				0x1fff
#define RG_AUDENC_SPARE2_MASK_SFT			(0x1fff << 3)

/* AUDENC_ANA_CON13 */
#define RG_AUDDIGMICEN_SFT				0
#define RG_AUDDIGMICEN_MASK				0x1
#define RG_AUDDIGMICEN_MASK_SFT				(0x1 << 0)
#define RG_AUDDIGMICBIAS_SFT				1
#define RG_AUDDIGMICBIAS_MASK				0x3
#define RG_AUDDIGMICBIAS_MASK_SFT			(0x3 << 1)
#define RG_DMICHPCLKEN_SFT				3
#define RG_DMICHPCLKEN_MASK				0x1
#define RG_DMICHPCLKEN_MASK_SFT				(0x1 << 3)
#define RG_AUDDIGMICPDUTY_SFT				4
#define RG_AUDDIGMICPDUTY_MASK				0x3
#define RG_AUDDIGMICPDUTY_MASK_SFT			(0x3 << 4)
#define RG_AUDDIGMICNDUTY_SFT				6
#define RG_AUDDIGMICNDUTY_MASK				0x3
#define RG_AUDDIGMICNDUTY_MASK_SFT			(0x3 << 6)
#define RG_DMICMONEN_SFT				8
#define RG_DMICMONEN_MASK				0x1
#define RG_DMICMONEN_MASK_SFT				(0x1 << 8)
#define RG_DMICMONSEL_SFT				9
#define RG_DMICMONSEL_MASK				0x7
#define RG_DMICMONSEL_MASK_SFT				(0x7 << 9)

/* AUDENC_ANA_CON14 */
#define RG_AUDDIGMIC1EN_SFT				0
#define RG_AUDDIGMIC1EN_MASK				0x1
#define RG_AUDDIGMIC1EN_MASK_SFT			(0x1 << 0)
#define RG_AUDDIGMICBIAS1_SFT				1
#define RG_AUDDIGMICBIAS1_MASK				0x3
#define RG_AUDDIGMICBIAS1_MASK_SFT			(0x3 << 1)
#define RG_DMIC1HPCLKEN_SFT				3
#define RG_DMIC1HPCLKEN_MASK				0x1
#define RG_DMIC1HPCLKEN_MASK_SFT			(0x1 << 3)
#define RG_AUDDIGMIC1PDUTY_SFT				4
#define RG_AUDDIGMIC1PDUTY_MASK				0x3
#define RG_AUDDIGMIC1PDUTY_MASK_SFT			(0x3 << 4)
#define RG_AUDDIGMIC1NDUTY_SFT				6
#define RG_AUDDIGMIC1NDUTY_MASK				0x3
#define RG_AUDDIGMIC1NDUTY_MASK_SFT			(0x3 << 6)
#define RG_DMIC1MONEN_SFT				8
#define RG_DMIC1MONEN_MASK				0x1
#define RG_DMIC1MONEN_MASK_SFT				(0x1 << 8)
#define RG_DMIC1MONSEL_SFT				9
#define RG_DMIC1MONSEL_MASK				0x7
#define RG_DMIC1MONSEL_MASK_SFT				(0x7 << 9)
#define RG_AUDSPAREVMIC_SFT				12
#define RG_AUDSPAREVMIC_MASK				0xf
#define RG_AUDSPAREVMIC_MASK_SFT			(0xf << 12)

/* AUDENC_ANA_CON15 */
#define RG_AUDPWDBMICBIAS0_SFT				0
#define RG_AUDPWDBMICBIAS0_MASK				0x1
#define RG_AUDPWDBMICBIAS0_MASK_SFT			(0x1 << 0)
#define RG_AUDMICBIAS0BYPASSEN_SFT			1
#define RG_AUDMICBIAS0BYPASSEN_MASK			0x1
#define RG_AUDMICBIAS0BYPASSEN_MASK_SFT			(0x1 << 1)
#define RG_AUDMICBIAS0LOWPEN_SFT			2
#define RG_AUDMICBIAS0LOWPEN_MASK			0x1
#define RG_AUDMICBIAS0LOWPEN_MASK_SFT			(0x1 << 2)
#define RG_AUDPWDBMICBIAS3_SFT				3
#define RG_AUDPWDBMICBIAS3_MASK				0x1
#define RG_AUDPWDBMICBIAS3_MASK_SFT			(0x1 << 3)
#define RG_AUDMICBIAS0VREF_SFT				4
#define RG_AUDMICBIAS0VREF_MASK				0x7
#define RG_AUDMICBIAS0VREF_MASK_SFT			(0x7 << 4)
#define RG_AUDMICBIAS0DCSW0P1EN_SFT			8
#define RG_AUDMICBIAS0DCSW0P1EN_MASK			0x1
#define RG_AUDMICBIAS0DCSW0P1EN_MASK_SFT		(0x1 << 8)
#define RG_AUDMICBIAS0DCSW0P2EN_SFT			9
#define RG_AUDMICBIAS0DCSW0P2EN_MASK			0x1
#define RG_AUDMICBIAS0DCSW0P2EN_MASK_SFT		(0x1 << 9)
#define RG_AUDMICBIAS0DCSW0NEN_SFT			10
#define RG_AUDMICBIAS0DCSW0NEN_MASK			0x1
#define RG_AUDMICBIAS0DCSW0NEN_MASK_SFT			(0x1 << 10)
#define RG_AUDMICBIAS0DCSW2P1EN_SFT			12
#define RG_AUDMICBIAS0DCSW2P1EN_MASK			0x1
#define RG_AUDMICBIAS0DCSW2P1EN_MASK_SFT		(0x1 << 12)
#define RG_AUDMICBIAS0DCSW2P2EN_SFT			13
#define RG_AUDMICBIAS0DCSW2P2EN_MASK			0x1
#define RG_AUDMICBIAS0DCSW2P2EN_MASK_SFT		(0x1 << 13)
#define RG_AUDMICBIAS0DCSW2NEN_SFT			14
#define RG_AUDMICBIAS0DCSW2NEN_MASK			0x1
#define RG_AUDMICBIAS0DCSW2NEN_MASK_SFT			(0x1 << 14)

/* AUDENC_ANA_CON16 */
#define RG_AUDPWDBMICBIAS1_SFT				0
#define RG_AUDPWDBMICBIAS1_MASK				0x1
#define RG_AUDPWDBMICBIAS1_MASK_SFT			(0x1 << 0)
#define RG_AUDMICBIAS1BYPASSEN_SFT			1
#define RG_AUDMICBIAS1BYPASSEN_MASK			0x1
#define RG_AUDMICBIAS1BYPASSEN_MASK_SFT			(0x1 << 1)
#define RG_AUDMICBIAS1LOWPEN_SFT			2
#define RG_AUDMICBIAS1LOWPEN_MASK			0x1
#define RG_AUDMICBIAS1LOWPEN_MASK_SFT			(0x1 << 2)
#define RG_AUDMICBIAS1VREF_SFT				4
#define RG_AUDMICBIAS1VREF_MASK				0x7
#define RG_AUDMICBIAS1VREF_MASK_SFT			(0x7 << 4)
#define RG_AUDMICBIAS1DCSW1PEN_SFT			8
#define RG_AUDMICBIAS1DCSW1PEN_MASK			0x1
#define RG_AUDMICBIAS1DCSW1PEN_MASK_SFT			(0x1 << 8)
#define RG_AUDMICBIAS1DCSW1NEN_SFT			9
#define RG_AUDMICBIAS1DCSW1NEN_MASK			0x1
#define RG_AUDMICBIAS1DCSW1NEN_MASK_SFT			(0x1 << 9)
#define RG_BANDGAPGEN_SFT				10
#define RG_BANDGAPGEN_MASK				0x1
#define RG_BANDGAPGEN_MASK_SFT				(0x1 << 10)
#define RG_AUDMICBIAS1HVEN_SFT				12
#define RG_AUDMICBIAS1HVEN_MASK				0x1
#define RG_AUDMICBIAS1HVEN_MASK_SFT			(0x1 << 12)
#define RG_AUDMICBIAS1HVVREF_SFT			13
#define RG_AUDMICBIAS1HVVREF_MASK			0x1
#define RG_AUDMICBIAS1HVVREF_MASK_SFT			(0x1 << 13)

/* AUDENC_ANA_CON17 */
#define RG_AUDPWDBMICBIAS2_SFT				0
#define RG_AUDPWDBMICBIAS2_MASK				0x1
#define RG_AUDPWDBMICBIAS2_MASK_SFT			(0x1 << 0)
#define RG_AUDMICBIAS2BYPASSEN_SFT			1
#define RG_AUDMICBIAS2BYPASSEN_MASK			0x1
#define RG_AUDMICBIAS2BYPASSEN_MASK_SFT			(0x1 << 1)
#define RG_AUDMICBIAS2LOWPEN_SFT			2
#define RG_AUDMICBIAS2LOWPEN_MASK			0x1
#define RG_AUDMICBIAS2LOWPEN_MASK_SFT			(0x1 << 2)
#define RG_AUDMICBIAS2VREF_SFT				4
#define RG_AUDMICBIAS2VREF_MASK				0x7
#define RG_AUDMICBIAS2VREF_MASK_SFT			(0x7 << 4)
#define RG_AUDMICBIAS2DCSW3P1EN_SFT			8
#define RG_AUDMICBIAS2DCSW3P1EN_MASK			0x1
#define RG_AUDMICBIAS2DCSW3P1EN_MASK_SFT		(0x1 << 8)
#define RG_AUDMICBIAS2DCSW3P2EN_SFT			9
#define RG_AUDMICBIAS2DCSW3P2EN_MASK			0x1
#define RG_AUDMICBIAS2DCSW3P2EN_MASK_SFT		(0x1 << 9)
#define RG_AUDMICBIAS2DCSW3NEN_SFT			10
#define RG_AUDMICBIAS2DCSW3NEN_MASK			0x1
#define RG_AUDMICBIAS2DCSW3NEN_MASK_SFT			(0x1 << 10)
#define RG_AUDMICBIASSPARE_SFT				12
#define RG_AUDMICBIASSPARE_MASK				0xf
#define RG_AUDMICBIASSPARE_MASK_SFT			(0xf << 12)

/* AUDENC_ANA_CON18 */
#define RG_AUDACCDETMICBIAS0PULLLOW_SFT			0
#define RG_AUDACCDETMICBIAS0PULLLOW_MASK		0x1
#define RG_AUDACCDETMICBIAS0PULLLOW_MASK_SFT		(0x1 << 0)
#define RG_AUDACCDETMICBIAS1PULLLOW_SFT			1
#define RG_AUDACCDETMICBIAS1PULLLOW_MASK		0x1
#define RG_AUDACCDETMICBIAS1PULLLOW_MASK_SFT		(0x1 << 1)
#define RG_AUDACCDETMICBIAS2PULLLOW_SFT			2
#define RG_AUDACCDETMICBIAS2PULLLOW_MASK		0x1
#define RG_AUDACCDETMICBIAS2PULLLOW_MASK_SFT		(0x1 << 2)
#define RG_AUDACCDETVIN1PULLLOW_SFT			3
#define RG_AUDACCDETVIN1PULLLOW_MASK			0x1
#define RG_AUDACCDETVIN1PULLLOW_MASK_SFT		(0x1 << 3)
#define RG_AUDACCDETVTHACAL_SFT				4
#define RG_AUDACCDETVTHACAL_MASK			0x1
#define RG_AUDACCDETVTHACAL_MASK_SFT			(0x1 << 4)
#define RG_AUDACCDETVTHBCAL_SFT				5
#define RG_AUDACCDETVTHBCAL_MASK			0x1
#define RG_AUDACCDETVTHBCAL_MASK_SFT			(0x1 << 5)
#define RG_AUDACCDETTVDET_SFT				6
#define RG_AUDACCDETTVDET_MASK				0x1
#define RG_AUDACCDETTVDET_MASK_SFT			(0x1 << 6)
#define RG_ACCDETSEL_SFT				7
#define RG_ACCDETSEL_MASK				0x1
#define RG_ACCDETSEL_MASK_SFT				(0x1 << 7)
#define RG_SWBUFMODSEL_SFT				8
#define RG_SWBUFMODSEL_MASK				0x1
#define RG_SWBUFMODSEL_MASK_SFT				(0x1 << 8)
#define RG_SWBUFSWEN_SFT				9
#define RG_SWBUFSWEN_MASK				0x1
#define RG_SWBUFSWEN_MASK_SFT				(0x1 << 9)
#define RG_EINT0NOHYS_SFT				10
#define RG_EINT0NOHYS_MASK				0x1
#define RG_EINT0NOHYS_MASK_SFT				(0x1 << 10)
#define RG_EINT0CONFIGACCDET_SFT			11
#define RG_EINT0CONFIGACCDET_MASK			0x1
#define RG_EINT0CONFIGACCDET_MASK_SFT			(0x1 << 11)
#define RG_EINT0HIRENB_SFT				12
#define RG_EINT0HIRENB_MASK				0x1
#define RG_EINT0HIRENB_MASK_SFT				(0x1 << 12)
#define RG_ACCDET2AUXRESBYPASS_SFT			13
#define RG_ACCDET2AUXRESBYPASS_MASK			0x1
#define RG_ACCDET2AUXRESBYPASS_MASK_SFT			(0x1 << 13)
#define RG_ACCDET2AUXSWEN_SFT				14
#define RG_ACCDET2AUXSWEN_MASK				0x1
#define RG_ACCDET2AUXSWEN_MASK_SFT			(0x1 << 14)
#define RG_AUDACCDETMICBIAS3PULLLOW_SFT			15
#define RG_AUDACCDETMICBIAS3PULLLOW_MASK		0x1
#define RG_AUDACCDETMICBIAS3PULLLOW_MASK_SFT		(0x1 << 15)

/* AUDENC_ANA_CON19 */
#define RG_EINT1CONFIGACCDET_SFT			0
#define RG_EINT1CONFIGACCDET_MASK			0x1
#define RG_EINT1CONFIGACCDET_MASK_SFT			(0x1 << 0)
#define RG_EINT1HIRENB_SFT				1
#define RG_EINT1HIRENB_MASK				0x1
#define RG_EINT1HIRENB_MASK_SFT				(0x1 << 1)
#define RG_EINT1NOHYS_SFT				2
#define RG_EINT1NOHYS_MASK				0x1
#define RG_EINT1NOHYS_MASK_SFT				(0x1 << 2)
#define RG_EINTCOMPVTH_SFT				4
#define RG_EINTCOMPVTH_MASK				0xf
#define RG_EINTCOMPVTH_MASK_SFT				(0xf << 4)
#define RG_MTEST_EN_SFT					8
#define RG_MTEST_EN_MASK				0x1
#define RG_MTEST_EN_MASK_SFT				(0x1 << 8)
#define RG_MTEST_SEL_SFT				9
#define RG_MTEST_SEL_MASK				0x1
#define RG_MTEST_SEL_MASK_SFT				(0x1 << 9)
#define RG_MTEST_CURRENT_SFT				10
#define RG_MTEST_CURRENT_MASK				0x1
#define RG_MTEST_CURRENT_MASK_SFT			(0x1 << 10)
#define RG_ANALOGFDEN_SFT				12
#define RG_ANALOGFDEN_MASK				0x1
#define RG_ANALOGFDEN_MASK_SFT				(0x1 << 12)
#define RG_FDVIN1PPULLLOW_SFT				13
#define RG_FDVIN1PPULLLOW_MASK				0x1
#define RG_FDVIN1PPULLLOW_MASK_SFT			(0x1 << 13)
#define RG_FDEINT0TYPE_SFT				14
#define RG_FDEINT0TYPE_MASK				0x1
#define RG_FDEINT0TYPE_MASK_SFT				(0x1 << 14)
#define RG_FDEINT1TYPE_SFT				15
#define RG_FDEINT1TYPE_MASK				0x1
#define RG_FDEINT1TYPE_MASK_SFT				(0x1 << 15)

/* AUDENC_ANA_CON20 */
#define RG_EINT0CMPEN_SFT				0
#define RG_EINT0CMPEN_MASK				0x1
#define RG_EINT0CMPEN_MASK_SFT				(0x1 << 0)
#define RG_EINT0CMPMEN_SFT				1
#define RG_EINT0CMPMEN_MASK				0x1
#define RG_EINT0CMPMEN_MASK_SFT				(0x1 << 1)
#define RG_EINT0EN_SFT					2
#define RG_EINT0EN_MASK					0x1
#define RG_EINT0EN_MASK_SFT				(0x1 << 2)
#define RG_EINT0CEN_SFT					3
#define RG_EINT0CEN_MASK				0x1
#define RG_EINT0CEN_MASK_SFT				(0x1 << 3)
#define RG_EINT0INVEN_SFT				4
#define RG_EINT0INVEN_MASK				0x1
#define RG_EINT0INVEN_MASK_SFT				(0x1 << 4)
#define RG_EINT0CTURBO_SFT				5
#define RG_EINT0CTURBO_MASK				0x7
#define RG_EINT0CTURBO_MASK_SFT				(0x7 << 5)
#define RG_EINT1CMPEN_SFT				8
#define RG_EINT1CMPEN_MASK				0x1
#define RG_EINT1CMPEN_MASK_SFT				(0x1 << 8)
#define RG_EINT1CMPMEN_SFT				9
#define RG_EINT1CMPMEN_MASK				0x1
#define RG_EINT1CMPMEN_MASK_SFT				(0x1 << 9)
#define RG_EINT1EN_SFT					10
#define RG_EINT1EN_MASK					0x1
#define RG_EINT1EN_MASK_SFT				(0x1 << 10)
#define RG_EINT1CEN_SFT					11
#define RG_EINT1CEN_MASK				0x1
#define RG_EINT1CEN_MASK_SFT				(0x1 << 11)
#define RG_EINT1INVEN_SFT				12
#define RG_EINT1INVEN_MASK				0x1
#define RG_EINT1INVEN_MASK_SFT				(0x1 << 12)
#define RG_EINT1CTURBO_SFT				13
#define RG_EINT1CTURBO_MASK				0x7
#define RG_EINT1CTURBO_MASK_SFT				(0x7 << 13)

/* AUDENC_ANA_CON21 */
#define RG_ACCDETSPARE_SFT				0
#define RG_ACCDETSPARE_MASK				0xffff
#define RG_ACCDETSPARE_MASK_SFT				(0xffff << 0)

/* AUDENC_ANA_CON22 */
#define RG_AUDENCSPAREVA30_SFT				0
#define RG_AUDENCSPAREVA30_MASK				0xff
#define RG_AUDENCSPAREVA30_MASK_SFT			(0xff << 0)
#define RG_AUDENCSPAREVA18_SFT				8
#define RG_AUDENCSPAREVA18_MASK				0xff
#define RG_AUDENCSPAREVA18_MASK_SFT			(0xff << 8)

/* AUDENC_ANA_CON23 */
#define RG_CLKSQ_EN_SFT					0
#define RG_CLKSQ_EN_MASK				0x1
#define RG_CLKSQ_EN_MASK_SFT				(0x1 << 0)
#define RG_CLKSQ_IN_SEL_TEST_SFT			1
#define RG_CLKSQ_IN_SEL_TEST_MASK			0x1
#define RG_CLKSQ_IN_SEL_TEST_MASK_SFT			(0x1 << 1)
#define RG_CM_REFGENSEL_SFT				2
#define RG_CM_REFGENSEL_MASK				0x1
#define RG_CM_REFGENSEL_MASK_SFT			(0x1 << 2)
#define RG_AUDIO_VOW_EN_SFT				3
#define RG_AUDIO_VOW_EN_MASK				0x1
#define RG_AUDIO_VOW_EN_MASK_SFT			(0x1 << 3)
#define RG_CLKSQ_EN_VOW_SFT				4
#define RG_CLKSQ_EN_VOW_MASK				0x1
#define RG_CLKSQ_EN_VOW_MASK_SFT			(0x1 << 4)
#define RG_CLKAND_EN_VOW_SFT				5
#define RG_CLKAND_EN_VOW_MASK				0x1
#define RG_CLKAND_EN_VOW_MASK_SFT			(0x1 << 5)
#define RG_VOWCLK_SEL_EN_VOW_SFT			6
#define RG_VOWCLK_SEL_EN_VOW_MASK			0x1
#define RG_VOWCLK_SEL_EN_VOW_MASK_SFT			(0x1 << 6)
#define RG_SPARE_VOW_SFT				7
#define RG_SPARE_VOW_MASK				0x7
#define RG_SPARE_VOW_MASK_SFT				(0x7 << 7)

/* AUDDEC_ANA_CON0 */
#define RG_AUDDACLPWRUP_VAUDP32_SFT			0
#define RG_AUDDACLPWRUP_VAUDP32_MASK			0x1
#define RG_AUDDACLPWRUP_VAUDP32_MASK_SFT		(0x1 << 0)
#define RG_AUDDACRPWRUP_VAUDP32_SFT			1
#define RG_AUDDACRPWRUP_VAUDP32_MASK			0x1
#define RG_AUDDACRPWRUP_VAUDP32_MASK_SFT		(0x1 << 1)
#define RG_AUD_DAC_PWR_UP_VA32_SFT			2
#define RG_AUD_DAC_PWR_UP_VA32_MASK			0x1
#define RG_AUD_DAC_PWR_UP_VA32_MASK_SFT			(0x1 << 2)
#define RG_AUD_DAC_PWL_UP_VA32_SFT			3
#define RG_AUD_DAC_PWL_UP_VA32_MASK			0x1
#define RG_AUD_DAC_PWL_UP_VA32_MASK_SFT			(0x1 << 3)
#define RG_AUDHPLPWRUP_VAUDP32_SFT			4
#define RG_AUDHPLPWRUP_VAUDP32_MASK			0x1
#define RG_AUDHPLPWRUP_VAUDP32_MASK_SFT			(0x1 << 4)
#define RG_AUDHPRPWRUP_VAUDP32_SFT			5
#define RG_AUDHPRPWRUP_VAUDP32_MASK			0x1
#define RG_AUDHPRPWRUP_VAUDP32_MASK_SFT			(0x1 << 5)
#define RG_AUDHPLPWRUP_IBIAS_VAUDP32_SFT		6
#define RG_AUDHPLPWRUP_IBIAS_VAUDP32_MASK		0x1
#define RG_AUDHPLPWRUP_IBIAS_VAUDP32_MASK_SFT		(0x1 << 6)
#define RG_AUDHPRPWRUP_IBIAS_VAUDP32_SFT		7
#define RG_AUDHPRPWRUP_IBIAS_VAUDP32_MASK		0x1
#define RG_AUDHPRPWRUP_IBIAS_VAUDP32_MASK_SFT		(0x1 << 7)
#define RG_AUDHPLMUXINPUTSEL_VAUDP32_SFT		8
#define RG_AUDHPLMUXINPUTSEL_VAUDP32_MASK		0x3
#define RG_AUDHPLMUXINPUTSEL_VAUDP32_MASK_SFT		(0x3 << 8)
#define RG_AUDHPRMUXINPUTSEL_VAUDP32_SFT		10
#define RG_AUDHPRMUXINPUTSEL_VAUDP32_MASK		0x3
#define RG_AUDHPRMUXINPUTSEL_VAUDP32_MASK_SFT		(0x3 << 10)
#define RG_AUDHPLSCDISABLE_VAUDP32_SFT			12
#define RG_AUDHPLSCDISABLE_VAUDP32_MASK			0x1
#define RG_AUDHPLSCDISABLE_VAUDP32_MASK_SFT		(0x1 << 12)
#define RG_AUDHPRSCDISABLE_VAUDP32_SFT			13
#define RG_AUDHPRSCDISABLE_VAUDP32_MASK			0x1
#define RG_AUDHPRSCDISABLE_VAUDP32_MASK_SFT		(0x1 << 13)
#define RG_AUDHPLBSCCURRENT_VAUDP32_SFT			14
#define RG_AUDHPLBSCCURRENT_VAUDP32_MASK		0x1
#define RG_AUDHPLBSCCURRENT_VAUDP32_MASK_SFT		(0x1 << 14)
#define RG_AUDHPRBSCCURRENT_VAUDP32_SFT			15
#define RG_AUDHPRBSCCURRENT_VAUDP32_MASK		0x1
#define RG_AUDHPRBSCCURRENT_VAUDP32_MASK_SFT		(0x1 << 15)

/* AUDDEC_ANA_CON1 */
#define RG_AUDHPLOUTPWRUP_VAUDP32_SFT			0
#define RG_AUDHPLOUTPWRUP_VAUDP32_MASK			0x1
#define RG_AUDHPLOUTPWRUP_VAUDP32_MASK_SFT		(0x1 << 0)
#define RG_AUDHPROUTPWRUP_VAUDP32_SFT			1
#define RG_AUDHPROUTPWRUP_VAUDP32_MASK			0x1
#define RG_AUDHPROUTPWRUP_VAUDP32_MASK_SFT		(0x1 << 1)
#define RG_AUDHPLOUTAUXPWRUP_VAUDP32_SFT		2
#define RG_AUDHPLOUTAUXPWRUP_VAUDP32_MASK		0x1
#define RG_AUDHPLOUTAUXPWRUP_VAUDP32_MASK_SFT		(0x1 << 2)
#define RG_AUDHPROUTAUXPWRUP_VAUDP32_SFT		3
#define RG_AUDHPROUTAUXPWRUP_VAUDP32_MASK		0x1
#define RG_AUDHPROUTAUXPWRUP_VAUDP32_MASK_SFT		(0x1 << 3)
#define RG_HPLAUXFBRSW_EN_VAUDP32_SFT			4
#define RG_HPLAUXFBRSW_EN_VAUDP32_MASK			0x1
#define RG_HPLAUXFBRSW_EN_VAUDP32_MASK_SFT		(0x1 << 4)
#define RG_HPRAUXFBRSW_EN_VAUDP32_SFT			5
#define RG_HPRAUXFBRSW_EN_VAUDP32_MASK			0x1
#define RG_HPRAUXFBRSW_EN_VAUDP32_MASK_SFT		(0x1 << 5)
#define RG_HPLSHORT2HPLAUX_EN_VAUDP32_SFT		6
#define RG_HPLSHORT2HPLAUX_EN_VAUDP32_MASK		0x1
#define RG_HPLSHORT2HPLAUX_EN_VAUDP32_MASK_SFT		(0x1 << 6)
#define RG_HPRSHORT2HPRAUX_EN_VAUDP32_SFT		7
#define RG_HPRSHORT2HPRAUX_EN_VAUDP32_MASK		0x1
#define RG_HPRSHORT2HPRAUX_EN_VAUDP32_MASK_SFT		(0x1 << 7)
#define RG_HPLOUTSTGCTRL_VAUDP32_SFT			8
#define RG_HPLOUTSTGCTRL_VAUDP32_MASK			0x7
#define RG_HPLOUTSTGCTRL_VAUDP32_MASK_SFT		(0x7 << 8)
#define RG_HPROUTSTGCTRL_VAUDP32_SFT			12
#define RG_HPROUTSTGCTRL_VAUDP32_MASK			0x7
#define RG_HPROUTSTGCTRL_VAUDP32_MASK_SFT		(0x7 << 12)

/* AUDDEC_ANA_CON2 */
#define RG_HPLOUTPUTSTBENH_VAUDP32_SFT			0
#define RG_HPLOUTPUTSTBENH_VAUDP32_MASK			0x7
#define RG_HPLOUTPUTSTBENH_VAUDP32_MASK_SFT		(0x7 << 0)
#define RG_HPROUTPUTSTBENH_VAUDP32_SFT			4
#define RG_HPROUTPUTSTBENH_VAUDP32_MASK			0x7
#define RG_HPROUTPUTSTBENH_VAUDP32_MASK_SFT		(0x7 << 4)
#define RG_AUDHPSTARTUP_VAUDP32_SFT			7
#define RG_AUDHPSTARTUP_VAUDP32_MASK			0x1
#define RG_AUDHPSTARTUP_VAUDP32_MASK_SFT		(0x1 << 7)
#define RG_AUDREFN_DERES_EN_VAUDP32_SFT			8
#define RG_AUDREFN_DERES_EN_VAUDP32_MASK		0x1
#define RG_AUDREFN_DERES_EN_VAUDP32_MASK_SFT		(0x1 << 8)
#define RG_HPINPUTSTBENH_VAUDP32_SFT			9
#define RG_HPINPUTSTBENH_VAUDP32_MASK			0x1
#define RG_HPINPUTSTBENH_VAUDP32_MASK_SFT		(0x1 << 9)
#define RG_HPINPUTRESET0_VAUDP32_SFT			10
#define RG_HPINPUTRESET0_VAUDP32_MASK			0x1
#define RG_HPINPUTRESET0_VAUDP32_MASK_SFT		(0x1 << 10)
#define RG_HPOUTPUTRESET0_VAUDP32_SFT			11
#define RG_HPOUTPUTRESET0_VAUDP32_MASK			0x1
#define RG_HPOUTPUTRESET0_VAUDP32_MASK_SFT		(0x1 << 11)
#define RG_HPPSHORT2VCM_VAUDP32_SFT			12
#define RG_HPPSHORT2VCM_VAUDP32_MASK			0x7
#define RG_HPPSHORT2VCM_VAUDP32_MASK_SFT		(0x7 << 12)
#define RG_AUDHPTRIM_EN_VAUDP32_SFT			15
#define RG_AUDHPTRIM_EN_VAUDP32_MASK			0x1
#define RG_AUDHPTRIM_EN_VAUDP32_MASK_SFT		(0x1 << 15)

/* AUDDEC_ANA_CON3 */
#define RG_AUDHPLTRIM_VAUDP32_SFT			0
#define RG_AUDHPLTRIM_VAUDP32_MASK			0x1f
#define RG_AUDHPLTRIM_VAUDP32_MASK_SFT			(0x1f << 0)
#define RG_AUDHPLFINETRIM_VAUDP32_SFT			5
#define RG_AUDHPLFINETRIM_VAUDP32_MASK			0x7
#define RG_AUDHPLFINETRIM_VAUDP32_MASK_SFT		(0x7 << 5)
#define RG_AUDHPRTRIM_VAUDP32_SFT			8
#define RG_AUDHPRTRIM_VAUDP32_MASK			0x1f
#define RG_AUDHPRTRIM_VAUDP32_MASK_SFT			(0x1f << 8)
#define RG_AUDHPRFINETRIM_VAUDP32_SFT			13
#define RG_AUDHPRFINETRIM_VAUDP32_MASK			0x7
#define RG_AUDHPRFINETRIM_VAUDP32_MASK_SFT		(0x7 << 13)

/* AUDDEC_ANA_CON4 */
#define RG_AUDHPDIFFINPBIASADJ_VAUDP32_SFT		0
#define RG_AUDHPDIFFINPBIASADJ_VAUDP32_MASK		0x7
#define RG_AUDHPDIFFINPBIASADJ_VAUDP32_MASK_SFT		(0x7 << 0)
#define RG_AUDHPLFCOMPRESSEL_VAUDP32_SFT		4
#define RG_AUDHPLFCOMPRESSEL_VAUDP32_MASK		0x7
#define RG_AUDHPLFCOMPRESSEL_VAUDP32_MASK_SFT		(0x7 << 4)
#define RG_AUDHPHFCOMPRESSEL_VAUDP32_SFT		8
#define RG_AUDHPHFCOMPRESSEL_VAUDP32_MASK		0x7
#define RG_AUDHPHFCOMPRESSEL_VAUDP32_MASK_SFT		(0x7 << 8)
#define RG_AUDHPHFCOMPBUFGAINSEL_VAUDP32_SFT		12
#define RG_AUDHPHFCOMPBUFGAINSEL_VAUDP32_MASK		0x3
#define RG_AUDHPHFCOMPBUFGAINSEL_VAUDP32_MASK_SFT	(0x3 << 12)
#define RG_AUDHPCOMP_EN_VAUDP32_SFT			15
#define RG_AUDHPCOMP_EN_VAUDP32_MASK			0x1
#define RG_AUDHPCOMP_EN_VAUDP32_MASK_SFT		(0x1 << 15)

/* AUDDEC_ANA_CON5 */
#define RG_AUDHPDECMGAINADJ_VAUDP32_SFT			0
#define RG_AUDHPDECMGAINADJ_VAUDP32_MASK		0x7
#define RG_AUDHPDECMGAINADJ_VAUDP32_MASK_SFT		(0x7 << 0)
#define RG_AUDHPDEDMGAINADJ_VAUDP32_SFT			4
#define RG_AUDHPDEDMGAINADJ_VAUDP32_MASK		0x7
#define RG_AUDHPDEDMGAINADJ_VAUDP32_MASK_SFT		(0x7 << 4)

/* AUDDEC_ANA_CON6 */
#define RG_AUDHSPWRUP_VAUDP32_SFT			0
#define RG_AUDHSPWRUP_VAUDP32_MASK			0x1
#define RG_AUDHSPWRUP_VAUDP32_MASK_SFT			(0x1 << 0)
#define RG_AUDHSPWRUP_IBIAS_VAUDP32_SFT			1
#define RG_AUDHSPWRUP_IBIAS_VAUDP32_MASK		0x1
#define RG_AUDHSPWRUP_IBIAS_VAUDP32_MASK_SFT		(0x1 << 1)
#define RG_AUDHSMUXINPUTSEL_VAUDP32_SFT			2
#define RG_AUDHSMUXINPUTSEL_VAUDP32_MASK		0x3
#define RG_AUDHSMUXINPUTSEL_VAUDP32_MASK_SFT		(0x3 << 2)
#define RG_AUDHSSCDISABLE_VAUDP32_SFT			4
#define RG_AUDHSSCDISABLE_VAUDP32_MASK			0x1
#define RG_AUDHSSCDISABLE_VAUDP32_MASK_SFT		(0x1 << 4)
#define RG_AUDHSBSCCURRENT_VAUDP32_SFT			5
#define RG_AUDHSBSCCURRENT_VAUDP32_MASK			0x1
#define RG_AUDHSBSCCURRENT_VAUDP32_MASK_SFT		(0x1 << 5)
#define RG_AUDHSSTARTUP_VAUDP32_SFT			6
#define RG_AUDHSSTARTUP_VAUDP32_MASK			0x1
#define RG_AUDHSSTARTUP_VAUDP32_MASK_SFT		(0x1 << 6)
#define RG_HSOUTPUTSTBENH_VAUDP32_SFT			7
#define RG_HSOUTPUTSTBENH_VAUDP32_MASK			0x1
#define RG_HSOUTPUTSTBENH_VAUDP32_MASK_SFT		(0x1 << 7)
#define RG_HSINPUTSTBENH_VAUDP32_SFT			8
#define RG_HSINPUTSTBENH_VAUDP32_MASK			0x1
#define RG_HSINPUTSTBENH_VAUDP32_MASK_SFT		(0x1 << 8)
#define RG_HSINPUTRESET0_VAUDP32_SFT			9
#define RG_HSINPUTRESET0_VAUDP32_MASK			0x1
#define RG_HSINPUTRESET0_VAUDP32_MASK_SFT		(0x1 << 9)
#define RG_HSOUTPUTRESET0_VAUDP32_SFT			10
#define RG_HSOUTPUTRESET0_VAUDP32_MASK			0x1
#define RG_HSOUTPUTRESET0_VAUDP32_MASK_SFT		(0x1 << 10)
#define RG_HSOUT_SHORTVCM_VAUDP32_SFT			11
#define RG_HSOUT_SHORTVCM_VAUDP32_MASK			0x1
#define RG_HSOUT_SHORTVCM_VAUDP32_MASK_SFT		(0x1 << 11)

/* AUDDEC_ANA_CON7 */
#define RG_AUDLOLPWRUP_VAUDP32_SFT			0
#define RG_AUDLOLPWRUP_VAUDP32_MASK			0x1
#define RG_AUDLOLPWRUP_VAUDP32_MASK_SFT			(0x1 << 0)
#define RG_AUDLOLPWRUP_IBIAS_VAUDP32_SFT		1
#define RG_AUDLOLPWRUP_IBIAS_VAUDP32_MASK		0x1
#define RG_AUDLOLPWRUP_IBIAS_VAUDP32_MASK_SFT		(0x1 << 1)
#define RG_AUDLOLMUXINPUTSEL_VAUDP32_SFT		2
#define RG_AUDLOLMUXINPUTSEL_VAUDP32_MASK		0x3
#define RG_AUDLOLMUXINPUTSEL_VAUDP32_MASK_SFT		(0x3 << 2)
#define RG_AUDLOLSCDISABLE_VAUDP32_SFT			4
#define RG_AUDLOLSCDISABLE_VAUDP32_MASK			0x1
#define RG_AUDLOLSCDISABLE_VAUDP32_MASK_SFT		(0x1 << 4)
#define RG_AUDLOLBSCCURRENT_VAUDP32_SFT			5
#define RG_AUDLOLBSCCURRENT_VAUDP32_MASK		0x1
#define RG_AUDLOLBSCCURRENT_VAUDP32_MASK_SFT		(0x1 << 5)
#define RG_AUDLOSTARTUP_VAUDP32_SFT			6
#define RG_AUDLOSTARTUP_VAUDP32_MASK			0x1
#define RG_AUDLOSTARTUP_VAUDP32_MASK_SFT		(0x1 << 6)
#define RG_LOINPUTSTBENH_VAUDP32_SFT			7
#define RG_LOINPUTSTBENH_VAUDP32_MASK			0x1
#define RG_LOINPUTSTBENH_VAUDP32_MASK_SFT		(0x1 << 7)
#define RG_LOOUTPUTSTBENH_VAUDP32_SFT			8
#define RG_LOOUTPUTSTBENH_VAUDP32_MASK			0x1
#define RG_LOOUTPUTSTBENH_VAUDP32_MASK_SFT		(0x1 << 8)
#define RG_LOINPUTRESET0_VAUDP32_SFT			9
#define RG_LOINPUTRESET0_VAUDP32_MASK			0x1
#define RG_LOINPUTRESET0_VAUDP32_MASK_SFT		(0x1 << 9)
#define RG_LOOUTPUTRESET0_VAUDP32_SFT			10
#define RG_LOOUTPUTRESET0_VAUDP32_MASK			0x1
#define RG_LOOUTPUTRESET0_VAUDP32_MASK_SFT		(0x1 << 10)
#define RG_LOOUT_SHORTVCM_VAUDP32_SFT			11
#define RG_LOOUT_SHORTVCM_VAUDP32_MASK			0x1
#define RG_LOOUT_SHORTVCM_VAUDP32_MASK_SFT		(0x1 << 11)
#define RG_AUDDACTPWRUP_VAUDP32_SFT			12
#define RG_AUDDACTPWRUP_VAUDP32_MASK			0x1
#define RG_AUDDACTPWRUP_VAUDP32_MASK_SFT		(0x1 << 12)
#define RG_AUD_DAC_PWT_UP_VA32_SFT			13
#define RG_AUD_DAC_PWT_UP_VA32_MASK			0x1
#define RG_AUD_DAC_PWT_UP_VA32_MASK_SFT			(0x1 << 13)

/* AUDDEC_ANA_CON8 */
#define RG_AUDTRIMBUF_INPUTMUXSEL_VAUDP32_SFT		0
#define RG_AUDTRIMBUF_INPUTMUXSEL_VAUDP32_MASK		0xf
#define RG_AUDTRIMBUF_INPUTMUXSEL_VAUDP32_MASK_SFT	(0xf << 0)
#define RG_AUDTRIMBUF_GAINSEL_VAUDP32_SFT		4
#define RG_AUDTRIMBUF_GAINSEL_VAUDP32_MASK		0x3
#define RG_AUDTRIMBUF_GAINSEL_VAUDP32_MASK_SFT		(0x3 << 4)
#define RG_AUDTRIMBUF_EN_VAUDP32_SFT			6
#define RG_AUDTRIMBUF_EN_VAUDP32_MASK			0x1
#define RG_AUDTRIMBUF_EN_VAUDP32_MASK_SFT		(0x1 << 6)
#define RG_AUDHPSPKDET_INPUTMUXSEL_VAUDP32_SFT		8
#define RG_AUDHPSPKDET_INPUTMUXSEL_VAUDP32_MASK		0x3
#define RG_AUDHPSPKDET_INPUTMUXSEL_VAUDP32_MASK_SFT	(0x3 << 8)
#define RG_AUDHPSPKDET_OUTPUTMUXSEL_VAUDP32_SFT		10
#define RG_AUDHPSPKDET_OUTPUTMUXSEL_VAUDP32_MASK	0x3
#define RG_AUDHPSPKDET_OUTPUTMUXSEL_VAUDP32_MASK_SFT	(0x3 << 10)
#define RG_AUDHPSPKDET_EN_VAUDP32_SFT			12
#define RG_AUDHPSPKDET_EN_VAUDP32_MASK			0x1
#define RG_AUDHPSPKDET_EN_VAUDP32_MASK_SFT		(0x1 << 12)

/* AUDDEC_ANA_CON9 */
#define RG_ABIDEC_RSVD0_VA32_SFT			0
#define RG_ABIDEC_RSVD0_VA32_MASK			0xff
#define RG_ABIDEC_RSVD0_VA32_MASK_SFT			(0xff << 0)
#define RG_ABIDEC_RSVD0_VAUDP32_SFT			8
#define RG_ABIDEC_RSVD0_VAUDP32_MASK			0xff
#define RG_ABIDEC_RSVD0_VAUDP32_MASK_SFT		(0xff << 8)

/* AUDDEC_ANA_CON10 */
#define RG_ABIDEC_RSVD1_VAUDP32_SFT			0
#define RG_ABIDEC_RSVD1_VAUDP32_MASK			0xff
#define RG_ABIDEC_RSVD1_VAUDP32_MASK_SFT		(0xff << 0)
#define RG_ABIDEC_RSVD2_VAUDP32_SFT			8
#define RG_ABIDEC_RSVD2_VAUDP32_MASK			0xff
#define RG_ABIDEC_RSVD2_VAUDP32_MASK_SFT		(0xff << 8)

/* AUDDEC_ANA_CON11 */
#define RG_AUDZCDMUXSEL_VAUDP32_SFT			0
#define RG_AUDZCDMUXSEL_VAUDP32_MASK			0x7
#define RG_AUDZCDMUXSEL_VAUDP32_MASK_SFT		(0x7 << 0)
#define RG_AUDZCDCLKSEL_VAUDP32_SFT			3
#define RG_AUDZCDCLKSEL_VAUDP32_MASK			0x1
#define RG_AUDZCDCLKSEL_VAUDP32_MASK_SFT		(0x1 << 3)
#define RG_AUDBIASADJ_0_VAUDP32_SFT			7
#define RG_AUDBIASADJ_0_VAUDP32_MASK			0x1ff
#define RG_AUDBIASADJ_0_VAUDP32_MASK_SFT		(0x1ff << 7)

/* AUDDEC_ANA_CON12 */
#define RG_AUDBIASADJ_1_VAUDP32_SFT			0
#define RG_AUDBIASADJ_1_VAUDP32_MASK			0xff
#define RG_AUDBIASADJ_1_VAUDP32_MASK_SFT		(0xff << 0)
#define RG_AUDIBIASPWRDN_VAUDP32_SFT			8
#define RG_AUDIBIASPWRDN_VAUDP32_MASK			0x1
#define RG_AUDIBIASPWRDN_VAUDP32_MASK_SFT		(0x1 << 8)

/* AUDDEC_ANA_CON13 */
#define RG_RSTB_DECODER_VA32_SFT			0
#define RG_RSTB_DECODER_VA32_MASK			0x1
#define RG_RSTB_DECODER_VA32_MASK_SFT			(0x1 << 0)
#define RG_SEL_DECODER_96K_VA32_SFT			1
#define RG_SEL_DECODER_96K_VA32_MASK			0x1
#define RG_SEL_DECODER_96K_VA32_MASK_SFT		(0x1 << 1)
#define RG_SEL_DELAY_VCORE_SFT				2
#define RG_SEL_DELAY_VCORE_MASK				0x1
#define RG_SEL_DELAY_VCORE_MASK_SFT			(0x1 << 2)
#define RG_AUDGLB_PWRDN_VA32_SFT			4
#define RG_AUDGLB_PWRDN_VA32_MASK			0x1
#define RG_AUDGLB_PWRDN_VA32_MASK_SFT			(0x1 << 4)
#define RG_AUDGLB_LP_VOW_EN_VA32_SFT			5
#define RG_AUDGLB_LP_VOW_EN_VA32_MASK			0x1
#define RG_AUDGLB_LP_VOW_EN_VA32_MASK_SFT		(0x1 << 5)
#define RG_AUDGLB_LP2_VOW_EN_VA32_SFT			6
#define RG_AUDGLB_LP2_VOW_EN_VA32_MASK			0x1
#define RG_AUDGLB_LP2_VOW_EN_VA32_MASK_SFT		(0x1 << 6)

/* AUDDEC_ANA_CON14 */
#define RG_LCLDO_DEC_EN_VA32_SFT			0
#define RG_LCLDO_DEC_EN_VA32_MASK			0x1
#define RG_LCLDO_DEC_EN_VA32_MASK_SFT			(0x1 << 0)
#define RG_LCLDO_DEC_PDDIS_EN_VA18_SFT			1
#define RG_LCLDO_DEC_PDDIS_EN_VA18_MASK			0x1
#define RG_LCLDO_DEC_PDDIS_EN_VA18_MASK_SFT		(0x1 << 1)
#define RG_LCLDO_DEC_REMOTE_SENSE_VA18_SFT		2
#define RG_LCLDO_DEC_REMOTE_SENSE_VA18_MASK		0x1
#define RG_LCLDO_DEC_REMOTE_SENSE_VA18_MASK_SFT		(0x1 << 2)
#define RG_NVREG_EN_VAUDP32_SFT				4
#define RG_NVREG_EN_VAUDP32_MASK			0x1
#define RG_NVREG_EN_VAUDP32_MASK_SFT			(0x1 << 4)
#define RG_NVREG_PULL0V_VAUDP32_SFT			5
#define RG_NVREG_PULL0V_VAUDP32_MASK			0x1
#define RG_NVREG_PULL0V_VAUDP32_MASK_SFT		(0x1 << 5)
#define RG_AUDPMU_RSVD_VA18_SFT				8
#define RG_AUDPMU_RSVD_VA18_MASK			0xff
#define RG_AUDPMU_RSVD_VA18_MASK_SFT			(0xff << 8)

/* MT6359_ZCD_CON0 */
#define RG_AUDZCDENABLE_SFT				0
#define RG_AUDZCDENABLE_MASK				0x1
#define RG_AUDZCDENABLE_MASK_SFT			(0x1 << 0)
#define RG_AUDZCDGAINSTEPTIME_SFT			1
#define RG_AUDZCDGAINSTEPTIME_MASK			0x7
#define RG_AUDZCDGAINSTEPTIME_MASK_SFT			(0x7 << 1)
#define RG_AUDZCDGAINSTEPSIZE_SFT			4
#define RG_AUDZCDGAINSTEPSIZE_MASK			0x3
#define RG_AUDZCDGAINSTEPSIZE_MASK_SFT			(0x3 << 4)
#define RG_AUDZCDTIMEOUTMODESEL_SFT			6
#define RG_AUDZCDTIMEOUTMODESEL_MASK			0x1
#define RG_AUDZCDTIMEOUTMODESEL_MASK_SFT		(0x1 << 6)

/* MT6359_ZCD_CON1 */
#define RG_AUDLOLGAIN_SFT				0
#define RG_AUDLOLGAIN_MASK				0x1f
#define RG_AUDLOLGAIN_MASK_SFT				(0x1f << 0)
#define RG_AUDLORGAIN_SFT				7
#define RG_AUDLORGAIN_MASK				0x1f
#define RG_AUDLORGAIN_MASK_SFT				(0x1f << 7)

/* MT6359_ZCD_CON2 */
#define RG_AUDHPLGAIN_SFT				0
#define RG_AUDHPLGAIN_MASK				0x1f
#define RG_AUDHPLGAIN_MASK_SFT				(0x1f << 0)
#define RG_AUDHPRGAIN_SFT				7
#define RG_AUDHPRGAIN_MASK				0x1f
#define RG_AUDHPRGAIN_MASK_SFT				(0x1f << 7)

/* MT6359_ZCD_CON3 */
#define RG_AUDHSGAIN_SFT				0
#define RG_AUDHSGAIN_MASK				0x1f
#define RG_AUDHSGAIN_MASK_SFT				(0x1f << 0)

/* MT6359_ZCD_CON4 */
#define RG_AUDIVLGAIN_SFT				0
#define RG_AUDIVLGAIN_MASK				0x7
#define RG_AUDIVLGAIN_MASK_SFT				(0x7 << 0)
#define RG_AUDIVRGAIN_SFT				8
#define RG_AUDIVRGAIN_MASK				0x7
#define RG_AUDIVRGAIN_MASK_SFT				(0x7 << 8)

/* MT6359_ZCD_CON5 */
#define RG_AUDINTGAIN1_SFT				0
#define RG_AUDINTGAIN1_MASK				0x3f
#define RG_AUDINTGAIN1_MASK_SFT				(0x3f << 0)
#define RG_AUDINTGAIN2_SFT				8
#define RG_AUDINTGAIN2_MASK				0x3f
#define RG_AUDINTGAIN2_MASK_SFT				(0x3f << 8)

/* audio register */
#define MT6359_GPIO_DIR0				0x88
#define MT6359_GPIO_DIR0_SET				0x8a
#define MT6359_GPIO_DIR0_CLR				0x8c
#define MT6359_GPIO_DIR1				0x8e
#define MT6359_GPIO_DIR1_SET				0x90
#define MT6359_GPIO_DIR1_CLR				0x92

#define MT6359_DCXO_CW11				0x7a6
#define MT6359_DCXO_CW12				0x7a8

#define MT6359_GPIO_MODE0				0xcc
#define MT6359_GPIO_MODE0_SET				0xce
#define MT6359_GPIO_MODE0_CLR				0xd0
#define MT6359_GPIO_MODE1				0xd2
#define MT6359_GPIO_MODE1_SET				0xd4
#define MT6359_GPIO_MODE1_CLR				0xd6
#define MT6359_GPIO_MODE2				0xd8
#define MT6359_GPIO_MODE2_SET				0xda
#define MT6359_GPIO_MODE2_CLR				0xdc
#define MT6359_GPIO_MODE3				0xde
#define MT6359_GPIO_MODE3_SET				0xe0
#define MT6359_GPIO_MODE3_CLR				0xe2
#define MT6359_GPIO_MODE4				0xe4
#define MT6359_GPIO_MODE4_SET				0xe6
#define MT6359_GPIO_MODE4_CLR				0xe8

#define MT6359_AUD_TOP_ID				0x2300
#define MT6359_AUD_TOP_REV0				0x2302
#define MT6359_AUD_TOP_DBI				0x2304
#define MT6359_AUD_TOP_DXI				0x2306
#define MT6359_AUD_TOP_CKPDN_TPM0			0x2308
#define MT6359_AUD_TOP_CKPDN_TPM1			0x230a
#define MT6359_AUD_TOP_CKPDN_CON0			0x230c
#define MT6359_AUD_TOP_CKPDN_CON0_SET			0x230e
#define MT6359_AUD_TOP_CKPDN_CON0_CLR			0x2310
#define MT6359_AUD_TOP_CKSEL_CON0			0x2312
#define MT6359_AUD_TOP_CKSEL_CON0_SET			0x2314
#define MT6359_AUD_TOP_CKSEL_CON0_CLR			0x2316
#define MT6359_AUD_TOP_CKTST_CON0			0x2318
#define MT6359_AUD_TOP_CLK_HWEN_CON0			0x231a
#define MT6359_AUD_TOP_CLK_HWEN_CON0_SET		0x231c
#define MT6359_AUD_TOP_CLK_HWEN_CON0_CLR		0x231e
#define MT6359_AUD_TOP_RST_CON0				0x2320
#define MT6359_AUD_TOP_RST_CON0_SET			0x2322
#define MT6359_AUD_TOP_RST_CON0_CLR			0x2324
#define MT6359_AUD_TOP_RST_BANK_CON0			0x2326
#define MT6359_AUD_TOP_INT_CON0				0x2328
#define MT6359_AUD_TOP_INT_CON0_SET			0x232a
#define MT6359_AUD_TOP_INT_CON0_CLR			0x232c
#define MT6359_AUD_TOP_INT_MASK_CON0			0x232e
#define MT6359_AUD_TOP_INT_MASK_CON0_SET		0x2330
#define MT6359_AUD_TOP_INT_MASK_CON0_CLR		0x2332
#define MT6359_AUD_TOP_INT_STATUS0			0x2334
#define MT6359_AUD_TOP_INT_RAW_STATUS0			0x2336
#define MT6359_AUD_TOP_INT_MISC_CON0			0x2338
#define MT6359_AUD_TOP_MON_CON0				0x233a
#define MT6359_AUDIO_DIG_DSN_ID				0x2380
#define MT6359_AUDIO_DIG_DSN_REV0			0x2382
#define MT6359_AUDIO_DIG_DSN_DBI			0x2384
#define MT6359_AUDIO_DIG_DSN_DXI			0x2386
#define MT6359_AFE_UL_DL_CON0				0x2388
#define MT6359_AFE_DL_SRC2_CON0_L			0x238a
#define MT6359_AFE_UL_SRC_CON0_H			0x238c
#define MT6359_AFE_UL_SRC_CON0_L			0x238e
#define MT6359_AFE_ADDA6_L_SRC_CON0_H			0x2390
#define MT6359_AFE_ADDA6_UL_SRC_CON0_L			0x2392
#define MT6359_AFE_TOP_CON0				0x2394
#define MT6359_AUDIO_TOP_CON0				0x2396
#define MT6359_AFE_MON_DEBUG0				0x2398
#define MT6359_AFUNC_AUD_CON0				0x239a
#define MT6359_AFUNC_AUD_CON1				0x239c
#define MT6359_AFUNC_AUD_CON2				0x239e
#define MT6359_AFUNC_AUD_CON3				0x23a0
#define MT6359_AFUNC_AUD_CON4				0x23a2
#define MT6359_AFUNC_AUD_CON5				0x23a4
#define MT6359_AFUNC_AUD_CON6				0x23a6
#define MT6359_AFUNC_AUD_CON7				0x23a8
#define MT6359_AFUNC_AUD_CON8				0x23aa
#define MT6359_AFUNC_AUD_CON9				0x23ac
#define MT6359_AFUNC_AUD_CON10				0x23ae
#define MT6359_AFUNC_AUD_CON11				0x23b0
#define MT6359_AFUNC_AUD_CON12				0x23b2
#define MT6359_AFUNC_AUD_MON0				0x23b4
#define MT6359_AFUNC_AUD_MON1				0x23b6
#define MT6359_AUDRC_TUNE_MON0				0x23b8
#define MT6359_AFE_ADDA_MTKAIF_FIFO_CFG0		0x23ba
#define MT6359_AFE_ADDA_MTKAIF_FIFO_LOG_MON1		0x23bc
#define MT6359_AFE_ADDA_MTKAIF_MON0			0x23be
#define MT6359_AFE_ADDA_MTKAIF_MON1			0x23c0
#define MT6359_AFE_ADDA_MTKAIF_MON2			0x23c2
#define MT6359_AFE_ADDA6_MTKAIF_MON3			0x23c4
#define MT6359_AFE_ADDA_MTKAIF_MON4			0x23c6
#define MT6359_AFE_ADDA_MTKAIF_MON5			0x23c8
#define MT6359_AFE_ADDA_MTKAIF_CFG0			0x23ca
#define MT6359_AFE_ADDA_MTKAIF_RX_CFG0			0x23cc
#define MT6359_AFE_ADDA_MTKAIF_RX_CFG1			0x23ce
#define MT6359_AFE_ADDA_MTKAIF_RX_CFG2			0x23d0
#define MT6359_AFE_ADDA_MTKAIF_RX_CFG3			0x23d2
#define MT6359_AFE_ADDA_MTKAIF_SYNCWORD_CFG0		0x23d4
#define MT6359_AFE_ADDA_MTKAIF_SYNCWORD_CFG1		0x23d6
#define MT6359_AFE_SGEN_CFG0				0x23d8
#define MT6359_AFE_SGEN_CFG1				0x23da
#define MT6359_AFE_ADC_ASYNC_FIFO_CFG			0x23dc
#define MT6359_AFE_ADC_ASYNC_FIFO_CFG1			0x23de
#define MT6359_AFE_DCCLK_CFG0				0x23e0
#define MT6359_AFE_DCCLK_CFG1				0x23e2
#define MT6359_AUDIO_DIG_CFG				0x23e4
#define MT6359_AUDIO_DIG_CFG1				0x23e6
#define MT6359_AFE_AUD_PAD_TOP				0x23e8
#define MT6359_AFE_AUD_PAD_TOP_MON			0x23ea
#define MT6359_AFE_AUD_PAD_TOP_MON1			0x23ec
#define MT6359_AFE_AUD_PAD_TOP_MON2			0x23ee
#define MT6359_AFE_DL_NLE_CFG				0x23f0
#define MT6359_AFE_DL_NLE_MON				0x23f2
#define MT6359_AFE_CG_EN_MON				0x23f4
#define MT6359_AFE_MIC_ARRAY_CFG			0x23f6
#define MT6359_AFE_CHOP_CFG0				0x23f8
#define MT6359_AFE_MTKAIF_MUX_CFG			0x23fa
#define MT6359_AUDIO_DIG_2ND_DSN_ID			0x2400
#define MT6359_AUDIO_DIG_2ND_DSN_REV0			0x2402
#define MT6359_AUDIO_DIG_2ND_DSN_DBI			0x2404
#define MT6359_AUDIO_DIG_2ND_DSN_DXI			0x2406
#define MT6359_AFE_PMIC_NEWIF_CFG3			0x2408
#define MT6359_AUDIO_DIG_3RD_DSN_ID			0x2480
#define MT6359_AUDIO_DIG_3RD_DSN_REV0			0x2482
#define MT6359_AUDIO_DIG_3RD_DSN_DBI			0x2484
#define MT6359_AUDIO_DIG_3RD_DSN_DXI			0x2486
#define MT6359_AFE_NCP_CFG0				0x24de
#define MT6359_AFE_NCP_CFG1				0x24e0
#define MT6359_AFE_NCP_CFG2				0x24e2
#define MT6359_AUDENC_DSN_ID				0x2500
#define MT6359_AUDENC_DSN_REV0				0x2502
#define MT6359_AUDENC_DSN_DBI				0x2504
#define MT6359_AUDENC_DSN_FPI				0x2506
#define MT6359_AUDENC_ANA_CON0				0x2508
#define MT6359_AUDENC_ANA_CON1				0x250a
#define MT6359_AUDENC_ANA_CON2				0x250c
#define MT6359_AUDENC_ANA_CON3				0x250e
#define MT6359_AUDENC_ANA_CON4				0x2510
#define MT6359_AUDENC_ANA_CON5				0x2512
#define MT6359_AUDENC_ANA_CON6				0x2514
#define MT6359_AUDENC_ANA_CON7				0x2516
#define MT6359_AUDENC_ANA_CON8				0x2518
#define MT6359_AUDENC_ANA_CON9				0x251a
#define MT6359_AUDENC_ANA_CON10				0x251c
#define MT6359_AUDENC_ANA_CON11				0x251e
#define MT6359_AUDENC_ANA_CON12				0x2520
#define MT6359_AUDENC_ANA_CON13				0x2522
#define MT6359_AUDENC_ANA_CON14				0x2524
#define MT6359_AUDENC_ANA_CON15				0x2526
#define MT6359_AUDENC_ANA_CON16				0x2528
#define MT6359_AUDENC_ANA_CON17				0x252a
#define MT6359_AUDENC_ANA_CON18				0x252c
#define MT6359_AUDENC_ANA_CON19				0x252e
#define MT6359_AUDENC_ANA_CON20				0x2530
#define MT6359_AUDENC_ANA_CON21				0x2532
#define MT6359_AUDENC_ANA_CON22				0x2534
#define MT6359_AUDENC_ANA_CON23				0x2536
#define MT6359_AUDDEC_DSN_ID				0x2580
#define MT6359_AUDDEC_DSN_REV0				0x2582
#define MT6359_AUDDEC_DSN_DBI				0x2584
#define MT6359_AUDDEC_DSN_FPI				0x2586
#define MT6359_AUDDEC_ANA_CON0				0x2588
#define MT6359_AUDDEC_ANA_CON1				0x258a
#define MT6359_AUDDEC_ANA_CON2				0x258c
#define MT6359_AUDDEC_ANA_CON3				0x258e
#define MT6359_AUDDEC_ANA_CON4				0x2590
#define MT6359_AUDDEC_ANA_CON5				0x2592
#define MT6359_AUDDEC_ANA_CON6				0x2594
#define MT6359_AUDDEC_ANA_CON7				0x2596
#define MT6359_AUDDEC_ANA_CON8				0x2598
#define MT6359_AUDDEC_ANA_CON9				0x259a
#define MT6359_AUDDEC_ANA_CON10				0x259c
#define MT6359_AUDDEC_ANA_CON11				0x259e
#define MT6359_AUDDEC_ANA_CON12				0x25a0
#define MT6359_AUDDEC_ANA_CON13				0x25a2
#define MT6359_AUDDEC_ANA_CON14				0x25a4
#define MT6359_AUDZCD_DSN_ID				0x2600
#define MT6359_AUDZCD_DSN_REV0				0x2602
#define MT6359_AUDZCD_DSN_DBI				0x2604
#define MT6359_AUDZCD_DSN_FPI				0x2606
#define MT6359_ZCD_CON0					0x2608
#define MT6359_ZCD_CON1					0x260a
#define MT6359_ZCD_CON2					0x260c
#define MT6359_ZCD_CON3					0x260e
#define MT6359_ZCD_CON4					0x2610
#define MT6359_ZCD_CON5					0x2612
#define MT6359_ACCDET_DSN_DIG_ID			0x2680
#define MT6359_ACCDET_DSN_DIG_REV0			0x2682
#define MT6359_ACCDET_DSN_DBI				0x2684
#define MT6359_ACCDET_DSN_FPI				0x2686
#define MT6359_ACCDET_CON0				0x2688
#define MT6359_ACCDET_CON1				0x268a
#define MT6359_ACCDET_CON2				0x268c
#define MT6359_ACCDET_CON3				0x268e
#define MT6359_ACCDET_CON4				0x2690
#define MT6359_ACCDET_CON5				0x2692
#define MT6359_ACCDET_CON6				0x2694
#define MT6359_ACCDET_CON7				0x2696
#define MT6359_ACCDET_CON8				0x2698
#define MT6359_ACCDET_CON9				0x269a
#define MT6359_ACCDET_CON10				0x269c
#define MT6359_ACCDET_CON11				0x269e
#define MT6359_ACCDET_CON12				0x26a0
#define MT6359_ACCDET_CON13				0x26a2
#define MT6359_ACCDET_CON14				0x26a4
#define MT6359_ACCDET_CON15				0x26a6
#define MT6359_ACCDET_CON16				0x26a8
#define MT6359_ACCDET_CON17				0x26aa
#define MT6359_ACCDET_CON18				0x26ac
#define MT6359_ACCDET_CON19				0x26ae
#define MT6359_ACCDET_CON20				0x26b0
#define MT6359_ACCDET_CON21				0x26b2
#define MT6359_ACCDET_CON22				0x26b4
#define MT6359_ACCDET_CON23				0x26b6
#define MT6359_ACCDET_CON24				0x26b8
#define MT6359_ACCDET_CON25				0x26ba
#define MT6359_ACCDET_CON26				0x26bc
#define MT6359_ACCDET_CON27				0x26be
#define MT6359_ACCDET_CON28				0x26c0
#define MT6359_ACCDET_CON29				0x26c2
#define MT6359_ACCDET_CON30				0x26c4
#define MT6359_ACCDET_CON31				0x26c6
#define MT6359_ACCDET_CON32				0x26c8
#define MT6359_ACCDET_CON33				0x26ca
#define MT6359_ACCDET_CON34				0x26cc
#define MT6359_ACCDET_CON35				0x26ce
#define MT6359_ACCDET_CON36				0x26d0
#define MT6359_ACCDET_CON37				0x26d2
#define MT6359_ACCDET_CON38				0x26d4
#define MT6359_ACCDET_CON39				0x26d6
#define MT6359_ACCDET_CON40				0x26d8
#define MT6359_MAX_REGISTER				MT6359_ZCD_CON5

/* dl bias */
#define DRBIAS_MASK 0x7
#define DRBIAS_HP_SFT (RG_AUDBIASADJ_0_VAUDP32_SFT + 0)
#define DRBIAS_HP_MASK_SFT (DRBIAS_MASK << DRBIAS_HP_SFT)
#define DRBIAS_HS_SFT (RG_AUDBIASADJ_0_VAUDP32_SFT + 3)
#define DRBIAS_HS_MASK_SFT (DRBIAS_MASK << DRBIAS_HS_SFT)
#define DRBIAS_LO_SFT (RG_AUDBIASADJ_0_VAUDP32_SFT + 6)
#define DRBIAS_LO_MASK_SFT (DRBIAS_MASK << DRBIAS_LO_SFT)
#define IBIAS_MASK 0x3
#define IBIAS_HP_SFT (RG_AUDBIASADJ_1_VAUDP32_SFT + 0)
#define IBIAS_HP_MASK_SFT (IBIAS_MASK << IBIAS_HP_SFT)
#define IBIAS_HS_SFT (RG_AUDBIASADJ_1_VAUDP32_SFT + 2)
#define IBIAS_HS_MASK_SFT (IBIAS_MASK << IBIAS_HS_SFT)
#define IBIAS_LO_SFT (RG_AUDBIASADJ_1_VAUDP32_SFT + 4)
#define IBIAS_LO_MASK_SFT (IBIAS_MASK << IBIAS_LO_SFT)
#define IBIAS_ZCD_SFT (RG_AUDBIASADJ_1_VAUDP32_SFT + 6)
#define IBIAS_ZCD_MASK_SFT (IBIAS_MASK << IBIAS_ZCD_SFT)

/* dl gain */
#define DL_GAIN_N_10DB_REG (DL_GAIN_N_10DB << 7 | DL_GAIN_N_10DB)
#define DL_GAIN_N_22DB_REG (DL_GAIN_N_22DB << 7 | DL_GAIN_N_22DB)
#define DL_GAIN_N_40DB_REG (DL_GAIN_N_40DB << 7 | DL_GAIN_N_40DB)
#define DL_GAIN_REG_MASK 0x0f9f

/* mic type mux */
#define MT_SOC_ENUM_EXT_ID(xname, xenum, xhandler_get, xhandler_put, id) \
{	.iface = SNDRV_CTL_ELEM_IFACE_MIXER, .name = xname, .device = id,\
	.info = snd_soc_info_enum_double, \
	.get = xhandler_get, .put = xhandler_put, \
	.private_value = (unsigned long)&(xenum) }

enum {
	MT6359_MTKAIF_PROTOCOL_1 = 0,
	MT6359_MTKAIF_PROTOCOL_2,
	MT6359_MTKAIF_PROTOCOL_2_CLK_P2,
};

enum {
	MT6359_AIF_1 = 0,	/* dl: hp, rcv, hp+lo */
	MT6359_AIF_2,		/* dl: lo only */
	MT6359_AIF_NUM,
};

enum {
	AUDIO_ANALOG_VOLUME_HSOUTL,
	AUDIO_ANALOG_VOLUME_HSOUTR,
	AUDIO_ANALOG_VOLUME_HPOUTL,
	AUDIO_ANALOG_VOLUME_HPOUTR,
	AUDIO_ANALOG_VOLUME_LINEOUTL,
	AUDIO_ANALOG_VOLUME_LINEOUTR,
	AUDIO_ANALOG_VOLUME_MICAMP1,
	AUDIO_ANALOG_VOLUME_MICAMP2,
	AUDIO_ANALOG_VOLUME_MICAMP3,
	AUDIO_ANALOG_VOLUME_TYPE_MAX
};

enum {
	MUX_MIC_TYPE_0,	/* ain0, micbias 0 */
	MUX_MIC_TYPE_1,	/* ain1, micbias 1 */
	MUX_MIC_TYPE_2,	/* ain2/3, micbias 2 */
	MUX_PGA_L,
	MUX_PGA_R,
	MUX_PGA_3,
	MUX_HP,
	MUX_NUM,
};

enum {
	DEVICE_HP,
	DEVICE_LO,
	DEVICE_RCV,
	DEVICE_MIC1,
	DEVICE_MIC2,
	DEVICE_NUM
};

enum {
	HP_GAIN_CTL_ZCD = 0,
	HP_GAIN_CTL_NLE,
	HP_GAIN_CTL_NUM,
};

enum {
	HP_MUX_OPEN = 0,
	HP_MUX_HPSPK,
	HP_MUX_HP,
	HP_MUX_TEST_MODE,
	HP_MUX_HP_IMPEDANCE,
	HP_MUX_MASK = 0x7,
};

enum {
	RCV_MUX_OPEN = 0,
	RCV_MUX_MUTE,
	RCV_MUX_VOICE_PLAYBACK,
	RCV_MUX_TEST_MODE,
	RCV_MUX_MASK = 0x3,
};

enum {
	LO_MUX_OPEN = 0,
	LO_MUX_L_DAC,
	LO_MUX_3RD_DAC,
	LO_MUX_TEST_MODE,
	LO_MUX_MASK = 0x3,
};

/* Supply widget subseq */
enum {
	/* common */
	SUPPLY_SEQ_CLK_BUF,
	SUPPLY_SEQ_AUD_GLB,
	SUPPLY_SEQ_HP_PULL_DOWN,
	SUPPLY_SEQ_CLKSQ,
	SUPPLY_SEQ_ADC_CLKGEN,
	SUPPLY_SEQ_TOP_CK,
	SUPPLY_SEQ_TOP_CK_LAST,
	SUPPLY_SEQ_DCC_CLK,
	SUPPLY_SEQ_MIC_BIAS,
	SUPPLY_SEQ_DMIC,
	SUPPLY_SEQ_AUD_TOP,
	SUPPLY_SEQ_AUD_TOP_LAST,
	SUPPLY_SEQ_DL_SDM_FIFO_CLK,
	SUPPLY_SEQ_DL_SDM,
	SUPPLY_SEQ_DL_NCP,
	SUPPLY_SEQ_AFE,
	/* playback */
	SUPPLY_SEQ_DL_SRC,
	SUPPLY_SEQ_DL_ESD_RESIST,
	SUPPLY_SEQ_HP_DAMPING_OFF_RESET_CMFB,
	SUPPLY_SEQ_HP_MUTE,
	SUPPLY_SEQ_DL_LDO_REMOTE_SENSE,
	SUPPLY_SEQ_DL_LDO,
	SUPPLY_SEQ_DL_NV,
	SUPPLY_SEQ_HP_ANA_TRIM,
	SUPPLY_SEQ_DL_IBIST,
	/* capture */
	SUPPLY_SEQ_UL_PGA,
	SUPPLY_SEQ_UL_ADC,
	SUPPLY_SEQ_UL_MTKAIF,
	SUPPLY_SEQ_UL_SRC_DMIC,
	SUPPLY_SEQ_UL_SRC,
};

enum {
	CH_L = 0,
	CH_R,
	NUM_CH,
};

enum {
	DRBIAS_4UA = 0,
	DRBIAS_5UA,
	DRBIAS_6UA,
	DRBIAS_7UA,
	DRBIAS_8UA,
	DRBIAS_9UA,
	DRBIAS_10UA,
	DRBIAS_11UA,
};

enum {
	IBIAS_4UA = 0,
	IBIAS_5UA,
	IBIAS_6UA,
	IBIAS_7UA,
};

enum {
	IBIAS_ZCD_3UA = 0,
	IBIAS_ZCD_4UA,
	IBIAS_ZCD_5UA,
	IBIAS_ZCD_6UA,
};

enum {
	MIC_BIAS_1P7 = 0,
	MIC_BIAS_1P8,
	MIC_BIAS_1P9,
	MIC_BIAS_2P0,
	MIC_BIAS_2P1,
	MIC_BIAS_2P5,
	MIC_BIAS_2P6,
	MIC_BIAS_2P7,
};

/* dl pga gain */
enum {
	DL_GAIN_8DB = 0,
	DL_GAIN_0DB = 8,
	DL_GAIN_N_1DB = 9,
	DL_GAIN_N_10DB = 18,
	DL_GAIN_N_22DB = 30,
	DL_GAIN_N_40DB = 0x1f,
};

/* Mic Type MUX */
enum {
	MIC_TYPE_MUX_IDLE = 0,
	MIC_TYPE_MUX_ACC,
	MIC_TYPE_MUX_DMIC,
	MIC_TYPE_MUX_DCC,
	MIC_TYPE_MUX_DCC_ECM_DIFF,
	MIC_TYPE_MUX_DCC_ECM_SINGLE,
};

/* UL SRC MUX */
enum {
	UL_SRC_MUX_AMIC = 0,
	UL_SRC_MUX_DMIC,
};

/* MISO MUX */
enum {
	MISO_MUX_UL1_CH1 = 0,
	MISO_MUX_UL1_CH2,
	MISO_MUX_UL2_CH1,
	MISO_MUX_UL2_CH2,
};

/* DMIC MUX */
enum {
	DMIC_MUX_DMIC_DATA0 = 0,
	DMIC_MUX_DMIC_DATA1_L,
	DMIC_MUX_DMIC_DATA1_L_1,
	DMIC_MUX_DMIC_DATA1_R,
};

/* ADC L MUX */
enum {
	ADC_MUX_IDLE = 0,
	ADC_MUX_AIN0,
	ADC_MUX_PREAMPLIFIER,
	ADC_MUX_IDLE1,
};

/* PGA L MUX */
enum {
	PGA_L_MUX_NONE = 0,
	PGA_L_MUX_AIN0,
	PGA_L_MUX_AIN1,
};

/* PGA R MUX */
enum {
	PGA_R_MUX_NONE = 0,
	PGA_R_MUX_AIN2,
	PGA_R_MUX_AIN3,
	PGA_R_MUX_AIN0,
};

/* PGA 3 MUX */
enum {
	PGA_3_MUX_NONE = 0,
	PGA_3_MUX_AIN3,
	PGA_3_MUX_AIN2,
};

struct mt6359_priv {
	struct device *dev;
	struct regmap *regmap;
	unsigned int dl_rate[MT6359_AIF_NUM];
	unsigned int ul_rate[MT6359_AIF_NUM];
	int ana_gain[AUDIO_ANALOG_VOLUME_TYPE_MAX];
	unsigned int mux_select[MUX_NUM];
	unsigned int dmic_one_wire_mode;
	int dev_counter[DEVICE_NUM];
	int hp_gain_ctl;
	int hp_hifi_mode;
	int mtkaif_protocol;
};

#define CODEC_MT6359_NAME "mtk-codec-mt6359"
#define IS_DCC_BASE(type) ((type) == MIC_TYPE_MUX_DCC || \
			   (type) == MIC_TYPE_MUX_DCC_ECM_DIFF || \
			   (type) == MIC_TYPE_MUX_DCC_ECM_SINGLE)

void mt6359_set_mtkaif_protocol(struct snd_soc_component *cmpnt,
				int mtkaif_protocol);
void mt6359_mtkaif_calibration_enable(struct snd_soc_component *cmpnt);
void mt6359_mtkaif_calibration_disable(struct snd_soc_component *cmpnt);
void mt6359_set_mtkaif_calibration_phase(struct snd_soc_component *cmpnt,
					 int phase_1, int phase_2, int phase_3);

#endif/* end _MT6359_H_ */