ramips: dts: mt7628an: reset FE and ESW cores together
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7628an_xiaomi_mi-router-4.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "mt7628an.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 chosen {
10 bootargs = "console=ttyS0,115200";
11 };
12
13 keys {
14 compatible = "gpio-keys";
15
16 reset {
17 label = "reset";
18 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
19 linux,code = <KEY_RESTART>;
20 };
21 };
22 };
23
24 &spi0 {
25 status = "okay";
26
27 flash0: flash@0 {
28 compatible = "jedec,spi-nor";
29 reg = <0>;
30 spi-max-frequency = <10000000>;
31
32 partitions: partitions {
33 compatible = "fixed-partitions";
34 #address-cells = <1>;
35 #size-cells = <1>;
36
37 partition@0 {
38 label = "bootloader";
39 reg = <0x0 0x20000>;
40 read-only;
41 };
42
43 partition@20000 {
44 label = "config";
45 reg = <0x20000 0x10000>;
46 read-only;
47 };
48
49 factory: partition@30000 {
50 label = "factory";
51 reg = <0x30000 0x10000>;
52 read-only;
53
54 nvmem-layout {
55 compatible = "fixed-layout";
56 #address-cells = <1>;
57 #size-cells = <1>;
58
59 eeprom_factory_0: eeprom@0 {
60 reg = <0x0 0x400>;
61 };
62
63 eeprom_factory_8000: eeprom@8000 {
64 reg = <0x8000 0x200>;
65 };
66
67 macaddr_factory_4: macaddr@4 {
68 compatible = "mac-base";
69 reg = <0x4 0x6>;
70 #nvmem-cell-cells = <1>;
71 };
72
73 macaddr_factory_28: macaddr@28 {
74 reg = <0x28 0x6>;
75 };
76
77 macaddr_factory_8004: macaddr@8004 {
78 reg = <0x8004 0x6>;
79 };
80 };
81 };
82
83 partition@40000 {
84 label = "crash";
85 reg = <0x40000 0x10000>;
86 read-only;
87 };
88
89 partition@50000 {
90 label = "cfg_bak";
91 reg = <0x50000 0x10000>;
92 read-only;
93 };
94
95 /* additional partitions in DTS */
96 };
97 };
98 };
99
100 &state_default {
101 gpio {
102 groups = "gpio", "refclk", "wdt", "wled_an";
103 function = "gpio";
104 };
105 };
106
107 &wmac {
108 status = "okay";
109
110 nvmem-cells = <&eeprom_factory_0>;
111 nvmem-cell-names = "eeprom";
112 };