ramips: add support for Netgear EX6130
[oweals/openwrt.git] / target / linux / ramips / dts / mt7621_edimax_rg21s.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /dts-v1/;
3
4 #include "mt7621.dtsi"
5
6 #include <dt-bindings/gpio/gpio.h>
7 #include <dt-bindings/input/input.h>
8
9 / {
10         compatible = "edimax,rg21s", "mediatek,mt7621-soc";
11         model = "Edimax RG21S";
12
13         aliases {
14                 led-boot = &led_power;
15                 led-failsafe = &led_power;
16                 led-running = &led_power;
17                 led-upgrade = &led_power;
18         };
19
20         chosen {
21                 bootargs = "console=ttyS0,57600";
22         };
23
24         palmbus: palmbus@1E000000 {
25                 i2c@900 {
26                         status = "okay";
27                 };
28         };
29
30         keys {
31                 compatible = "gpio-keys";
32
33                 reset {
34                         label = "reset";
35                         gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
36                         linux,code = <KEY_RESTART>;
37                 };
38
39                 wps {
40                         label = "wps";
41                         gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
42                         linux,code = <KEY_RESTART>;
43                 };
44         };
45
46         leds {
47                 compatible = "gpio-leds";
48
49                 led_power: led_1 {
50                         label = "rg21s:red:led1";
51                         gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
52                 };
53
54                 led_2 {
55                         label = "rg21s:red:led2";
56                         gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
57                 };
58
59                 led_3 {
60                         label = "rg21s:red:led3";
61                         gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
62                 };
63
64                 led_4 {
65                         label = "rg21s:red:led4";
66                         gpios = <&gpio0 15 GPIO_ACTIVE_HIGH>;
67                 };
68         };
69 };
70
71 &sdhci {
72         status = "okay";
73 };
74
75 &spi0 {
76         status = "okay";
77
78         flash@0 {
79                 compatible = "jedec,spi-nor";
80                 reg = <0>;
81                 spi-max-frequency = <10000000>;
82
83                 partitions {
84                         compatible = "fixed-partitions";
85                         #address-cells = <1>;
86                         #size-cells = <1>;
87
88                         partition@0 {
89                                 label = "u-boot";
90                                 reg = <0x0 0x30000>;
91                                 read-only;
92                         };
93
94                         partition@30000 {
95                                 label = "u-boot-env";
96                                 reg = <0x30000 0x10000>;
97                                 read-only;
98                         };
99
100                         factory: partition@40000 {
101                                 label = "factory";
102                                 reg = <0x40000 0x10000>;
103                                 read-only;
104                         };
105
106                         partition@50000 {
107                                 compatible = "denx,uimage";
108                                 label = "firmware";
109                                 reg = <0x50000 0xfb0000>;
110                         };
111                 };
112         };
113 };
114
115 &pcie {
116         status = "okay";
117 };
118
119 &pcie0 {
120         wifi0: wifi@0,0 {
121                 compatible = "pci14c3,7615";
122                 reg = <0x0000 0 0 0 0>;
123                 mediatek,mtd-eeprom = <&factory 0x0000>;
124                 ieee80211-freq-limit = <2400000 2500000>;
125         };
126 };
127
128 &pcie1 {
129         wifi1: wifi@0,0 {
130                 compatible = "pci14c3,7615";
131                 reg = <0x0000 0 0 0 0>;
132                 mediatek,mtd-eeprom = <&factory 0x8000>;
133                 ieee80211-freq-limit = <5000000 6000000>;
134         };
135 };
136
137 &ethernet {
138         mediatek,portmap = "wllll";
139         port@5 {
140                 status = "disabled";
141         };
142 };
143
144 &pinctrl {
145         state_default: pinctrl0 {
146                 gpio {
147                         ralink,group = "wdt", "rgmii2", "jtag", "mdio";
148                         ralink,function = "gpio";
149                 };
150         };
151 };
152
153 &xhci {
154         status = "disabled";
155 };