e506e12c315cde5977aebff1159a8966ddb79756
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9558_openmesh_mr900.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qca955x.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 chosen {
10 /delete-property/ bootargs;
11 };
12
13 aliases {
14 serial0 = &uart;
15 led-boot = &led_power_blue;
16 led-failsafe = &led_power_blue;
17 led-running = &led_power_blue;
18 led-upgrade = &led_power_blue;
19 label-mac-device = &eth0;
20 };
21
22 keys {
23 compatible = "gpio-keys";
24
25 reset {
26 label = "reset";
27 linux,code = <KEY_RESTART>;
28 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
29 };
30 };
31
32 leds {
33 compatible = "gpio-leds";
34
35 lan_blue {
36 label = "blue:lan";
37 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
38 };
39
40 wifi2g_blue {
41 label = "blue:wifi2g";
42 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
43 linux,default-trigger = "phy0tpt";
44 };
45
46 status_green {
47 label = "green:status";
48 gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
49 };
50
51 status_red {
52 label = "red:status";
53 gpios = <&gpio 21 GPIO_ACTIVE_LOW>;
54 };
55
56 led_power_blue: power_blue {
57 label = "blue:power";
58 gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
59 default-state = "on";
60 };
61
62 wifi5g_blue {
63 label = "blue:wifi5g";
64 gpios = <&gpio 23 GPIO_ACTIVE_LOW>;
65 linux,default-trigger = "phy1tpt";
66 };
67 };
68
69 watchdog {
70 compatible = "linux,wdt-gpio";
71 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
72 hw_algo = "toggle";
73 /* hw_margin_ms is actually 300s but driver limits it to 60s */
74 hw_margin_ms = <60000>;
75 always-running;
76 };
77 };
78
79 &uart {
80 status = "okay";
81 };
82
83 &spi {
84 status = "okay";
85
86 flash@0 {
87 compatible = "jedec,spi-nor";
88 reg = <0>;
89 spi-max-frequency = <40000000>;
90
91 /* partitions are passed via bootloader */
92 partitions {
93 compatible = "fixed-partitions";
94 #address-cells = <1>;
95 #size-cells = <1>;
96
97 partition@0 {
98 label = "u-boot";
99 reg = <0x000000 0x040000>;
100 read-only;
101 };
102
103 partition@40000 {
104 label = "u-boot-env";
105 reg = <0x040000 0x010000>;
106 };
107
108 partition@50000 {
109 label = "custom";
110 reg = <0x050000 0x060000>;
111 read-only;
112 };
113
114 partition@b0000 {
115 label = "inactive";
116 reg = <0x0b0000 0x7a0000>;
117 };
118
119 partition@850000 {
120 label = "inactive2";
121 reg = <0x850000 0x7a0000>;
122 };
123
124 art: partition@ff0000 {
125 label = "ART";
126 reg = <0xff0000 0x010000>;
127 read-only;
128 };
129 };
130 };
131 };
132
133 &mdio0 {
134 status = "okay";
135
136 phy-mask = <0x20>;
137
138 phy5: ethernet-phy@5 {
139 reg = <5>;
140 eee-broken-100tx;
141 eee-broken-1000t;
142 };
143 };
144
145 &eth0 {
146 status = "okay";
147
148 pll-data = <0xae000000 0xa0000101 0xa0001313>;
149
150 mtd-mac-address = <&art 0x0>;
151
152 phy-mode = "rgmii-rxid";
153 phy-handle = <&phy5>;
154
155 gmac-config {
156 device = <&gmac>;
157 rgmii-enabled = <1>;
158 rxd-delay = <3>;
159 rxdv-delay = <3>;
160 txd-delay = <0>;
161 txen-delay = <0>;
162 };
163 };
164
165 &wmac {
166 status = "okay";
167
168 mtd-cal-data = <&art 0x1000>;
169 mtd-mac-address = <&art 0x0>;
170 mtd-mac-address-increment = <1>;
171 };
172
173 &pcie0 {
174 status = "okay";
175
176 wifi@0,0 {
177 compatible = "pci168c,0033";
178 reg = <0x0000 0 0 0 0>;
179 mtd-mac-address = <&art 0x0>;
180 mtd-mac-address-increment = <16>;
181 };
182 };