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