ramips: move compatible for Ubiquiti Edgerouter X to DTS file
[openwrt/staging/wigyori.git] / target / linux / ramips / dts / mt7620a_zbtlink_zbt-ape522ii.dts
1 /dts-v1/;
2
3 #include "mt7620a.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "zbtlink,zbt-ape522ii", "ralink,mt7620a-soc";
10 model = "Zbtlink ZBT-APE522II";
11
12 chosen {
13 bootargs = "console=ttyS0,115200";
14 };
15
16 leds {
17 compatible = "gpio-leds";
18
19 sys1 {
20 label = "zbt-ape522ii:green:sys1";
21 gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
22 };
23
24 sys2 {
25 label = "zbt-ape522ii:green:sys2";
26 gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
27 };
28
29 sys3 {
30 label = "zbt-ape522ii:green:sys3";
31 gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
32 };
33
34 sys4 {
35 label = "zbt-ape522ii:green:sys4";
36 gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
37 };
38
39 wlan2g4 {
40 label = "zbt-ape522ii:green:wlan2g4";
41 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
42 };
43 };
44
45 keys {
46 compatible = "gpio-keys";
47
48 reset {
49 label = "reset";
50 gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
51 linux,code = <KEY_RESTART>;
52 };
53 };
54 };
55
56 &gpio0 {
57 status = "okay";
58 };
59
60 &gpio1 {
61 status = "okay";
62 };
63
64 &gpio2 {
65 status = "okay";
66 };
67
68 &gpio3 {
69 status = "okay";
70 };
71
72 &spi0 {
73 status = "okay";
74
75 m25p80@0 {
76 compatible = "jedec,spi-nor";
77 reg = <0>;
78 spi-max-frequency = <10000000>;
79
80 partitions {
81 compatible = "fixed-partitions";
82 #address-cells = <1>;
83 #size-cells = <1>;
84
85 partition@0 {
86 label = "u-boot";
87 reg = <0x0 0x30000>;
88 };
89
90 partition@30000 {
91 label = "u-boot-env";
92 reg = <0x30000 0x10000>;
93 read-only;
94 };
95
96 factory: partition@40000 {
97 label = "factory";
98 reg = <0x40000 0x10000>;
99 read-only;
100 };
101
102 partition@50000 {
103 compatible = "denx,uimage";
104 label = "firmware";
105 reg = <0x50000 0xf80000>;
106 };
107 };
108 };
109 };
110
111 &ethernet {
112 pinctrl-names = "default";
113 pinctrl-0 = <&ephy_pins>;
114 mtd-mac-address = <&factory 0x4>;
115 mediatek,portmap = "wllll";
116 };
117
118 &wmac {
119 ralink,mtd-eeprom = <&factory 0>;
120 pinctrl-names = "default";
121 pinctrl-0 = <&pa_pins>;
122 };
123
124 &pcie {
125 status = "okay";
126 };
127
128 &pcie0 {
129 mt76@0,0 {
130 reg = <0x0000 0 0 0 0>;
131 mediatek,mtd-eeprom = <&factory 0x8000>;
132 ieee80211-freq-limit = <5000000 6000000>;
133 };
134 };
135
136 &state_default {
137 gpio {
138 ralink,group = "wled", "i2c", "uartf", "wdt";
139 ralink,function = "gpio";
140 };
141 };