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