ramips: add support for ALFA Network Quad-E4G
[oweals/openwrt.git] / target / linux / ramips / dts / rt5350_zyxel_keenetic-start.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /dts-v1/;
3
4 #include "rt5350.dtsi"
5
6 #include <dt-bindings/gpio/gpio.h>
7 #include <dt-bindings/input/input.h>
8
9 / {
10         compatible = "zyxel,keenetic-start", "ralink,rt5350-soc";
11         model = "ZyXEL Keenetic Start";
12
13         aliases {
14                 led-boot = &led_status;
15                 led-failsafe = &led_status;
16                 led-running = &led_status;
17                 led-upgrade = &led_status;
18                 label-mac-device = &ethernet;
19         };
20
21         leds {
22                 compatible = "gpio-leds";
23
24                 led_status: power {
25                         label = "zyxel:green:power";
26                         gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
27                 };
28
29                 internet {
30                         label = "zyxel:green:internet";
31                         gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
32                 };
33         };
34
35         keys {
36                 compatible = "gpio-keys-polled";
37                 poll-interval = <20>;
38
39                 reset {
40                         label = "reset";
41                         gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
42                         linux,code = <KEY_RESTART>;
43                 };
44
45                 wps {
46                         label = "wps";
47                         gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
48                         linux,code = <KEY_WPS_BUTTON>;
49                 };
50         };
51 };
52
53 &spi0 {
54         status = "okay";
55
56         flash@0 {
57                 compatible = "jedec,spi-nor";
58                 reg = <0>;
59                 spi-max-frequency = <10000000>;
60
61                 partitions {
62                         compatible = "fixed-partitions";
63                         #address-cells = <1>;
64                         #size-cells = <1>;
65
66                         partition@0 {
67                                 label = "u-boot";
68                                 reg = <0x0 0x30000>;
69                                 read-only;
70                         };
71
72                         partition@30000 {
73                                 label = "u-boot-env";
74                                 reg = <0x30000 0x10000>;
75                                 read-only;
76                         };
77
78                         factory: partition@40000 {
79                                 label = "factory";
80                                 reg = <0x40000 0x10000>;
81                                 read-only;
82                         };
83
84                         partition@50000 {
85                                 compatible = "denx,uimage";
86                                 label = "firmware";
87                                 reg = <0x50000 0x3b0000>;
88                         };
89                 };
90         };
91 };
92
93 &pinctrl {
94         state_default: pinctrl0 {
95                 gpio {
96                         ralink,group = "i2c", "jtag", "uartf";
97                         ralink,function = "gpio";
98                 };
99         };
100 };
101
102 &ethernet {
103         mtd-mac-address = <&factory 0x28>;
104 };
105
106 &esw {
107         mediatek,portmap = <0x2f>;
108         mediatek,led_polarity = <0x17>;
109 };
110
111 &wmac {
112         status = "okay";
113         ralink,led-polarity = <1>;
114         ralink,mtd-eeprom = <&factory 0>;
115 };