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