ath79: add support for ZiKing CPE46B
[openwrt/staging/dedeckeh.git] / target / linux / ath79 / dts / ar9330_ziking_cpe46b.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar9330.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 model = "ZiKing CPE46B";
10 compatible = "ziking,cpe46b", "qca,ar9330";
11
12 aliases {
13 label-mac-device = &eth0;
14 };
15
16 leds {
17 compatible = "gpio-leds";
18
19 wlan {
20 label = "green:wlan";
21 gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;
22 linux,default-trigger = "phy0tpt";
23 };
24
25 rssi1 {
26 label = "green:rssi1";
27 gpios = <&gpio 20 GPIO_ACTIVE_HIGH>;
28 };
29
30 rssi2 {
31 label = "green:rssi2";
32 gpios = <&gpio 23 GPIO_ACTIVE_HIGH>;
33 };
34 };
35
36 keys {
37 compatible = "gpio-keys";
38
39 reset {
40 label = "reset";
41 linux,code = <KEY_RESTART>;
42 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
43 };
44 };
45 };
46
47 &spi {
48 status = "okay";
49
50 flash@0 {
51 compatible = "jedec,spi-nor";
52 spi-max-frequency = <50000000>;
53 reg = <0>;
54
55 partitions {
56 compatible = "fixed-partitions";
57 #address-cells = <1>;
58 #size-cells = <1>;
59
60 partition@0 {
61 label = "u-boot";
62 reg = <0x000000 0x010000>;
63 read-only;
64 };
65
66 partition@10000 {
67 label = "u-boot-env";
68 reg = <0x010000 0x010000>;
69 };
70
71 partition@20000 {
72 compatible = "denx,uimage";
73 label = "firmware";
74 reg = <0x020000 0x7d0000>;
75 };
76
77 art: partition@7f0000 {
78 label = "art";
79 reg = <0x7f0000 0x010000>;
80 read-only;
81 };
82 };
83 };
84 };
85
86 &eth0 {
87 status = "okay";
88
89 mtd-mac-address = <&art 0x0>;
90 };
91
92 &eth1 {
93 status = "okay";
94
95 mtd-mac-address = <&art 0x0>;
96 mtd-mac-address-increment = <2>;
97 };
98
99 &wmac {
100 status = "okay";
101
102 mtd-cal-data = <&art 0x1000>;
103 };