ath79: add support for ROSINSON WR818 board
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9563_rosinson_wr818.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 "qca956x.dtsi"
8
9 / {
10 model = "ROSINSON WR818";
11 compatible = "rosinson,wr818", "qca,qca9560";
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 gpio_leds: leds {
25 compatible = "gpio-leds";
26
27 system: system {
28 label = "wr818:red:system";
29 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
30 };
31
32 wifi_2g {
33 label = "wr818:red:wifi2g";
34 gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
35 linux,default-trigger = "phy0tpt";
36 };
37 };
38
39 keys {
40 compatible = "gpio-keys";
41
42 reset {
43 label = "reset";
44 linux,code = <KEY_RESTART>;
45 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
46 debounce-interval = <60>;
47 };
48 };
49 };
50
51 &uart {
52 status = "okay";
53 };
54
55 &gpio {
56 status = "okay";
57 };
58
59 &spi {
60 num-cs = <1>;
61
62 status = "okay";
63
64 flash@0 {
65 compatible = "jedec,spi-nor";
66 reg = <0>;
67 spi-max-frequency = <25000000>;
68
69 partitions {
70 compatible = "fixed-partitions";
71 #address-cells = <1>;
72 #size-cells = <1>;
73
74 partition@0 {
75 label = "u-boot";
76 reg = <0x000000 0x040000>;
77 read-only;
78 };
79
80 partition@40000 {
81 label = "u-boot-env";
82 reg = <0x040000 0x010000>;
83 read-only;
84 };
85
86 partition@50000 {
87 label = "firmware";
88 reg = <0x050000 0xf80000>;
89 };
90
91 info: partition@fd0000 {
92 label = "factory";
93 reg = <0xfd0000 0x010000>;
94 read-only;
95 };
96
97 art: partition@ff0000 {
98 label = "art";
99 reg = <0xff0000 0x010000>;
100 read-only;
101 };
102 };
103 };
104 };
105
106 &mdio0 {
107 status = "okay";
108
109 phy-mask = <0>;
110 phy0: ethernet-phy@0 {
111 reg = <0>;
112 phy-mode = "sgmii";
113
114 qca,ar8327-initvals = <
115 0x04 0x00080080 /* PORT0 PAD MODE CTRL */
116 0x7c 0x0000007e /* PORT0_STATUS */
117 >;
118 };
119 };
120
121 &eth0 {
122 status = "okay";
123
124 mtd-mac-address = <&info 0x0>;
125 phy-mode = "sgmii";
126 phy-handle = <&phy0>;
127 };
128
129 &wmac {
130 status = "okay";
131 mtd-cal-data = <&art 0x1000>;
132 };
133
134 &usb_phy0 {
135 status = "okay";
136 };
137
138 &usb0 {
139 #address-cells = <1>;
140 #size-cells = <0>;
141 status = "okay";
142
143 port@1 {
144 reg = <1>;
145 #trigger-source-cells = <0>;
146 };
147 };
148
149 &usb_phy1 {
150 status = "okay";
151 };
152
153 &usb1 {
154 #address-cells = <1>;
155 #size-cells = <0>;
156 status = "okay";
157
158 port@2 {
159 reg = <2>;
160 #trigger-source-cells = <0>;
161 };
162 };