b7f6400930bfe456a063d6c4a054b4cd362433bb
[openwrt/staging/hauke.git] / target / linux / ramips / dts / mt7621_iodata_wnpr2600g.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 = "iodata,wnpr2600g", "mediatek,mt7621-soc";
11 model = "I-O DATA WNPR2600G";
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 leds {
21 compatible = "gpio-leds";
22
23 led_power: power {
24 label = "wnpr2600g:green:power";
25 gpios = <&gpio 7 GPIO_ACTIVE_HIGH>;
26 default-state = "on";
27 };
28
29 notification {
30 label = "wnpr2600g:green:notification";
31 gpios = <&gpio 12 GPIO_ACTIVE_HIGH>;
32 };
33
34 wlan2g {
35 label = "wnpr2600g:green:wlan2g";
36 gpios = <&gpio 14 GPIO_ACTIVE_HIGH>;
37 linux,default-trigger = "phy0radio";
38 };
39
40 wlan5g {
41 label = "wnpr2600g:green:wlan5g";
42 gpios = <&gpio 15 GPIO_ACTIVE_HIGH>;
43 linux,default-trigger = "phy1radio";
44 };
45 };
46
47 keys {
48 compatible = "gpio-keys";
49
50 auto {
51 label = "auto";
52 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
53 linux,code = <BTN_0>;
54 linux,input-type = <EV_SW>;
55 };
56
57 reset {
58 label = "reset";
59 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
60 linux,code = <KEY_RESTART>;
61 };
62
63 wps {
64 label = "wps";
65 gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
66 linux,code = <KEY_WPS_BUTTON>;
67 };
68 };
69 };
70
71 &spi0 {
72 status = "okay";
73
74 flash@0 {
75 compatible = "jedec,spi-nor";
76 reg = <0>;
77 spi-max-frequency = <40000000>;
78
79 partitions {
80 compatible = "fixed-partitions";
81 #address-cells = <1>;
82 #size-cells = <1>;
83
84 partition@0 {
85 label = "u-boot";
86 reg = <0x000000 0x030000>;
87 read-only;
88 };
89
90 partition@30000 {
91 label = "u-boot-env";
92 reg = <0x030000 0x010000>;
93 read-only;
94 };
95
96 factory: partition@40000 {
97 label = "factory";
98 reg = <0x040000 0x010000>;
99 read-only;
100 };
101
102 partition@50000 {
103 compatible = "denx,uimage";
104 label = "firmware";
105 reg = <0x050000 0xda0000>;
106 };
107
108 partition@df0000 {
109 label = "manufacture";
110 reg = <0xdf0000 0x190000>;
111 read-only;
112 };
113
114 partition@f80000 {
115 label = "storage";
116 reg = <0xf80000 0x080000>;
117 read-only;
118 };
119 };
120 };
121 };
122
123 &gmac0 {
124 mtd-mac-address = <&factory 0x4>;
125 };
126
127 &switch0 {
128 ports {
129 port@0 {
130 status = "okay";
131 label = "wan";
132 };
133
134 port@1 {
135 status = "okay";
136 label = "lan4";
137 };
138
139 port@2 {
140 status = "okay";
141 label = "lan3";
142 };
143
144 port@3 {
145 status = "okay";
146 label = "lan2";
147 };
148
149 port@4 {
150 status = "okay";
151 label = "lan1";
152 };
153 };
154 };
155
156 &state_default {
157 gpio {
158 groups = "uart2", "uart3", "jtag", "wdt";
159 function = "gpio";
160 };
161 };
162
163 &pcie {
164 status = "okay";
165 };
166
167 &pcie0 {
168 wifi@0,0 {
169 compatible = "mediatek,mt76";
170 reg = <0x0000 0 0 0 0>;
171 mediatek,mtd-eeprom = <&factory 0x0>;
172 ieee80211-freq-limit = <2400000 2500000>;
173 };
174 };
175
176 &pcie1 {
177 wifi@0,0 {
178 compatible = "mediatek,mt76";
179 reg = <0x0000 0 0 0 0>;
180 mediatek,mtd-eeprom = <&factory 0x8000>;
181 ieee80211-freq-limit = <5000000 6000000>;
182 };
183 };
184
185 &xhci {
186 status = "disabled";
187 };