ath79: TP-Link EAP245 v3: convert radios to nvmem-cells
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9563_compex_wpj563.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qca956x.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 model = "Compex WPJ563";
10 compatible = "compex,wpj563", "qca,qca9563";
11
12 aliases {
13 label-mac-device = &eth0;
14 led-boot = &led_sig4;
15 led-failsafe = &led_sig4;
16 led-running = &led_sig4;
17 led-upgrade = &led_sig4;
18 };
19
20 beeper {
21 compatible = "gpio-beeper";
22 gpios = <&gpio 19 GPIO_ACTIVE_HIGH>;
23 };
24
25 keys {
26 compatible = "gpio-keys";
27
28 reset {
29 label = "reset";
30 linux,code = <KEY_RESTART>;
31 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
32 debounce-interval = <60>;
33 };
34 };
35
36 leds {
37 compatible = "gpio-leds";
38
39 sig1 {
40 label = "green:sig1";
41 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
42 };
43
44 sig2 {
45 label = "green:sig2";
46 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
47 };
48
49 sig3 {
50 label = "green:sig4";
51 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
52 };
53
54 led_sig4: sig4 {
55 label = "green:sig4";
56 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
57 };
58 };
59 };
60
61 &pcie {
62 status = "okay";
63 };
64
65 &spi {
66 status = "okay";
67
68 flash@0 {
69 compatible = "jedec,spi-nor";
70 reg = <0>;
71 spi-max-frequency = <25000000>;
72
73 partitions {
74 compatible = "fixed-partitions";
75 #address-cells = <1>;
76 #size-cells = <1>;
77
78 uboot: partition@0 {
79 label = "u-boot";
80 reg = <0x000000 0x030000>;
81 read-only;
82 };
83
84 partition@30000 {
85 compatible = "denx,uimage";
86 label = "firmware";
87 reg = <0x030000 0xfc0000>;
88 };
89
90 art: partition@ff0000 {
91 label = "art";
92 reg = <0xff0000 0x010000>;
93 read-only;
94 };
95 };
96 };
97 };
98
99 &mdio0 {
100 status = "okay";
101
102 phy0: ethernet-phy@0 {
103 reg = <0>;
104 phy-mode = "sgmii";
105 qca,mib-poll-interval = <500>;
106
107 qca,ar8327-initvals = <
108 0x04 0x00080080 /* PORT0 PAD MODE CTRL */
109 0x7c 0x0000007e /* PORT0_STATUS */
110 >;
111 };
112 };
113
114 &eth0 {
115 status = "okay";
116
117 pll-data = <0x03000101 0x00000101 0x00001919>;
118
119 nvmem-cells = <&macaddr_uboot_2e010>;
120 nvmem-cell-names = "mac-address";
121 phy-mode = "sgmii";
122 phy-handle = <&phy0>;
123 };
124
125 &usb_phy0 {
126 status = "okay";
127 };
128
129 &usb0 {
130 status = "okay";
131 };
132
133 &wmac {
134 status = "okay";
135
136 mtd-cal-data = <&art 0x1000>;
137 };
138
139 &uboot {
140 compatible = "nvmem-cells";
141 #address-cells = <1>;
142 #size-cells = <1>;
143
144 macaddr_uboot_2e010: macaddr@2e010 {
145 reg = <0x2e010 0x6>;
146 };
147 };