1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
3 #include "qca956x.dtsi"
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
10 led-boot = &led_power_amber;
11 led-failsafe = &led_power_amber;
12 led-running = &led_power_green;
13 led-upgrade = &led_power_amber;
14 label-mac-device = ð0;
18 compatible = "gpio-keys";
22 linux,code = <KEY_WPS_BUTTON>;
23 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
28 linux,code = <KEY_RESTART>;
29 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
34 compatible = "gpio-keys-polled";
39 linux,code = <KEY_RFKILL>;
40 gpios = <&ath9k 9 GPIO_ACTIVE_LOW>;
41 debounce-interval = <60>;
46 compatible = "gpio-leds";
48 pinctrl-names = "default";
49 pinctrl-0 = <&jtag_disable_pins>;
51 led_power_green: power_green {
52 label = "green:power";
53 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
56 led_power_amber: power_amber {
57 label = "amber:power";
58 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
59 default-state = "keep";
64 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
69 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
73 label = "green:wlan2g";
74 gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
75 linux,default-trigger = "phy0tpt";
80 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
85 compatible = "gpio-leds";
88 label = "blue:wlan5g";
89 gpios = <&ath9k 7 GPIO_ACTIVE_LOW>;
90 linux,default-trigger = "phy1tpt";
95 compatible = "mtd-concat";
96 devices = <&ubiconcat0 &ubiconcat1>;
99 compatible = "fixed-partitions";
100 #address-cells = <1>;
115 compatible = "jedec,spi-nor";
117 spi-max-frequency = <25000000>;
120 compatible = "fixed-partitions";
121 #address-cells = <1>;
131 label = "u-boot-env";
132 reg = <0x40000 0x10000>;
136 label = "caldata_backup";
137 reg = <0x50000 0x10000>;
143 reg = <0x60000 0x10000>;
147 label = "traffic_meter";
148 reg = <0x70000 0x10000>;
153 reg = <0x80000 0x10000>;
158 reg = <0x90000 0x160000>;
161 caldata: partition@1f0000 {
163 reg = <0x1f0000 0x10000>;
167 compatible = "fixed-layout";
168 #address-cells = <1>;
171 macaddr_caldata_0: macaddr@0 {
175 macaddr_caldata_c: macaddr@c {
179 cal_art_1000: cal@1000 {
180 reg = <0x1000 0x440>;
183 cal_art_5000: cal@5000 {
184 reg = <0x5000 0x440>;
192 compatible = "spi-nand";
194 spi-max-frequency = <25000000>;
197 compatible = "fixed-partitions";
198 #address-cells = <1>;
203 reg = <0x0 0x400000>;
206 ubiconcat0: partition@400000 {
207 label = "ubiconcat0";
208 reg = <0x400000 0x5c00000>;
211 ubiconcat1: partition@6020000 {
212 label = "ubiconcat1";
213 reg = <0x6020000 0x1f60000>;
216 * U-boot always unconditionally marks block 768, 1020 - 1023 as
217 * bad blocks on each boot. To avoid conflicts with the nand
218 * driver, manually skip them.
227 phy0: ethernet-phy@0 {
230 qca,mib-poll-interval = <500>;
232 qca,ar8327-initvals = <
233 0x04 0x00000080 /* PORT0 PAD MODE CTRL */
234 0x10 0x81000080 /* POWER_ON_STRAP */
235 0x50 0xcc35cc35 /* LED_CTRL0 */
236 0x54 0xcb37cb37 /* LED_CTRL1 */
237 0x58 0x00000000 /* LED_CTRL2 */
238 0x5c 0x00f3cf00 /* LED_CTRL3 */
239 0x7c 0x0000007e /* PORT0_STATUS */
240 0x94 0x00000200 /* PORT6_STATUS */
248 pll-data = <0x03000101 0x00000101 0x00001919>;
250 nvmem-cells = <&macaddr_caldata_0>;
251 nvmem-cell-names = "mac-address";
254 phy-handle = <&phy0>;
260 nvmem-cells = <&macaddr_caldata_0>, <&cal_art_1000>;
261 nvmem-cell-names = "mac-address", "calibration";
268 /* chip is AR9580, override bogus PCI ID 168c:abcd */
269 compatible = "pci168c,0033";
270 reg = <0x0000 0 0 0 0>;
271 nvmem-cells = <&macaddr_caldata_c>, <&cal_art_5000>;
272 nvmem-cell-names = "mac-address", "calibration";
273 qca,gpio-mask=<0xf6ff>; /* unmask pin 9 for RFKILL button */