ath79: prepare for 1-port TP-Link EAP2x5 devices
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9563_tplink_eap2x5-1port.dtsi
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 aliases {
10 label-mac-device = &eth0;
11 };
12
13 keys {
14 compatible = "gpio-keys";
15
16 reset {
17 label = "Reset button";
18 linux,code = <KEY_RESTART>;
19 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
20 debounce-interval = <60>;
21 };
22 };
23 };
24
25 &pcie {
26 status = "okay";
27 };
28
29 &uart {
30 status = "okay";
31 };
32
33 &spi {
34 status = "okay";
35 num-cs = <1>;
36
37 flash@0 {
38 compatible = "jedec,spi-nor";
39 reg = <0>;
40 spi-max-frequency = <25000000>;
41
42 partitions {
43 compatible = "fixed-partitions";
44 #address-cells = <1>;
45 #size-cells = <1>;
46
47 partition@0 {
48 label = "u-boot";
49 reg = <0x000000 0x020000>;
50 read-only;
51 };
52
53 partition@20000 {
54 label = "partition-table";
55 reg = <0x020000 0x010000>;
56 read-only;
57 };
58
59 info: partition@30000 {
60 label = "info";
61 reg = <0x030000 0x010000>;
62 read-only;
63 };
64
65 partition@40000 {
66 compatible = "openwrt,elf";
67 label = "firmware";
68 reg = <0x040000 0xd80000>;
69 };
70
71 partition@dc0000 {
72 label = "config";
73 reg = <0xdc0000 0x030000>;
74 read-only;
75 };
76
77 /* df0000-f30000 undefined in vendor firmware */
78
79 partition@f30000 {
80 label = "log";
81 reg = <0xf30000 0x0c0000>;
82 read-only;
83 };
84
85 art: partition@ff0000 {
86 label = "art";
87 reg = <0xff0000 0x010000>;
88 read-only;
89 };
90 };
91 };
92 };
93
94 &pinmux {
95 mdio_pins: mdio_pins {
96 /* GPIO 10 as MDIO(0x20), GPIO 8 as MDC(0x21) */
97 pinctrl-single,bits = <0x8 0x00200021 0x00ff00ff>;
98 };
99 };
100
101 &mdio0 {
102 status = "okay";
103
104 pinctrl-names = "default";
105 pinctrl-0 = <&mdio_pins>;
106
107 phy-mask = <0x10>;
108
109 phy4: ethernet-phy@4 {
110 reg = <4>;
111 reset-gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
112 };
113 };
114
115 &eth0 {
116 status = "okay";
117
118 phy-handle = <&phy4>;
119 phy-mode = "sgmii";
120
121 mtd-mac-address = <&info 0x8>;
122
123 qca956x-serdes-fixup;
124
125 gmac-config {
126 device = <&gmac>;
127 };
128 };
129
130 &wmac {
131 status = "okay";
132
133 mtd-cal-data = <&art 0x1000>;
134 mtd-mac-address = <&info 0x8>;
135 };