lantiq: kernel 4.14: copy patches, config and dts files
[openwrt/openwrt.git] / target / linux / lantiq / files-4.14 / arch / mips / boot / dts / WBMR300.dts
1 /dts-v1/;
2
3 #include "vr9.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 compatible = "buffalo,wbmr-300hpd", "lantiq,xway", "lantiq,vr9";
9 model = "Buffalo WBMR-300HPD";
10
11 chosen {
12 bootargs = "console=ttyLTQ0,115200";
13 };
14
15 aliases {
16 led-boot = &power_g;
17 led-failsafe = &diag_r;
18 led-running = &power_g;
19
20 led-dsl = &dsl;
21 led-internet = &router_g;
22 led-wifi = &wifi_g;
23 };
24
25 memory@0 {
26 reg = <0x0 0x4000000>;
27 };
28
29 fpi@10000000 {
30 gpio: pinmux@E100B10 {
31 pinctrl-names = "default";
32 pinctrl-0 = <&state_default>;
33
34 state_default: pinmux {
35 mdio {
36 lantiq,groups = "mdio";
37 lantiq,function = "mdio";
38 };
39 phy-rst {
40 lantiq,pins = "io42";
41 lantiq,pull = <0>;
42 lantiq,open-drain = <0>;
43 lantiq,output = <1>;
44 };
45 pcie-rst {
46 lantiq,pins = "io38";
47 lantiq,pull = <0>;
48 lantiq,output = <1>;
49 };
50 };
51 pins_spi_default: pins_spi_default {
52 spi_in {
53 lantiq,groups = "spi_di";
54 lantiq,function = "spi";
55 };
56 spi_out {
57 lantiq,groups = "spi_do", "spi_clk",
58 "spi_cs4";
59 lantiq,function = "spi";
60 lantiq,output = <1>;
61 };
62 };
63 };
64
65 ifxhcd@E101000 {
66 status = "okay";
67 gpios = <&gpio 33 GPIO_ACTIVE_HIGH>;
68 lantiq,portmask = <0x3>;
69 };
70
71 ifxhcd@E106000 {
72 status = "okay";
73 gpios = <&gpio 33 GPIO_ACTIVE_HIGH>;
74 };
75 };
76
77 gphy-xrx200 {
78 compatible = "lantiq,phy-xrx200";
79 firmware = "lantiq/xrx200_phy22f_a22.bin";
80 phys = [ 00 01 ];
81 };
82
83 gpio_poweroff {
84 compatible = "gpio-poweroff";
85 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
86 };
87
88 gpio-keys-polled {
89 compatible = "gpio-keys-polled";
90 #address-cells = <1>;
91 #size-cells = <0>;
92 poll-interval = <100>;
93
94 power {
95 label = "power";
96 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
97 linux,code = <KEY_POWER>;
98 };
99
100 reset {
101 label = "reset";
102 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
103 linux,code = <KEY_RESTART>;
104 };
105
106 wps {
107 label = "wps";
108 gpios = <&gpio 31 GPIO_ACTIVE_LOW>;
109 linux,code = <KEY_WPS_BUTTON>;
110 };
111
112 auto {
113 label = "auto";
114 gpios = <&gpio 48 GPIO_ACTIVE_HIGH>;
115 linux,code = <BTN_0>;
116 linux,input-type = <EV_SW>;
117 };
118
119 router {
120 label = "router";
121 gpios = <&gpio 2 GPIO_ACTIVE_HIGH>;
122 linux,code = <BTN_1>;
123 linux,input-type = <EV_SW>;
124 };
125 };
126
127 gpio-leds {
128 compatible = "gpio-leds";
129
130 diag_r: diag_r {
131 label = "wbmr300:red:diag";
132 gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;
133 default_state = "off";
134 };
135
136 wifi_g: wifi_g {
137 label = "wbmr300:green:wifi";
138 gpios = <&gpio 1 GPIO_ACTIVE_HIGH>;
139 };
140
141 dsl: dsl {
142 label = "dsl";
143 gpios = <&gpio 4 GPIO_ACTIVE_HIGH>;
144 };
145
146 router_y: router_y {
147 label = "wbmr300:yellow:router";
148 gpios = <&gpio 8 GPIO_ACTIVE_HIGH>;
149 };
150
151 wifi_y: wifi_y {
152 label = "wbmr300:yellow:wifi";
153 gpios = <&gpio 9 GPIO_ACTIVE_HIGH>;
154 };
155
156 lan1: lan1 {
157 label = "wbmr300:green:lan1";
158 gpios = <&gpio 11 GPIO_ACTIVE_HIGH>;
159 };
160
161 wan: wan {
162 label = "wbmr300:green:wan";
163 gpios = <&gpio 12 GPIO_ACTIVE_HIGH>;
164 };
165
166 lan3: lan3 {
167 label = "wbmr300:green:lan3";
168 gpios = <&gpio 15 GPIO_ACTIVE_HIGH>;
169 };
170
171 lan2: lan2 {
172 label = "wbmr300:green:lan2";
173 gpios = <&gpio 33 GPIO_ACTIVE_HIGH>;
174 };
175
176 internet_g: internet_g {
177 label = "wbmr300:green:internet";
178 gpios = <&gpio 34 GPIO_ACTIVE_HIGH>;
179 };
180
181 internet_y: internet_y {
182 label = "wbmr300:yellow:internet";
183 gpios = <&gpio 35 GPIO_ACTIVE_HIGH>;
184 };
185
186 router_g: router_g {
187 label = "wbmr300:green:router";
188 gpios = <&gpio 36 GPIO_ACTIVE_HIGH>;
189 };
190
191 power_g: power_g {
192 label = "wbmr300:green:power";
193 gpios = <&gpio 49 GPIO_ACTIVE_HIGH>;
194 };
195 };
196 };
197
198 &spi {
199 pinctrl-names = "default";
200 pinctrl-0 = <&pins_spi_default>;
201
202 status = "ok";
203 m25p80@4 {
204 #address-cells = <1>;
205 #size-cells = <1>;
206 compatible = "jedec,spi-nor";
207 reg = <4 0>;
208 spi-max-frequency = <20000000>;
209
210 partition@0 {
211 reg = <0x0 0x10000>;
212 label = "u-boot";
213 read-only;
214 };
215
216 partition@10000 {
217 reg = <0x10000 0x10000>;
218 label = "gphyfirmware";
219 read-only;
220 };
221
222 partition@20000 {
223 reg = <0x20000 0x80000>;
224 label = "dsl_fw";
225 };
226
227 partition@de0000 {
228 reg = <0xa0000 0xf40000>;
229 label = "firmware";
230 };
231
232 partition@fe0000 {
233 reg = <0xfe0000 0x10000>;
234 label = "sysconfig";
235 read-only;
236 };
237
238 partition@ff0000 {
239 reg = <0xff0000 0x2000>;
240 label = "ubootconfig";
241 };
242
243 partition@ff3000 {
244 reg = <0xff3000 0x2000>;
245 label = "board_config";
246 read-only;
247 };
248 };
249 };
250
251 &eth0 {
252 lan: interface@0 {
253 compatible = "lantiq,xrx200-pdi";
254 #address-cells = <1>;
255 #size-cells = <0>;
256 reg = <0>;
257 lantiq,switch;
258
259 ethernet@1 {
260 compatible = "lantiq,xrx200-pdi-port";
261 reg = <4>;
262 phy-mode = "mii";
263 phy-handle = <&phy13>;
264 };
265 ethernet@2 {
266 compatible = "lantiq,xrx200-pdi-port";
267 reg = <5>;
268 phy-mode = "mii";
269 phy-handle = <&phy14>;
270 };
271 ethernet@3 {
272 compatible = "lantiq,xrx200-pdi-port";
273 reg = <2>;
274 phy-mode = "mii";
275 phy-handle = <&phy11>;
276 };
277 ethernet@4 {
278 compatible = "lantiq,xrx200-pdi-port";
279 reg = <3>;
280 phy-mode = "mii";
281 phy-handle = <&phy12>;
282 };
283 };
284
285 mdio@0 {
286 #address-cells = <1>;
287 #size-cells = <0>;
288 compatible = "lantiq,xrx200-mdio";
289 phy11: ethernet-phy@11 {
290 reg = <0x11>;
291 compatible = "lantiq,phy22f", "ethernet-phy-ieee802.3-c22";
292 };
293 phy12: ethernet-phy@12 {
294 reg = <0x12>;
295 compatible = "lantiq,phy22f", "ethernet-phy-ieee802.3-c22";
296 };
297 phy13: ethernet-phy@13 {
298 reg = <0x13>;
299 compatible = "lantiq,phy22f", "ethernet-phy-ieee802.3-c22";
300 };
301 phy14: ethernet-phy@14 {
302 reg = <0x14>;
303 compatible = "lantiq,phy22f", "ethernet-phy-ieee802.3-c22";
304 };
305 };
306 };