Merge tag 'apparmor-pr-2018-11-01' of git://git.kernel.org/pub/scm/linux/kernel/git...
[sfrench/cifs-2.6.git] / arch / arm / boot / dts / rk3066a-rayeager.dts
1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2 /*
3  * Copyright (c) 2014, 2015 FUKAUMI Naoki <naobsd@gmail.com>
4  */
5
6 /dts-v1/;
7 #include <dt-bindings/input/input.h>
8 #include "rk3066a.dtsi"
9
10 / {
11         model = "Rayeager PX2";
12         compatible = "chipspark,rayeager-px2", "rockchip,rk3066a";
13
14         memory@60000000 {
15                 device_type = "memory";
16                 reg = <0x60000000 0x40000000>;
17         };
18
19         ir: ir-receiver {
20                 compatible = "gpio-ir-receiver";
21                 gpios = <&gpio6 RK_PA1 GPIO_ACTIVE_LOW>;
22                 pinctrl-names = "default";
23                 pinctrl-0 = <&ir_int>;
24         };
25
26         keys: gpio-keys {
27                 compatible = "gpio-keys";
28
29                 power {
30                         wakeup-source;
31                         gpios = <&gpio6 RK_PA2 GPIO_ACTIVE_LOW>;
32                         label = "GPIO Power";
33                         linux,code = <KEY_POWER>;
34                         pinctrl-names = "default";
35                         pinctrl-0 = <&pwr_key>;
36                 };
37         };
38
39         vdd_log: vdd-log {
40                 compatible = "pwm-regulator";
41                 pwms = <&pwm3 0 1000>;
42                 regulator-name = "vdd_log";
43                 regulator-min-microvolt = <1200000>;
44                 regulator-max-microvolt = <1200000>;
45                 regulator-always-on;
46                 voltage-table = <1000000 100>,
47                                 <1200000 42>;
48                 status = "okay";
49         };
50
51         vsys: vsys-regulator {
52                 compatible = "regulator-fixed";
53                 regulator-name = "vsys";
54                 regulator-min-microvolt = <5000000>;
55                 regulator-max-microvolt = <5000000>;
56                 regulator-always-on;
57                 regulator-boot-on;
58         };
59
60         /* input for 5V_STDBY is VSYS or DC5V, selectable by jumper J4 */
61         vcc_stdby: 5v-stdby-regulator {
62                 compatible = "regulator-fixed";
63                 regulator-name = "5v_stdby";
64                 regulator-min-microvolt = <5000000>;
65                 regulator-max-microvolt = <5000000>;
66                 regulator-always-on;
67                 regulator-boot-on;
68         };
69
70         vcc_emmc: emmc-regulator {
71                 compatible = "regulator-fixed";
72                 regulator-name = "emmc_vccq";
73                 regulator-min-microvolt = <3000000>;
74                 regulator-max-microvolt = <3000000>;
75                 vin-supply = <&vsys>;
76         };
77
78         vcc_sata: sata-regulator {
79                 compatible = "regulator-fixed";
80                 enable-active-high;
81                 gpio = <&gpio4 RK_PC6 GPIO_ACTIVE_HIGH>;
82                 pinctrl-names = "default";
83                 pinctrl-0 = <&sata_pwr>;
84                 regulator-name = "usb_5v";
85                 regulator-min-microvolt = <5000000>;
86                 regulator-max-microvolt = <5000000>;
87                 regulator-always-on;
88                 vin-supply = <&vcc_stdby>;
89         };
90
91         vcc_sd: sdmmc-regulator {
92                 compatible = "regulator-fixed";
93                 gpio = <&gpio3 RK_PA7 GPIO_ACTIVE_LOW>;
94                 pinctrl-names = "default";
95                 pinctrl-0 = <&sdmmc_pwr>;
96                 regulator-name = "vcc_sd";
97                 regulator-min-microvolt = <3300000>;
98                 regulator-max-microvolt = <3300000>;
99                 startup-delay-us = <100000>;
100                 vin-supply = <&vcc_io>;
101         };
102
103         vcc_host: usb-host-regulator {
104                 compatible = "regulator-fixed";
105                 enable-active-high;
106                 gpio = <&gpio0 RK_PA6 GPIO_ACTIVE_HIGH>;
107                 pinctrl-names = "default";
108                 pinctrl-0 = <&host_drv>;
109                 regulator-name = "host-pwr";
110                 regulator-min-microvolt = <5000000>;
111                 regulator-max-microvolt = <5000000>;
112                 regulator-always-on;
113                 vin-supply = <&vcc_stdby>;
114         };
115
116         vcc_otg: usb-otg-regulator {
117                 compatible = "regulator-fixed";
118                 enable-active-high;
119                 gpio = <&gpio0 RK_PA5 GPIO_ACTIVE_HIGH>;
120                 pinctrl-names = "default";
121                 pinctrl-0 = <&otg_drv>;
122                 regulator-name = "vcc_otg";
123                 regulator-min-microvolt = <5000000>;
124                 regulator-max-microvolt = <5000000>;
125                 regulator-always-on;
126                 vin-supply = <&vcc_stdby>;
127         };
128 };
129
130 &cpu0 {
131         cpu0-supply = <&vdd_arm>;
132 };
133
134 &emac {
135         pinctrl-names = "default";
136         pinctrl-0 = <&emac_xfer>, <&emac_mdio>, <&rmii_rst>;
137         phy = <&phy0>;
138         phy-supply = <&vcc_rmii>;
139         status = "okay";
140
141         phy0: ethernet-phy@0 {
142                 reg = <0>;
143                 reset-gpios = <&gpio1 RK_PD6 GPIO_ACTIVE_LOW>;
144         };
145 };
146
147 &emmc {
148         bus-width = <8>;
149         cap-mmc-highspeed;
150         disable-wp;
151         non-removable;
152         pinctrl-names = "default";
153         pinctrl-0 = <&emmc_clk>, <&emmc_cmd>, <&emmc_rst>;
154         vmmc-supply = <&vcc_emmc>;
155         vqmmc-supply = <&vcc_emmc>;
156         status = "okay";
157 };
158
159 &i2c0 {
160         clock-frequency = <400000>;
161         status = "okay";
162
163         ak8963: ak8963@d {
164                 compatible = "asahi-kasei,ak8975";
165                 reg = <0x0d>;
166                 interrupt-parent = <&gpio4>;
167                 interrupts = <RK_PC1 IRQ_TYPE_EDGE_RISING>;
168                 pinctrl-names = "default";
169                 pinctrl-0 = <&comp_int>;
170         };
171
172         mma8452: mma8452@1d {
173                 compatible = "fsl,mma8452";
174                 reg = <0x1d>;
175                 interrupt-parent = <&gpio4>;
176                 interrupts = <RK_PC0 IRQ_TYPE_EDGE_RISING>;
177                 pinctrl-names = "default";
178                 pinctrl-0 = <&gsensor_int>;
179         };
180 };
181
182 &i2c1 {
183         clock-frequency = <400000>;
184         status = "okay";
185
186         tps: tps@2d {
187                 reg = <0x2d>;
188                 interrupt-parent = <&gpio6>;
189                 interrupts = <RK_PA4 IRQ_TYPE_EDGE_RISING>;
190                 pinctrl-names = "default";
191                 pinctrl-0 = <&pmic_int>, <&pwr_hold>;
192
193                 vcc1-supply = <&vsys>;
194                 vcc2-supply = <&vsys>;
195                 vcc3-supply = <&vsys>;
196                 vcc4-supply = <&vsys>;
197                 vcc5-supply = <&vcc_io>;
198                 vcc6-supply = <&vcc_io>;
199                 vcc7-supply = <&vsys>;
200                 vccio-supply = <&vsys>;
201
202                 regulators {
203                         vcc_rtc: regulator@0 {
204                                 regulator-name = "vcc_rtc";
205                                 regulator-always-on;
206                         };
207
208                         vcc_io: regulator@1 {
209                                 regulator-name = "vcc_io";
210                                 regulator-min-microvolt = <3300000>;
211                                 regulator-max-microvolt = <3300000>;
212                                 regulator-always-on;
213                         };
214
215                         vdd_arm: regulator@2 {
216                                 regulator-name = "vdd_arm";
217                                 regulator-min-microvolt = <600000>;
218                                 regulator-max-microvolt = <1500000>;
219                                 regulator-always-on;
220                                 regulator-boot-on;
221                         };
222
223                         vcc_ddr: regulator@3 {
224                                 regulator-name = "vcc_ddr";
225                                 regulator-min-microvolt = <600000>;
226                                 regulator-max-microvolt = <1500000>;
227                                 regulator-always-on;
228                                 regulator-boot-on;
229                         };
230
231                         vcc18: regulator@5 {
232                                 regulator-name = "vcc18";
233                                 regulator-min-microvolt = <1800000>;
234                                 regulator-max-microvolt = <1800000>;
235                                 regulator-always-on;
236                         };
237
238                         vdd_11: regulator@6 {
239                                 regulator-name = "vdd_11";
240                                 regulator-min-microvolt = <1100000>;
241                                 regulator-max-microvolt = <1100000>;
242                                 regulator-always-on;
243                         };
244
245                         vcc_25: regulator@7 {
246                                 regulator-name = "vcc_25";
247                                 regulator-min-microvolt = <2500000>;
248                                 regulator-max-microvolt = <2500000>;
249                                 regulator-always-on;
250                         };
251
252                         vccio_wl: regulator@8 {
253                                 regulator-name = "vccio_wl";
254                                 regulator-min-microvolt = <1800000>;
255                                 regulator-max-microvolt = <1800000>;
256                         };
257
258                         vcc25_hdmi: regulator@9 {
259                                 regulator-name = "vcc25_hdmi";
260                                 regulator-min-microvolt = <2500000>;
261                                 regulator-max-microvolt = <2500000>;
262                         };
263
264                         vcca_33: regulator@10 {
265                                 regulator-name = "vcca_33";
266                                 regulator-min-microvolt = <3300000>;
267                                 regulator-max-microvolt = <3300000>;
268                         };
269
270                         vcc_rmii: regulator@11 {
271                                 regulator-name = "vcc_rmii";
272                                 regulator-min-microvolt = <3300000>;
273                                 regulator-max-microvolt = <3300000>;
274                         };
275
276                         vcc28_cif: regulator@12 {
277                                 regulator-name = "vcc28_cif";
278                                 regulator-min-microvolt = <2800000>;
279                                 regulator-max-microvolt = <2800000>;
280                         };
281                 };
282         };
283 };
284
285 #include "tps65910.dtsi"
286
287 &i2c2 {
288         status = "okay";
289 };
290
291 &i2c3 {
292         status = "okay";
293 };
294
295 &i2c4 {
296         status = "okay";
297 };
298
299 &mmc0 {
300         bus-width = <4>;
301         disable-wp;
302         pinctrl-names = "default";
303         pinctrl-0 = <&sd0_clk>, <&sd0_cmd>, <&sd0_cd>, <&sd0_bus4>;
304         vmmc-supply = <&vcc_sd>;
305         cap-mmc-highspeed;
306         cap-sd-highspeed;
307         status = "okay";
308 };
309
310 &mmc1 {
311         bus-width = <4>;
312         disable-wp;
313         non-removable;
314         pinctrl-names = "default";
315         pinctrl-0 = <&sd1_clk>, <&sd1_cmd>, <&sd1_bus4>;
316         vmmc-supply = <&vccio_wl>;
317         status = "okay";
318 };
319
320 &pinctrl {
321         pcfg_output_high: pcfg-output-high {
322                 output-high;
323         };
324
325         ak8963 {
326                 comp_int: comp-int {
327                         rockchip,pins = <4 17 RK_FUNC_GPIO &pcfg_pull_default>;
328                 };
329         };
330
331         emac {
332                 rmii_rst: rmii-rst {
333                         rockchip,pins = <1 30 RK_FUNC_GPIO &pcfg_output_high>;
334                 };
335         };
336
337         ir {
338                 ir_int: ir-int {
339                         rockchip,pins = <6 1 RK_FUNC_GPIO &pcfg_pull_default>;
340                 };
341         };
342
343         keys {
344                 pwr_key: pwr-key {
345                         rockchip,pins = <6 2 RK_FUNC_GPIO &pcfg_pull_default>;
346                 };
347         };
348
349         mma8452 {
350                 gsensor_int: gsensor-int {
351                         rockchip,pins = <4 16 RK_FUNC_GPIO &pcfg_pull_default>;
352                 };
353         };
354
355         mmc {
356                 sdmmc_pwr: sdmmc-pwr {
357                         rockchip,pins = <3 7 RK_FUNC_GPIO &pcfg_pull_default>;
358                 };
359         };
360
361         usb_host {
362                 host_drv: host-drv {
363                         rockchip,pins = <0 6 RK_FUNC_GPIO &pcfg_pull_default>;
364                 };
365
366                 hub_rst: hub-rst {
367                         rockchip,pins = <1 31 RK_FUNC_GPIO &pcfg_output_high>;
368                 };
369
370                 sata_pwr: sata-pwr {
371                         rockchip,pins = <4 22 RK_FUNC_GPIO &pcfg_pull_default>;
372                 };
373
374                 sata_reset: sata-reset {
375                         rockchip,pins = <0 13 RK_FUNC_GPIO &pcfg_output_high>;
376                 };
377         };
378
379         usb_otg {
380                 otg_drv: otg-drv {
381                         rockchip,pins = <0 5 RK_FUNC_GPIO &pcfg_pull_default>;
382                 };
383         };
384
385         tps {
386                 pmic_int: pmic-int {
387                         rockchip,pins = <6 4 RK_FUNC_GPIO &pcfg_pull_default>;
388                 };
389
390                 pwr_hold: pwr-hold {
391                         rockchip,pins = <6 8 RK_FUNC_GPIO &pcfg_output_high>;
392                 };
393         };
394 };
395
396 &pwm1 {
397         status = "okay";
398 };
399
400 &pwm2 {
401         status = "okay";
402 };
403
404 &pwm3 {
405         status = "okay";
406 };
407
408 &saradc {
409         vref-supply = <&vcc_25>;
410         status = "okay";
411 };
412
413 &spi0 {
414         status = "okay";
415 };
416
417 &uart0 {
418         pinctrl-names = "default";
419         pinctrl-0 = <&uart0_xfer>, <&uart0_cts>, <&uart0_rts>;
420         status = "okay";
421 };
422
423 &uart2 {
424         status = "okay";
425 };
426
427 &uart3 {
428         pinctrl-names = "default";
429         pinctrl-0 = <&uart3_xfer>, <&uart3_cts>, <&uart3_rts>;
430         status = "okay";
431 };
432
433 &usb_host {
434         pinctrl-names = "default";
435         pinctrl-0 = <&hub_rst>, <&sata_reset>;
436         status = "okay";
437 };
438
439 &usbphy {
440         status = "okay";
441 };
442
443 &usb_otg {
444         status = "okay";
445 };
446
447 &wdt {
448         status = "okay";
449 };