sound soc-core:codec_name not adapted i2c_name
[firefly-linux-kernel-4.4.55.git] / arch / arm / boot / dts / rk3188-tb.dts
1 /dts-v1/;
2
3 #include "rk3188.dtsi"
4 #include "rk3188-clocks.dtsi"
5 #include "lcd-b101ew05.dtsi"
6 #include "rk3188-mmc.dtsi"
7 #include <dt-bindings/clock/ddr.h>
8 / {
9         memory {
10                 device_type = "memory";
11                 reg = <0x60000000 0x40000000>;
12         };
13
14         chosen {
15                 bootargs = "clk_ignore_unused";
16         };
17
18         fiq-debugger {
19                 status = "okay";
20         };
21
22     wireless-wlan {
23         compatible = "wlan-platdata";
24         wifi_chip_type = "";
25         sdio_vref = <28000>;
26
27         wlan_ctrl_pmic {
28            power_ctrl_by_pmu = "false";
29            pmu_regulator = "act_ldo3";
30            pmu_enable_level = <1>; //1->HIGH, 0->LOW
31         };
32
33         wlan_ctrl_gpios {
34             gpio0 {
35                 pin-func = "wlan_poweren";
36                 gpios = <&gpio3 GPIO_D0 GPIO_ACTIVE_HIGH>;
37             };
38
39             gpio1 {
40                 pin-func = "wlan_reset";
41                 #gpios = <&gpio0 GPIO_A2 GPIO_ACTIVE_LOW>;
42             };
43
44             gpio2 {
45                 pin-func = "wlan_wake_host_irq";
46                 gpios = <&gpio3 GPIO_D2 GPIO_ACTIVE_HIGH>;
47             };
48         };
49     };
50
51         backlight {
52                 compatible = "pwm-backlight";
53                 pwms = <&pwm3 0 25000>;
54                 brightness-levels = <0 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>;
55                 default-brightness-level = <128>;
56                 enable-gpios = <&gpio0 GPIO_A2 GPIO_ACTIVE_HIGH>;
57         };
58
59         codec-hdmi-i2s {
60                 compatible = "hdmi-i2s";
61         };
62
63         codec-hdmi-spdif {
64                 compatible = "hdmi-spdif";
65         };
66
67         rockchip-rt5631 {
68                 compatible = "rockchip-rt5631";
69                 dais {
70                         dai0 {
71                                 codec-name = "rt5631.0-001a";
72                                 cpu-dai-name = "rockchip-i2s.0";
73                                 format = "i2s";
74                                 //continuous-clock;
75                                 //bitclock-inversion;
76                                 //frame-inversion;
77                                 //bitclock-master;
78                                 //frame-master;
79                         };
80                 };
81         };
82
83         rockchip-rk610 {
84                 compatible = "rockchip-rk610";
85                 dais {
86                         dai0 {
87                                 codec-name = "rk610_codec.0-0060";
88                                 cpu-dai-name = "rockchip-i2s.0";
89                                 format = "i2s";
90                                 //continuous-clock;
91                                 //bitclock-inversion;
92                                 //frame-inversion;
93                                 //bitclock-master;
94                                 //frame-master;
95                         };
96                 };
97         };
98
99         rockchip-hdmi-i2s {
100                 compatible = "rockchip-hdmi-i2s";
101                 dais {
102                         dai0 {
103                                 codec-name = "hdmi-i2s";
104                                 cpu-dai-name = "rockchip-i2s.0";
105                                 format = "i2s";
106                                 //continuous-clock;
107                                 //bitclock-inversion;
108                                 //frame-inversion;
109                                 //bitclock-master;
110                                 //frame-master;
111                         };
112                 };
113         };
114
115         rockchip-hdmi-spdif {
116                 compatible = "rockchip-hdmi-spdif";
117         };
118 };
119
120 &uart0 {
121         status = "okay";
122         dma-names = "!tx", "!rx";
123 };
124
125
126 &uart3 {
127         status = "okay";
128         dma-names = "!tx", "!rx";
129 };
130
131 &watchdog {
132                 rockchip,timeout = <50>;
133                 rockchip,debug = <1>;
134                 status = "disabled";
135 };
136
137 &i2c0 {
138         status = "okay";
139         rt5631@1a {
140                 compatible = "rt5631";
141                 reg = <0x1a>;
142         };
143
144         rk610ctl@40 {
145                 compatible = "rk610_ctl";
146                 reg = <0x40>;
147                 rk610-reset-io = <&gpio3 GPIO_B2 GPIO_ACTIVE_HIGH>;
148                 clocks = <&clk_i2s>;
149                 clock-names = "i2s_clk";
150         };
151
152         rk610codec@60 {//RK610_CODEC addr  from 0x60 to 0x80 (0x60~0x80)
153                 compatible = "rk610_codec";
154                 reg = <0x60>;
155                 spk_ctl_io = <&gpio2 GPIO_D7 GPIO_ACTIVE_HIGH>;
156                 boot_depop = <1>;
157                 pa_enable_time = <1000>;
158         };
159
160 };
161
162 &i2c1 {
163         status = "okay";
164         rtc@51 {
165                 compatible = "nxp,pcf8563";
166                 reg = <0x51>;
167         };
168         
169         act8846: act8846@5a {
170                 reg = <0x5a>;
171                 status = "okay";
172         };
173         rk808: rk808@1b {
174                 reg = <0x1b>;
175                 status = "okay";
176         };
177 };
178
179 &i2c2 {
180         status = "okay";
181         ts@55 {
182                 compatible = "goodix,gt8xx";
183                 reg = <0x55>;
184                 touch-gpio = <&gpio1 GPIO_B7 IRQ_TYPE_LEVEL_LOW>;
185                 reset-gpio = <&gpio0 GPIO_B6 GPIO_ACTIVE_LOW>;
186                 power-gpio = <&gpio0 GPIO_C5 GPIO_ACTIVE_LOW>;
187                 max-x = <1280>;
188                 max-y = <800>;
189         };
190 };
191
192 &i2c3 {
193         status = "okay";
194 };
195
196 &fb {
197         rockchip,disp-mode = <DUAL>;
198 };
199
200 &lcdc0 {
201         status = "okay";
202         power_ctr = <&disp_power_ctr>;
203         display-timings = <&disp_timings>;
204 };
205
206 &lcdc1 {
207         status = "okay";
208 };
209
210 &adc {
211         status = "okay";
212
213         key {
214                 compatible = "rockchip,key";
215                 io-channels = <&adc 1>; 
216
217                 vol-up-key {
218                         linux,code = <115>;
219                         label = "volume up";
220                         rockchip,adc_value = <1>;
221                 };
222
223                 vol-down-key {
224                         linux,code = <114>;
225                         label = "volume down";
226                         rockchip,adc_value = <170>;
227                 };
228
229                 power-key {
230                         gpios = <&gpio0 GPIO_A4 GPIO_ACTIVE_LOW>;
231                         linux,code = <116>;
232                         label = "power";
233                         gpio-key,wakeup;
234                 };
235
236                 menu-key {
237                         linux,code = <139>;
238                         label = "menu";
239                         rockchip,adc_value = <355>;
240                 };
241
242                 home-key {
243                         linux,code = <102>;
244                         label = "home";
245                         rockchip,adc_value = <746>;
246                 };
247
248                 back-key {
249                         linux,code = <158>;
250                         label = "back";
251                         rockchip,adc_value = <560>;
252                 };
253
254                 camera-key {
255                         linux,code = <212>;
256                         label = "camera";
257                         rockchip,adc_value = <450>;
258                 };       
259         };
260 };
261
262 &pwm3 {
263         status = "okay";
264 };
265
266 &clk_core_dvfs_table {
267         operating-points = <
268                 /* KHz    uV */
269                 312000 1100000
270                 504000 1100000
271                 816000 1100000
272                 1008000 1100000
273                 1200000 1200000
274                 1416000 1300000
275                 1608000 1350000
276                 >;
277 };
278
279 &clk_gpu_dvfs_table {
280         operating-points = <
281                 /* KHz    uV */
282                 200000 1200000
283                 300000 1200000
284                 400000 1200000
285                 >;
286 };
287
288 &clk_ddr_dvfs_table {
289         operating-points = <
290                 /* KHz    uV */
291                 200000 1200000
292                 300000 1200000
293                 400000 1200000
294                 >;
295
296         freq_table = <
297                 /*status                freq(KHz)*/
298                 SYS_STATUS_NORMAL       400000
299                 SYS_STATUS_SUSPEND      200000
300                 SYS_STATUS_VIDEO        300000
301                 SYS_STATUS_DUALVIEW     500000
302                 >;
303 };
304
305 /include/ "act8846.dtsi"
306 &act8846 {
307         gpios =<&gpio3 GPIO_D3 GPIO_ACTIVE_LOW>; 
308
309 regulators {
310                 
311                  dcdc1_reg: regulator@0{
312                         regulator-name= "act_dcdc1";
313                         regulator-min-microvolt = <1200000>;
314                         regulator-max-microvolt = <1200000>;
315                         regulator-always-on;
316                         regulator-boot-on;
317                 };
318
319                 dcdc2_reg: regulator@1 {
320                         regulator-name= "vdd_logic";
321                         regulator-always-on;
322                         regulator-boot-on;                      
323                 };
324
325                 dcdc3_reg: regulator@2 {
326                         regulator-name= "vdd_arm";
327                         regulator-always-on;
328                         regulator-boot-on;
329                 };
330
331                 dcdc4_reg: regulator@3 {
332                         regulator-name= "vccio";
333                         regulator-min-microvolt = <1800000>;
334                         regulator-max-microvolt = <3300000>;
335                         regulator-always-on;
336                         regulator-boot-on;
337                 };
338
339                 ldo1_reg: regulator@4 {
340                         regulator-name= "act_ldo1";
341                         regulator-min-microvolt = <1000000>;
342                         regulator-max-microvolt = <1000000>;
343                         regulator-always-on;
344                         regulator-boot-on;
345                 };
346
347                 ldo2_reg: regulator@5 {
348                         regulator-name= "act_ldo2";
349                         regulator-min-microvolt = <1200000>;
350                         regulator-max-microvolt = <1200000>;
351                         regulator-always-on;
352                         regulator-boot-on;
353                 };
354
355                 ldo3_reg: regulator@6 {
356                         regulator-name= "act_ldo3";
357                         regulator-min-microvolt = <1800000>;
358                         regulator-max-microvolt = <1800000>;
359                         regulator-always-on;
360                         regulator-boot-on;
361                 };
362
363                 ldo4_reg:regulator@7 {
364                         regulator-name= "act_ldo4";
365                         regulator-min-microvolt = <3300000>;
366                         regulator-max-microvolt = <3300000>;
367                         regulator-always-on;
368                         regulator-boot-on;
369                 };
370
371                 ldo5_reg: regulator@8 {
372                         regulator-name= "act_ldo5";
373                         regulator-min-microvolt = <3300000>;
374                         regulator-max-microvolt = <3300000>;
375                         regulator-always-on;
376                         regulator-boot-on;
377                 };
378
379                 ldo6_reg: regulator@9 {
380                         regulator-name= "act_ldo6";
381                         regulator-min-microvolt = <3300000>;
382                         regulator-max-microvolt = <3300000>;
383                         regulator-always-on;
384                         regulator-boot-on;
385                 };
386
387                 ldo7_reg: regulator@10 {
388                         regulator-name= "act_ldo7";
389                         regulator-min-microvolt = <1800000>;
390                         regulator-max-microvolt = <1800000>;
391                         regulator-always-on;
392                         regulator-boot-on;
393                 };
394
395                 ldo8_reg: regulator@11 {
396                         regulator-name= "act_ldo8";
397                         regulator-min-microvolt = <2800000>;
398                         regulator-max-microvolt = <2800000>;
399                         regulator-always-on;
400                         regulator-boot-on;
401                 };
402         };
403 };
404 /include/ "rk808.dtsi"
405 &rk808{
406         gpios =<&gpio0 GPIO_B3 GPIO_ACTIVE_HIGH>,<&gpio0 GPIO_A1 GPIO_ACTIVE_LOW>; 
407
408 regulators {
409                 
410                  rk808_dcdc1_reg: regulator@0{
411                         regulator-name= "vdd_arm";      
412                         regulator-always-on;
413                         regulator-boot-on;
414                 };
415
416                 rk808_dcdc2_reg: regulator@1 {
417                         regulator-name= "vdd_logic";
418                         regulator-always-on;
419                         regulator-boot-on;              
420                 };
421
422                 rk808_dcdc3_reg: regulator@2 {
423                         regulator-name= "rk_dcdc3";
424                         regulator-min-microvolt = <1200000>;
425                         regulator-max-microvolt = <1200000>;
426                         regulator-always-on;
427                         regulator-boot-on;
428                 };
429
430                 rk808_dcdc4_reg: regulator@3 {
431                         regulator-name= "vccio";
432                         regulator-min-microvolt = <1800000>;
433                         regulator-max-microvolt = <3300000>;
434                         regulator-always-on;
435                         regulator-boot-on;
436                 };
437
438                 rk808_ldo1_reg: regulator@4 {
439                         regulator-name= "rk_ldo1";
440                         regulator-min-microvolt = <3300000>;
441                         regulator-max-microvolt = <3300000>;
442                         regulator-always-on;
443                         regulator-boot-on;
444                 };
445
446                 rk808_ldo2_reg: regulator@5 {
447                         regulator-name= "rk_ldo2";
448                         regulator-min-microvolt = <3300000>;
449                         regulator-max-microvolt = <3300000>;
450                         regulator-always-on;
451                         regulator-boot-on;
452                 };
453
454                 rk808_ldo3_reg: regulator@6 {
455                         regulator-name= "rk_ldo3";
456                         regulator-min-microvolt = <1000000>;
457                         regulator-max-microvolt = <1000000>;
458                         regulator-always-on;
459                         regulator-boot-on;
460                 };
461
462                 rk808_ldo4_reg:regulator@7 {
463                         regulator-name= "rk_ldo4";
464                         regulator-min-microvolt = <1800000>;
465                         regulator-max-microvolt = <1800000>;
466                         regulator-always-on;
467                         regulator-boot-on;
468                 };
469
470                 rk808_ldo5_reg: regulator@8 {
471                         regulator-name= "rk_ldo5";
472                         regulator-min-microvolt = <2800000>;
473                         regulator-max-microvolt = <2800000>;
474                         regulator-always-on;
475                         regulator-boot-on;
476                 };
477
478                 rk808_ldo6_reg: regulator@9 {
479                         regulator-name= "rk_ldo6";
480                         regulator-min-microvolt = <1200000>;
481                         regulator-max-microvolt = <1200000>;
482                         regulator-always-on;
483                         regulator-boot-on;
484                 };
485
486                 rk808_ldo7_reg: regulator@10 {
487                         regulator-name= "rk_ldo7";
488                         regulator-min-microvolt = <1800000>;
489                         regulator-max-microvolt = <1800000>;
490                         regulator-always-on;
491                         regulator-boot-on;
492                 };
493
494                 rk808_ldo8_reg: regulator@11 {
495                         regulator-name= "rk_ldo8";
496                         regulator-min-microvolt = <1800000>;
497                         regulator-max-microvolt = <1800000>;
498                         regulator-always-on;
499                         regulator-boot-on;
500                 };
501         };
502 };
503
504