ramips: dts: rt3352: reset FE and ESW cores together
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7621_d-team_pbr-m1.dts
1 #include "mt7621.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "d-team,pbr-m1", "mediatek,mt7621-soc";
8 model = "PBR-M1";
9
10 aliases {
11 led-boot = &led_sys;
12 led-failsafe = &led_sys;
13 led-running = &led_sys;
14 led-upgrade = &led_sys;
15 };
16
17 chosen {
18 bootargs = "console=ttyS0,115200";
19 };
20
21 leds {
22 compatible = "gpio-leds";
23
24 power {
25 label = "blue:power";
26 gpios = <&gpio 31 GPIO_ACTIVE_LOW>;
27 default-state = "on";
28 };
29
30 led_sys: sys {
31 label = "blue:sys";
32 gpios = <&gpio 32 GPIO_ACTIVE_LOW>;
33 };
34
35 internet {
36 label = "blue:internet";
37 gpios = <&gpio 29 GPIO_ACTIVE_LOW>;
38 };
39
40 wlan2g {
41 label = "blue:wlan2g";
42 gpios = <&gpio 33 GPIO_ACTIVE_LOW>;
43 };
44
45 wlan5g {
46 label = "blue:wlan5g";
47 gpios = <&gpio 28 GPIO_ACTIVE_LOW>;
48 };
49 };
50
51 keys {
52 compatible = "gpio-keys";
53
54 reset {
55 label = "reset";
56 gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
57 linux,code = <KEY_RESTART>;
58 };
59 };
60
61 gpio_export {
62 compatible = "gpio-export";
63 #size-cells = <0>;
64
65 power_usb2 {
66 gpio-export,name = "power_usb2";
67 gpio-export,output = <1>;
68 gpios = <&gpio 22 GPIO_ACTIVE_HIGH>;
69 };
70
71 power_usb3 {
72 gpio-export,name = "power_usb3";
73 gpio-export,output = <1>;
74 gpios = <&gpio 25 GPIO_ACTIVE_HIGH>;
75 };
76
77 power_sata {
78 gpio-export,name = "power_sata";
79 gpio-export,output = <1>;
80 gpios = <&gpio 27 GPIO_ACTIVE_HIGH>;
81 };
82 };
83
84 beeper: beeper {
85 compatible = "gpio-beeper";
86 gpios = <&gpio 26 GPIO_ACTIVE_LOW>;
87 };
88 };
89
90 &i2c {
91 status = "okay";
92
93 rtc@51 {
94 status = "okay";
95 compatible = "nxp,pcf8563";
96 reg = <0x51>;
97 };
98 };
99
100 &sdhci {
101 status = "okay";
102 };
103
104 &spi0 {
105 status = "okay";
106
107 flash@0 {
108 compatible = "jedec,spi-nor";
109 reg = <0>;
110 spi-max-frequency = <50000000>;
111 m25p,fast-read;
112 broken-flash-reset;
113
114 partitions {
115 compatible = "fixed-partitions";
116 #address-cells = <1>;
117 #size-cells = <1>;
118
119 partition@0 {
120 label = "u-boot";
121 reg = <0x0 0x30000>;
122 read-only;
123 };
124
125 partition@30000 {
126 label = "u-boot-env";
127 reg = <0x30000 0x10000>;
128 read-only;
129 };
130
131 factory: partition@40000 {
132 label = "factory";
133 reg = <0x40000 0x10000>;
134 read-only;
135
136 nvmem-layout {
137 compatible = "fixed-layout";
138 #address-cells = <1>;
139 #size-cells = <1>;
140
141 eeprom_factory_0: eeprom@0 {
142 reg = <0x0 0x400>;
143 };
144
145 eeprom_factory_8000: eeprom@8000 {
146 reg = <0x8000 0x200>;
147 };
148
149 macaddr_factory_e000: macaddr@e000 {
150 reg = <0xe000 0x6>;
151 };
152
153 macaddr_factory_e006: macaddr@e006 {
154 reg = <0xe006 0x6>;
155 };
156 };
157 };
158
159 partition@50000 {
160 compatible = "denx,uimage";
161 label = "firmware";
162 reg = <0x50000 0x1fb0000>;
163 };
164 };
165 };
166 };
167
168 &pinctrl {
169 uart3_gpio: uart3-gpio {
170 uart3 {
171 groups = "uart3";
172 function = "gpio";
173 };
174 };
175 };
176
177 &pcie {
178 status = "okay";
179 pinctrl-0 = <&pcie_pins>, <&uart3_gpio>;
180 reset-gpios = <&gpio 19 GPIO_ACTIVE_LOW>,
181 <&gpio 7 GPIO_ACTIVE_LOW>;
182 };
183
184 &pcie0 {
185 mt76@0,0 {
186 reg = <0x0000 0 0 0 0>;
187 nvmem-cells = <&eeprom_factory_8000>;
188 nvmem-cell-names = "eeprom";
189 ieee80211-freq-limit = <5000000 6000000>;
190 };
191 };
192
193 &pcie1 {
194 mt76@0,0 {
195 reg = <0x0000 0 0 0 0>;
196 nvmem-cells = <&eeprom_factory_0>;
197 nvmem-cell-names = "eeprom";
198 };
199 };
200
201 &ethernet {
202 pinctrl-0 = <&mdio_pins>, <&rgmii1_pins>;
203 };
204
205 &gmac0 {
206 nvmem-cells = <&macaddr_factory_e000>;
207 nvmem-cell-names = "mac-address";
208 };
209
210 &switch0 {
211 ports {
212 port@0 {
213 status = "okay";
214 label = "lan1";
215 };
216
217 port@1 {
218 status = "okay";
219 label = "lan2";
220 };
221
222 port@2 {
223 status = "okay";
224 label = "lan3";
225 };
226
227 port@3 {
228 status = "okay";
229 label = "lan4";
230 };
231
232 port@4 {
233 status = "okay";
234 label = "wan";
235 nvmem-cells = <&macaddr_factory_e006>;
236 nvmem-cell-names = "mac-address";
237 };
238 };
239 };
240
241 &state_default {
242 gpio {
243 groups = "wdt", "rgmii2", "jtag";
244 function = "gpio";
245 };
246 };