ramips: move redundant console setup to mt7621 SoC DTSI
[openwrt/staging/wigyori.git] / target / linux / ramips / dts / mt7621_xiaomi_router-ac2100.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 chosen {
10 bootargs = "console=ttyS0,115200n8";
11 };
12
13 keys {
14 compatible = "gpio-keys";
15
16 reset {
17 label = "reset";
18 gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
19 linux,code = <KEY_RESTART>;
20 };
21 };
22 };
23
24 &nand {
25 status = "okay";
26
27 partitions {
28 compatible = "fixed-partitions";
29 #address-cells = <1>;
30 #size-cells = <1>;
31
32 partition@0 {
33 label = "Bootloader";
34 reg = <0x0 0x80000>;
35 read-only;
36 };
37
38 partition@80000 {
39 label = "Config";
40 reg = <0x80000 0x40000>;
41 };
42
43 partition@c0000 {
44 label = "Bdata";
45 reg = <0xc0000 0x40000>;
46 read-only;
47 };
48
49 factory: partition@100000 {
50 label = "factory";
51 reg = <0x100000 0x40000>;
52 read-only;
53 };
54
55 partition@140000 {
56 label = "crash";
57 reg = <0x140000 0x40000>;
58 };
59
60 partition@180000 {
61 label = "crash_syslog";
62 reg = <0x180000 0x40000>;
63 };
64
65 partition@1c0000 {
66 label = "reserved0";
67 reg = <0x1c0000 0x40000>;
68 read-only;
69 };
70
71 /* We keep stock xiaomi firmware (kernel0) here */
72 partition@200000 {
73 label = "kernel_stock";
74 reg = <0x200000 0x400000>;
75 };
76
77 partition@600000 {
78 label = "kernel";
79 reg = <0x600000 0x400000>;
80 };
81
82 partition@a00000 {
83 label = "ubi";
84 reg = <0xa00000 0x7580000>;
85 };
86 };
87 };
88
89 &pcie {
90 status = "okay";
91 };
92
93 &pcie0 {
94 wifi@0,0 {
95 compatible = "mediatek,mt76";
96 reg = <0x0000 0 0 0 0>;
97 mediatek,mtd-eeprom = <&factory 0x8000>;
98 ieee80211-freq-limit = <5000000 6000000>;
99 };
100 };
101
102 &pcie1 {
103 wifi@0,0 {
104 compatible = "mediatek,mt76";
105 reg = <0x0000 0 0 0 0>;
106 mediatek,mtd-eeprom = <&factory 0x0000>;
107 ieee80211-freq-limit = <2400000 2500000>;
108 };
109 };
110
111 &gmac0 {
112 mtd-mac-address = <&factory 0xe000>;
113 };
114
115 &switch0 {
116 ports {
117 port@0 {
118 status = "okay";
119 label = "wan";
120 mtd-mac-address = <&factory 0xe006>;
121 };
122
123 port@2 {
124 status = "okay";
125 label = "lan1";
126 };
127
128 port@3 {
129 status = "okay";
130 label = "lan2";
131 };
132
133 port@4 {
134 status = "okay";
135 label = "lan3";
136 };
137 };
138 };
139
140 &state_default {
141 gpio {
142 groups = "uart2", "uart3", "wdt";
143 function = "gpio";
144 };
145 };