eb7219b6f9d79635ffc0fc1f1dff76203d10df6a
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar9344_ocedo_raccoon.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 model = "OCEDO Raccoon";
11 compatible = "ocedo,raccoon", "qca,ar9344";
12
13 chosen {
14 bootargs = "console=ttyS0,115200n8";
15 };
16
17 aliases {
18 led-boot = &system;
19 led-failsafe = &system;
20 led-running = &system;
21 led-upgrade = &system;
22 };
23
24 leds {
25 compatible = "gpio-leds";
26
27 power {
28 label = "raccoon:green:power";
29 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
30 default-state = "on";
31 };
32
33 wlan2g {
34 label = "raccoon:yellow:wlan24";
35 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
36 default-state = "off";
37 linux,default-trigger = "phy0tpt";
38 };
39
40 system: system {
41 label = "raccoon:blue:sys";
42 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
43 };
44 };
45
46 ath9k-leds {
47 compatible = "gpio-leds";
48
49 wlan5g {
50 label = "raccoon:red:wlan5";
51 gpios = <&ath9k 0 GPIO_ACTIVE_LOW>;
52 default-state = "off";
53 linux,default-trigger = "phy1tpt";
54 };
55 };
56
57 keys {
58 compatible = "gpio-keys-polled";
59 poll-interval = <20>;
60
61 reset {
62 linux,code = <KEY_RESTART>;
63 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
64 debounce-interval = <60>;
65 };
66 };
67 };
68
69 &ref {
70 clock-frequency = <40000000>;
71 };
72
73 &uart {
74 status = "okay";
75 };
76
77 &gpio {
78 status = "okay";
79 };
80
81 &spi {
82 num-cs = <1>;
83
84 status = "okay";
85
86 flash@0 {
87 compatible = "jedec,spi-nor";
88 reg = <0>;
89 spi-max-frequency = <25000000>;
90
91 partitions {
92 compatible = "fixed-partitions";
93 #address-cells = <1>;
94 #size-cells = <1>;
95
96 uboot: partition@0 {
97 label = "u-boot";
98 reg = <0x000000 0x040000>;
99 read-only;
100 };
101
102 partition@40000 {
103 label = "u-boot-env";
104 reg = <0x040000 0x010000>;
105 };
106
107 partition@50000 {
108 compatible = "denx,uimage";
109 label = "firmware";
110 reg = <0x050000 0x740000>;
111 };
112
113 partition@790000 {
114 label = "vendor";
115 reg = <0x790000 0x740000>;
116 read-only;
117 };
118
119 partition@ed0000 {
120 label = "data";
121 reg = <0xed0000 0x110000>;
122 read-only;
123 };
124
125 partition@fe0000 {
126 label = "id";
127 reg = <0xfe0000 0x010000>;
128 read-only;
129 };
130
131 art: partition@ff0000 {
132 label = "art";
133 reg = <0xff0000 0x010000>;
134 read-only;
135 };
136 };
137 };
138 };
139
140 &pcie {
141 status = "okay";
142
143 ath9k: wifi@0,0 {
144 compatible = "pci168c,0030";
145 reg = <0x0000 0 0 0 0>;
146 mtd-mac-address = <&art 0xc>;
147 qca,no-eeprom;
148 #gpio-cells = <2>;
149 gpio-controller;
150 };
151 };
152
153 &wmac {
154 status = "okay";
155
156 mtd-cal-data = <&art 0x1000>;
157 mtd-mac-address = <&art 0x6>;
158 };
159
160 &mdio0 {
161 status = "okay";
162
163 phy-mask = <0>;
164
165 phy0: ethernet-phy@0 {
166 reg = <0>;
167 phy-mode = "rgmii";
168 };
169 };
170
171 &eth0 {
172 status = "okay";
173
174 /* default for ar934x, except for 1000M */
175 pll-data = <0x06000000 0x00000101 0x00001616>;
176
177 mtd-mac-address = <&art 0x0>;
178
179 phy-mode = "rgmii";
180 phy-handle = <&phy0>;
181 };