generic: 5.15: refresh kernel patches
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar9344_comfast_cf-e120a-v3.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /dts-v1/;
3
4 #include <dt-bindings/gpio/gpio.h>
5 #include <dt-bindings/input/input.h>
6
7 #include "ar9344.dtsi"
8
9 / {
10 compatible = "comfast,cf-e120a-v3", "qca,ar9344";
11 model = "COMFAST CF-E120A v3";
12
13 aliases {
14 serial0 = &uart;
15 led-boot = &led_rssihigh;
16 led-failsafe = &led_rssihigh;
17 led-upgrade = &led_rssihigh;
18 label-mac-device = &eth0;
19 };
20
21 leds {
22 compatible = "gpio-leds";
23
24 pinctrl-names = "default";
25 pinctrl-0 = <&led_rssimediumhigh_pin>;
26
27 wan {
28 label = "cf-e120a-v3:green:wan";
29 gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
30 };
31
32 lan {
33 label = "cf-e120a-v3:green:lan";
34 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
35 };
36
37 wlan {
38 label = "cf-e120a-v3:green:wlan";
39 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
40 linux,default-trigger = "phy0tpt";
41 };
42
43 rssilow {
44 label = "cf-e120a-v3:red:rssilow";
45 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
46 };
47
48 rssimediumlow {
49 label = "cf-e120a-v3:red:rssimediumlow";
50 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
51 };
52
53 rssimediumhigh {
54 label = "cf-e120a-v3:green:rssimediumhigh";
55 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
56 };
57
58 led_rssihigh: rssihigh {
59 label = "cf-e120a-v3:green:rssihigh";
60 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
61 };
62 };
63
64 keys {
65 compatible = "gpio-keys";
66
67 reset {
68 label = "reset";
69 linux,code = <KEY_RESTART>;
70 gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
71 debounce-interval = <60>;
72 };
73 };
74 };
75
76 &pinmux {
77 led_rssimediumhigh_pin: pinmux_rssimediumhigh_pin {
78 pinctrl-single,bits = <0x10 0x0 0xff>;
79 };
80 };
81
82 &spi {
83 status = "okay";
84
85 num-cs = <1>;
86
87 flash@0 {
88 compatible = "jedec,spi-nor";
89 reg = <0>;
90 spi-max-frequency = <25000000>;
91
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 0x010000>;
100 read-only;
101 };
102
103 art: partition@10000 {
104 label = "art";
105 reg = <0x010000 0x010000>;
106 read-only;
107 };
108
109 partition@20000 {
110 compatible = "denx,uimage";
111 label = "firmware";
112 reg = <0x020000 0x7d0000>;
113 };
114
115 partition@7f0000 {
116 label = "nvram";
117 reg = <0x7f0000 0x010000>;
118 read-only;
119 };
120 };
121 };
122 };
123
124 &uart {
125 status = "okay";
126 };
127
128 &eth0 {
129 status = "okay";
130 phy-handle = <&swphy0>;
131 mtd-mac-address = <&art 0x0>;
132
133 gmac-config {
134 device = <&gmac>;
135 switch-phy-swap = <1>;
136 };
137 };
138
139 &eth1 {
140 status = "okay";
141 mtd-mac-address = <&art 0x6>;
142 };
143
144 &wmac {
145 status = "okay";
146 mtd-cal-data = <&art 0x1000>;
147 };