Fresh pull from upstream
[librecmc/librecmc.git] / target / linux / ramips / dts / WIDORA-NEO.dts
1 /dts-v1/;
2
3 #include "mt7628an.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8         compatible = "mediatek,widora-neo", "mediatek,mt7628an-soc";
9         model = "Widora-NEO";
10
11         chosen {
12                 bootargs = "console=ttyS0,115200";
13         };
14
15         memory@0 {
16                 device_type = "memory";
17                 reg = <0x0 0x8000000>;
18         };
19
20         gpio-leds {
21                 compatible = "gpio-leds";
22
23                 wifi {
24                         label = "widora:orange:wifi";
25                         gpios = <&wgpio 0 0>;
26                         default-state = "on";
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                 wps {
37                         label = "reset";
38                         gpios = <&gpio1 6 1>;
39                         linux,code = <KEY_WPS_BUTTON>;
40                 };
41         };
42
43         wgpio: gpio-wifi {
44                 compatible = "mediatek,gpio-wifi";
45                 #address-cells = <1>;
46                 #size-cells = <0>;
47                 gpio-controller;
48                 #gpio-cells = <2>;
49         };
50 };
51
52 &pinctrl {
53         state_default: pinctrl0 {
54                 gpio {
55                         ralink,group = "gpio";
56                         ralink,function = "gpio";
57                 };
58
59                 perst {
60                         ralink,group = "perst";
61                         ralink,function = "gpio";
62                 };
63
64                 refclk {
65                         ralink,group = "refclk";
66                         ralink,function = "gpio";
67                 };
68
69                 i2s {
70                         ralink,group = "i2s";
71                         ralink,function = "gpio";
72                 };
73
74                 spis {
75                         ralink,group = "spis";
76                         ralink,function = "gpio";
77                 };
78
79                 wled_kn {
80                         ralink,group = "wled_kn";
81                         ralink,function = "gpio";
82                 };
83
84                 wled_an {
85                         ralink,group = "wled_an";
86                         ralink,function = "wled_an";
87                 };
88
89                 wdt {
90                         ralink,group = "wdt";
91                         ralink,function = "gpio";
92                 };
93         };
94 };
95
96
97 &spi0 {
98         status = "okay";
99
100         pinctrl-names = "default";
101         pinctrl-0 = <&spi_pins>, <&spi_cs1_pins>;
102
103         m25p80@0 {
104                 #address-cells = <1>;
105                 #size-cells = <1>;
106                 compatible = "jedec,spi-nor";
107                 reg = <0>;
108                 linux,modalias = "m25p80", "w25q128";
109                 spi-max-frequency = <40000000>;
110                 m25p,chunked-io = <31>;
111
112                 partition@0 {
113                         label = "u-boot";
114                         reg = <0x0 0x30000>;
115                         read-only;
116                 };
117
118                 partition@30000 {
119                         label = "u-boot-env";
120                         reg = <0x30000 0x10000>;
121                 };
122
123                 factory: partition@40000 {
124                         label = "factory";
125                         reg = <0x40000 0x10000>;
126                         read-only;
127                 };
128
129                 partition@50000 {
130                         label = "firmware";
131                         reg = <0x50000 0x0fb0000>;
132                 };
133         };
134
135         spidev@1 {
136                 #address-cells = <1>;
137                 #size-cells = <1>;
138                 compatible = "linux,spidev";
139                 reg = <1>;
140                 spi-max-frequency = <40000000>;
141         };
142 };
143
144 &i2c {
145         status = "okay";
146 };
147
148 &uart1 {
149         status = "okay";
150 };
151
152 &uart2 {
153         status = "okay";
154 };
155
156 &pwm {
157         status = "okay";
158 };
159
160 &ethernet {
161         mtd-mac-address = <&factory 0x28>;
162 };
163
164 &sdhci {
165         status = "okay";
166         mediatek,cd-low;
167 };
168
169 &wmac {
170         status = "okay";
171 };