ramips: update device tree source files
[openwrt/openwrt.git] / target / linux / ramips / dts / TINY-AC.dts
1 /dts-v1/;
2
3 #include "mt7620a.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "dovado,tiny-ac", "ralink,mt7620a-soc";
10 model = "Dovado Tiny AC";
11
12 chosen {
13 bootargs = "console=ttyS0,57600";
14 };
15
16 gpio-leds {
17 compatible = "gpio-leds";
18
19 usb {
20 label = "tiny-ac:green:usb";
21 gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
22 };
23
24 wifi {
25 label = "tiny-ac:orange:wifi";
26 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
27 };
28
29 };
30
31 gpio-keys-polled {
32 compatible = "gpio-keys-polled";
33 #address-cells = <1>;
34 #size-cells = <0>;
35 poll-interval = <20>;
36
37 reset {
38 label = "reset";
39 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
40 linux,code = <KEY_RESTART>;
41 };
42
43 };
44
45 gpio_export {
46 compatible = "gpio-export";
47 #size-cells = <0>;
48
49 usbpower {
50 gpio-export,name = "usbpower";
51 gpio-export,output = <1>;
52 gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
53 };
54 };
55 };
56
57 &gpio0 {
58 status = "okay";
59 };
60
61 &gpio2 {
62 status = "okay";
63 };
64
65 &gpio3 {
66 status = "okay";
67 };
68
69 &spi0 {
70 status = "okay";
71
72 m25p80@0 {
73 #address-cells = <1>;
74 #size-cells = <1>;
75 compatible = "jedec,spi-nor";
76 reg = <0>;
77 spi-max-frequency = <10000000>;
78
79 partition@0 {
80 label = "u-boot";
81 reg = <0x0 0x30000>;
82 read-only;
83 };
84
85 partition@30000 {
86 label = "u-boot-env";
87 reg = <0x30000 0x10000>;
88 read-only;
89 };
90
91 factory: partition@40000 {
92 label = "factory";
93 reg = <0x40000 0x10000>;
94 read-only;
95 };
96
97 partition@50000 {
98 label = "firmware";
99 reg = <0x50000 0x7b0000>;
100 };
101 };
102 };
103
104 &ehci {
105 status = "okay";
106 };
107
108 &ohci {
109 status = "okay";
110 };
111
112 &ethernet {
113 status = "okay";
114 pinctrl-names = "default";
115 pinctrl-0 = <&rgmii1_pins &rgmii2_pins &mdio_pins>;
116 mediatek,portmap = "llllw";
117
118 port@4 {
119 status = "okay";
120 phy-mode = "rgmii";
121 phy-handle = <&phy4>;
122 };
123
124 port@5 {
125 status = "okay";
126 phy-mode = "rgmii";
127 phy-handle = <&phy5>;
128 };
129
130 mdio-bus {
131 status = "okay";
132
133 phy4: ethernet-phy@4 {
134 reg = <4>;
135 phy-mode = "rgmii";
136 };
137
138 phy5: ethernet-phy@5 {
139 reg = <5>;
140 phy-mode = "rgmii";
141 };
142 };
143 };
144
145 &gsw {
146 mediatek,port4 = "gmac";
147 mediatek,mt7530 = <1>;
148 };
149
150 &pcie {
151 status = "okay";
152 };
153
154 &pinctrl {
155 state_default: pinctrl0 {
156 gpio {
157 ralink,group = "uartf", "nd_sd", "wled";
158 ralink,function = "gpio";
159 };
160 };
161 };