199b12ebdea6aad4b565d6829f075f2787101ca3
[openwrt/staging/mkresin.git] / target / linux / ramips / dts / mt7628an_buffalo_wcr-1166ds.dts
1 #include "mt7628an.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "buffalo,wcr-1166ds", "mediatek,mt7628an-soc";
8 model = "Buffalo WCR-1166DS";
9
10 aliases {
11 led-boot = &led_power;
12 led-failsafe = &led_power;
13 led-running = &led_power;
14 led-upgrade = &led_power;
15 };
16
17 keys {
18 compatible = "gpio-keys";
19
20 aoss {
21 label = "aoss";
22 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
23 linux,code = <KEY_WPS_BUTTON>;
24 };
25
26 ap {
27 label = "ap";
28 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
29 linux,code = <BTN_0>;
30 linux,input-type = <EV_SW>;
31 };
32
33 reset {
34 label = "reset";
35 gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
36 linux,code = <KEY_RESTART>;
37 };
38 };
39
40 leds {
41 compatible = "gpio-leds";
42
43 router_o {
44 label = "wcr-1166ds:orange:router";
45 gpios = <&gpio 37 GPIO_ACTIVE_LOW>;
46 };
47
48 router_g {
49 label = "wcr-1166ds:green:router";
50 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
51 };
52
53 internet_o {
54 label = "wcr-1166ds:orange:internet";
55 gpios = <&gpio 39 GPIO_ACTIVE_LOW>;
56 };
57
58 internet_g {
59 label = "wcr-1166ds:green:internet";
60 gpios = <&gpio 40 GPIO_ACTIVE_LOW>;
61 };
62
63 wireless_o {
64 label = "wcr-1166ds:orange:wireless";
65 gpios = <&gpio 41 GPIO_ACTIVE_LOW>;
66 };
67
68 wireless_g {
69 label = "wcr-1166ds:green:wireless";
70 gpios = <&gpio 42 GPIO_ACTIVE_LOW>;
71 };
72
73 diag {
74 label = "wcr-1166ds:orange:diag";
75 gpios = <&gpio 43 GPIO_ACTIVE_LOW>;
76 };
77
78 led_power: power {
79 label = "wcr-1166ds:green:power";
80 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
81 };
82 };
83 };
84
85 &ehci {
86 status = "disabled";
87 };
88
89 &esw {
90 mediatek,portmap = <0x2f>;
91 mediatek,portdisable = <0x27>;
92 };
93
94 &ohci {
95 status = "disabled";
96 };
97
98 &pcie {
99 status = "okay";
100 };
101
102 &pcie0 {
103 mt76@0,0 {
104 reg = <0x0000 0 0 0 0>;
105 mediatek,mtd-eeprom = <&factory 0x8000>;
106 ieee80211-freq-limit = <5000000 6000000>;
107 };
108 };
109
110 &state_default {
111 gpio {
112 groups = "uart1", "wled_an", "p0led_an", "p1led_an", "p2led_an", "p3led_an", "p4led_an", "wdt", "refclk", "gpio", "i2s";
113 function = "gpio";
114 };
115 };
116
117 &spi0 {
118 status = "okay";
119
120 flash@0 {
121 compatible = "jedec,spi-nor";
122 reg = <0>;
123 spi-max-frequency = <10000000>;
124
125 partitions {
126 compatible = "fixed-partitions";
127 #address-cells = <1>;
128 #size-cells = <1>;
129
130 partition@0 {
131 label = "u-boot";
132 reg = <0x0 0x30000>;
133 read-only;
134 };
135
136 partition@30000 {
137 label = "u-boot-env";
138 reg = <0x30000 0x10000>;
139 read-only;
140 };
141
142 factory: partition@40000 {
143 label = "factory";
144 reg = <0x40000 0x10000>;
145 read-only;
146 };
147
148 partition@50000 {
149 compatible = "openwrt,trx";
150 label = "firmware";
151 reg = <0x50000 0x7c0000>;
152 };
153
154 partition@810000 {
155 label = "firmware2";
156 reg = <0x810000 0x7c0000>;
157 };
158
159 partition@fd0000 {
160 label = "glbcfg";
161 reg = <0xfd0000 0x10000>;
162 read-only;
163 };
164
165 partition@fe0000 {
166 label = "board_data";
167 reg = <0xfe0000 0x10000>;
168 read-only;
169 };
170 };
171 };
172 };
173
174 &wmac {
175 status = "okay";
176 };