ath79: convert ath10k pre-calibration data to NVMEM (built-in MAC)
[openwrt/staging/dangole.git] / target / linux / ath79 / dts / qca9531_asus_rp-ac51.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qca953x.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 model = "ASUS RP-AC51";
10 compatible = "asus,rp-ac51", "qca,qca9531";
11
12 aliases {
13 led-boot = &led_wps;
14 led-failsafe = &led_wps;
15 led-running = &led_wps;
16 led-upgrade = &led_wps;
17 label-mac-device = &eth0;
18 };
19
20 keys {
21 compatible = "gpio-keys";
22
23 wps {
24 linux,code = <KEY_WPS_BUTTON>;
25 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
26 debounce-interval = <60>;
27 };
28
29 reset {
30 linux,code = <KEY_RESTART>;
31 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
32 debounce-interval = <60>;
33 };
34 };
35
36 leds {
37 compatible = "gpio-leds";
38
39 led_power: power {
40 label = "blue:power";
41 gpios = <&gpio 4 GPIO_ACTIVE_HIGH>;
42 };
43
44 led_wps: wps {
45 label = "red:wps";
46 gpios = <&gpio 15 GPIO_ACTIVE_HIGH>;
47 };
48
49 lan {
50 label = "blue:lan";
51 gpios = <&gpio 1 GPIO_ACTIVE_HIGH>;
52 };
53
54 wlan2g {
55 label = "blue:wlan2g";
56 gpios = <&gpio 16 GPIO_ACTIVE_HIGH>;
57 };
58
59 wlan5g {
60 label = "blue:wlan5g";
61 gpios = <&gpio 2 GPIO_ACTIVE_HIGH>;
62 };
63 };
64 };
65
66 &pcie0 {
67 status = "okay";
68
69 wifi@0,0 {
70 compatible = "qcom,ath10k";
71 reg = <0x0000 0 0 0 0>;
72 nvmem-cells = <&precal_art_5000>;
73 nvmem-cell-names = "pre-calibration";
74 };
75 };
76
77 &spi {
78 status = "okay";
79
80 flash@0 {
81 compatible = "jedec,spi-nor";
82 reg = <0>;
83 spi-max-frequency = <50000000>;
84
85 partitions {
86 compatible = "fixed-partitions";
87 #address-cells = <1>;
88 #size-cells = <1>;
89
90 partition@0 {
91 label = "u-boot";
92 reg = <0x000000 0x40000>;
93 read-only;
94 };
95
96 partition@40000 {
97 label = "u-boot-env";
98 reg = <0x040000 0x10000>;
99 read-only;
100 };
101
102 art: partition@50000 {
103 label = "art";
104 reg = <0x050000 0x10000>;
105 read-only;
106
107 nvmem-layout {
108 compatible = "fixed-layout";
109 #address-cells = <1>;
110 #size-cells = <1>;
111
112 macaddr_art_0: macaddr@0 {
113 reg = <0x0 0x6>;
114 };
115
116 macaddr_art_1002: macaddr@1002 {
117 reg = <0x1002 0x6>;
118 };
119
120 precal_art_5000: pre-calibration@5000 {
121 reg = <0x5000 0x2f20>;
122 };
123 };
124 };
125
126 partition@60000 {
127 compatible = "denx,uimage";
128 label = "firmware";
129 reg = <0x060000 0xfa0000>;
130 };
131 };
132 };
133 };
134
135 &eth0 {
136 status = "okay";
137
138 phy-handle = <&swphy4>;
139
140 nvmem-cells = <&macaddr_art_0>;
141 nvmem-cell-names = "mac-address";
142 };
143
144 &eth1 {
145 nvmem-cells = <&macaddr_art_1002>;
146 nvmem-cell-names = "mac-address";
147 };
148
149 &wmac {
150 status = "okay";
151
152 qca,no-eeprom;
153 };