ath79: convert ath10k calibration data to NVMEM (binary MAC)
[openwrt/staging/dangole.git] / target / linux / ath79 / dts / qca9558_ocedo_ursus.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qca955x.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "ocedo,ursus", "qca,qca9558";
10 model = "OCEDO Ursus";
11
12 leds {
13 compatible = "gpio-leds";
14
15 wifi2 {
16 label = "green:wlan2g";
17 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
18 linux,default-trigger = "phy1tpt";
19 };
20
21 wifi5 {
22 label = "green:wlan5g";
23 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
24 linux,default-trigger = "phy0tpt";
25 };
26 };
27 };
28
29 &pcie1 {
30 status = "okay";
31
32 wifi@0,0 {
33 compatible = "qcom,ath10k";
34 reg = <0x0000 0 0 0 0>;
35 nvmem-cells = <&cal_art_5000>, <&macaddr_art_c>;
36 nvmem-cell-names = "calibration", "mac-address";
37 };
38 };
39
40 &spi {
41 status = "okay";
42
43 flash@0 {
44 compatible = "jedec,spi-nor";
45 reg = <0>;
46 spi-max-frequency = <50000000>;
47
48 partitions {
49 compatible = "fixed-partitions";
50 #address-cells = <1>;
51 #size-cells = <1>;
52
53 uboot: partition@0 {
54 label = "u-boot";
55 reg = <0x000000 0x040000>;
56 read-only;
57 };
58
59 partition@40000 {
60 label = "u-boot-env";
61 reg = <0x040000 0x010000>;
62 };
63
64 partition@50000 {
65 /* Dual-Flash layout combined */
66 compatible = "denx,uimage";
67 label = "firmware";
68 reg = <0x050000 0xe80000>;
69 };
70
71 partition@ed0000 {
72 label = "data";
73 reg = <0xed0000 0x110000>;
74 read-only;
75 };
76
77 partition@fe0000 {
78 label = "id";
79 reg = <0xfe0000 0x010000>;
80 read-only;
81 };
82
83 art: partition@ff0000 {
84 label = "art";
85 reg = <0xff0000 0x010000>;
86 read-only;
87
88 nvmem-layout {
89 compatible = "fixed-layout";
90 #address-cells = <1>;
91 #size-cells = <1>;
92
93 macaddr_art_0: macaddr@0 {
94 reg = <0x0 0x6>;
95 };
96
97 macaddr_art_6: macaddr@6 {
98 reg = <0x6 0x6>;
99 };
100
101 macaddr_art_c: macaddr@c {
102 reg = <0xc 0x6>;
103 };
104
105 macaddr_art_12: macaddr@12 {
106 reg = <0x12 0x6>;
107 };
108
109 cal_art_5000: calibration@5000 {
110 reg = <0x5000 0x844>;
111 };
112 };
113 };
114 };
115 };
116 };
117
118 &wmac {
119 status = "okay";
120
121 mtd-cal-data = <&art 0x1000>;
122 nvmem-cells = <&macaddr_art_6>;
123 nvmem-cell-names = "mac-address";
124 };
125
126 &mdio0 {
127 status = "okay";
128
129 phy1: ethernet-phy@1 {
130 reg = <1>;
131 };
132
133 phy2: ethernet-phy@2 {
134 reg = <2>;
135 at803x-override-sgmii-link-check;
136 };
137 };
138
139 &eth0 {
140 status = "okay";
141 nvmem-cells = <&macaddr_art_0>;
142 nvmem-cell-names = "mac-address";
143
144 phy-mode = "rgmii-rxid";
145 phy-handle = <&phy1>;
146 pll-data = <0x8e000000 0x80000101 0x80001313>;
147
148 gmac_config: gmac-config {
149 device = <&gmac>;
150
151 rxdv-delay = <3>;
152 rxd-delay = <3>;
153 txen-delay = <0>;
154 txd-delay = <0>;
155 rgmii-enabled = <1>;
156 };
157 };
158
159 &eth1 {
160 status = "okay";
161 nvmem-cells = <&macaddr_art_12>;
162 nvmem-cell-names = "mac-address";
163 phy-handle = <&phy2>;
164 pll-data = <0x3000101 0x101 0x1313>;
165 qca955x-sgmii-fixup;
166 };