ath79: update WA/XC devices UBNT_VERSION to 8.7.4
[openwrt/staging/wigyori.git] / target / linux / ath79 / dts / ar9341_openmesh_om2p-hs.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar9341.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/leds/common.h>
8
9 / {
10 chosen {
11 /delete-property/ bootargs;
12 };
13
14 aliases {
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 = &eth1;
20 };
21
22 keys {
23 compatible = "gpio-keys";
24
25 pinctrl-names = "default";
26 pinctrl-0 = <&jtag_disable_pins &led_lan_wan_blue_pin>;
27
28 reset {
29 label = "reset";
30 linux,code = <KEY_RESTART>;
31 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
32 };
33 };
34
35 leds {
36 compatible = "gpio-leds";
37
38 led_power_blue: power_blue {
39 function = LED_FUNCTION_POWER;
40 color = <LED_COLOR_ID_BLUE>;
41 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
42 default-state = "on";
43 };
44
45 wifi_green {
46 label = "green:wifi";
47 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
48 linux,default-trigger = "phy0tpt";
49 };
50
51 wifi_red {
52 label = "red:wifi";
53 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
54 };
55
56 wifi_yellow {
57 label = "yellow:wifi";
58 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
59 };
60
61 lan_blue {
62 function = LED_FUNCTION_LAN;
63 color = <LED_COLOR_ID_BLUE>;
64 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
65 };
66
67 wan_blue {
68 function = LED_FUNCTION_WAN;
69 color = <LED_COLOR_ID_BLUE>;
70 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
71 };
72 };
73
74 watchdog {
75 compatible = "linux,wdt-gpio";
76 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
77 hw_algo = "toggle";
78 /* hw_margin_ms is actually 300s but driver limits it to 60s */
79 hw_margin_ms = <60000>;
80 always-running;
81 };
82 };
83
84 &ref {
85 clock-frequency = <40000000>;
86 };
87
88 &pinmux {
89 led_lan_wan_blue_pin: pinmux_lan_wan_blue_pin {
90 pinctrl-single,bits = <0x10 0x0 0x0000ffff>;
91 };
92 };
93
94 &spi {
95 status = "okay";
96
97 flash@0 {
98 compatible = "jedec,spi-nor";
99 reg = <0>;
100 spi-max-frequency = <40000000>;
101
102 /* partitions are passed via bootloader */
103 partitions {
104 compatible = "fixed-partitions";
105 #address-cells = <1>;
106 #size-cells = <1>;
107
108 partition@0 {
109 label = "u-boot";
110 reg = <0x000000 0x040000>;
111 read-only;
112 };
113
114 partition@40000 {
115 label = "u-boot-env";
116 reg = <0x040000 0x040000>;
117 };
118
119 partition@80000 {
120 label = "custom";
121 reg = <0x080000 0x140000>;
122 read-only;
123 };
124
125 partition@1c0000 {
126 label = "inactive";
127 reg = <0x1c0000 0x700000>;
128 };
129
130 partition@8c0000 {
131 label = "inactive2";
132 reg = <0x8c0000 0x700000>;
133 };
134
135 art: partition@fc0000 {
136 label = "ART";
137 reg = <0xfc0000 0x040000>;
138 read-only;
139
140 nvmem-layout {
141 compatible = "fixed-layout";
142 #address-cells = <1>;
143 #size-cells = <1>;
144
145 macaddr_art_0: macaddr@0 {
146 reg = <0x0 0x6>;
147 };
148
149 macaddr_art_6: macaddr@6 {
150 reg = <0x6 0x6>;
151 };
152 };
153 };
154 };
155 };
156 };
157
158 &eth0 {
159 status = "okay";
160
161 phy-handle = <&swphy4>;
162
163 nvmem-cells = <&macaddr_art_6>;
164 nvmem-cell-names = "mac-address";
165 };
166
167 &eth1 {
168 nvmem-cells = <&macaddr_art_0>;
169 nvmem-cell-names = "mac-address";
170 };
171
172 &wmac {
173 status = "okay";
174
175 mtd-cal-data = <&art 0x1000>;
176 };