3ca9bea58e411ed537da8b7a41e886b4f988d7b4
[openwrt/staging/dedeckeh.git] / target / linux / lantiq / files / arch / mips / boot / dts / VGV7519.dtsi
1 #include "vr9.dtsi"
2
3 #include <dt-bindings/input/input.h>
4 #include <dt-bindings/mips/lantiq_rcu_gphy.h>
5
6 / {
7 compatible = "arcadyan,vgv7519", "lantiq,xway", "lantiq,vr9";
8
9 chosen {
10 bootargs = "console=ttyLTQ0,115200 mem=62M vpe1_load_addr=0x83e00000 vpe1_mem=2M maxvpes=1 maxtcs=1 nosmp";
11 };
12
13 aliases {
14 led-boot = &power_green;
15 led-failsafe = &power_red;
16 led-running = &power_green;
17 led-upgrade = &power_green;
18
19 led-dsl = &broadband_green;
20 led-internet = &internet_green;
21 led-wifi = &wireless_green;
22 };
23
24 memory@0 {
25 device_type = "memory";
26 reg = <0x0 0x4000000>;
27 };
28
29 gpio-keys-polled {
30 compatible = "gpio-keys-polled";
31 #address-cells = <1>;
32 #size-cells = <0>;
33 poll-interval = <100>;
34 reset {
35 label = "reset";
36 gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
37 linux,code = <KEY_RESTART>;
38 };
39 eco {
40 label = "eco";
41 gpios = <&gpio 41 GPIO_ACTIVE_LOW>;
42 linux,code = <BTN_0>;
43 };
44 rfkill {
45 label = "rfkill";
46 gpios = <&gpio 45 GPIO_ACTIVE_LOW>;
47 linux,code = <KEY_RFKILL>;
48 };
49 wps {
50 label = "wps";
51 gpios = <&gpio 10 GPIO_ACTIVE_LOW>;
52 linux,code = <KEY_WPS_BUTTON>;
53 };
54 };
55
56 gpio-leds {
57 compatible = "gpio-leds";
58
59 eco {
60 label = "vgv7519:blue:eco";
61 gpios = <&stp 2 GPIO_ACTIVE_LOW>;
62 };
63 wps_red {
64 label = "vgv7519:red:wps";
65 gpios = <&stp 3 GPIO_ACTIVE_LOW>;
66 };
67 wps_green {
68 label = "vgv7519:green:wps";
69 gpios = <&stp 4 GPIO_ACTIVE_LOW>;
70 };
71 upgrade {
72 label = "vgv7519:blue:upgrade";
73 gpios = <&stp 5 GPIO_ACTIVE_LOW>;
74 };
75 tv {
76 label = "vgv7519:green:tv";
77 gpios = <&stp 6 GPIO_ACTIVE_LOW>;
78 };
79 internet_green: internet_green {
80 label = "vgv7519:green:internet";
81 gpios = <&stp 7 GPIO_ACTIVE_LOW>;
82 };
83 internet_red {
84 label = "vgv7519:red:internet";
85 gpios = <&stp 8 GPIO_ACTIVE_LOW>;
86 };
87 broadband_red {
88 label = "vgv7519:red:broadband";
89 gpios = <&stp 9 GPIO_ACTIVE_LOW>;
90 };
91 broadband_green: broadband_green {
92 label = "vgv7519:green:broadband";
93 gpios = <&stp 10 GPIO_ACTIVE_LOW>;
94 };
95 voice {
96 label = "vgv7519:green:voice";
97 gpios = <&stp 11 GPIO_ACTIVE_LOW>;
98 };
99 wireless_red {
100 label = "vgv7519:red:wireless";
101 gpios = <&stp 12 GPIO_ACTIVE_LOW>;
102 };
103 wireless_green: wireless_green {
104 label = "vgv7519:green:wireless";
105 gpios = <&stp 13 GPIO_ACTIVE_LOW>;
106 };
107 power_green: power2 {
108 label = "vgv7519:green:power";
109 gpios = <&stp 14 GPIO_ACTIVE_LOW>;
110 default-state = "keep";
111 };
112 power_red: power {
113 label = "vgv7519:red:power";
114 gpios = <&stp 15 GPIO_ACTIVE_LOW>;
115 };
116 };
117
118 usb_vbus: regulator-usb-vbus {
119 compatible = "regulator-fixed";
120
121 regulator-name = "USB_VBUS";
122
123 regulator-min-microvolt = <5000000>;
124 regulator-max-microvolt = <5000000>;
125
126 gpio = <&gpio 32 GPIO_ACTIVE_HIGH>;
127 enable-active-high;
128 };
129 };
130
131 &eth0 {
132 lan: interface@0 {
133 compatible = "lantiq,xrx200-pdi";
134 #address-cells = <1>;
135 #size-cells = <0>;
136 reg = <0>;
137 mtd-mac-address = <&boardconfig 0x16>;
138 mtd-mac-address-increment = <1>;
139 lantiq,switch;
140
141 ethernet@0 {
142 compatible = "lantiq,xrx200-pdi-port";
143 reg = <0>;
144 phy-mode = "rgmii";
145 phy-handle = <&phy0>;
146 };
147 ethernet@1 {
148 compatible = "lantiq,xrx200-pdi-port";
149 reg = <1>;
150 phy-mode = "rgmii";
151 phy-handle = <&phy1>;
152 };
153 ethernet@2 {
154 compatible = "lantiq,xrx200-pdi-port";
155 reg = <2>;
156 phy-mode = "gmii";
157 phy-handle = <&phy11>;
158 };
159 ethernet@4 {
160 compatible = "lantiq,xrx200-pdi-port";
161 reg = <4>;
162 phy-mode = "gmii";
163 phy-handle = <&phy13>;
164 };
165 ethernet@5 {
166 compatible = "lantiq,xrx200-pdi-port";
167 reg = <5>;
168 phy-mode = "rgmii";
169 phy-handle = <&phy5>;
170 };
171 };
172
173 mdio@0 {
174 #address-cells = <1>;
175 #size-cells = <0>;
176 compatible = "lantiq,xrx200-mdio";
177 reg = <0>;
178
179 phy0: ethernet-phy@0 {
180 reg = <0x0>;
181 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
182 };
183 phy1: ethernet-phy@1 {
184 reg = <0x1>;
185 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
186 };
187 phy5: ethernet-phy@5 {
188 reg = <0x5>;
189 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
190 };
191 phy11: ethernet-phy@11 {
192 reg = <0x11>;
193 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
194 };
195 phy13: ethernet-phy@13 {
196 reg = <0x13>;
197 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
198 };
199 };
200 };
201
202 &gphy0 {
203 lantiq,gphy-mode = <GPHY_MODE_GE>;
204 };
205
206 &gphy1 {
207 lantiq,gphy-mode = <GPHY_MODE_GE>;
208 };
209
210 &gpio {
211 pinctrl-names = "default";
212 pinctrl-0 = <&state_default>;
213
214 state_default: pinmux {
215 stp {
216 lantiq,groups = "stp";
217 lantiq,function = "stp";
218 lantiq,open-drain = <0>;
219 lantiq,output = <1>;
220 lantiq,pull = <0>;
221 };
222 mdio {
223 lantiq,groups = "mdio";
224 lantiq,function = "mdio";
225 };
226 pci-rst {
227 lantiq,pins = "io21";
228 lantiq,open-drain = <0>;
229 lantiq,pull = <0>;
230 lantiq,output = <1>;
231 };
232 gphy-leds {
233 lantiq,groups = "gphy0 led1", "gphy1 led0";
234 lantiq,function = "gphy";
235 lantiq,open-drain = <0>;
236 lantiq,pull = <0>;
237 lantiq,output = <1>;
238 };
239 };
240 };
241
242 &localbus {
243 nor@0 {
244 compatible = "lantiq,nor";
245 bank-width = <2>;
246 reg = <0 0x0 0x800000>, <1 0x800000 0x800000>;
247 #address-cells = <1>;
248 #size-cells = <1>;
249
250 partitions {
251 compatible = "fixed-partitions";
252 #address-cells = <1>;
253 #size-cells = <1>;
254
255 boardconfig: partition@40000 {
256 label = "board_config";
257 reg = <0x40000 0x10000>;
258 read-only;
259 };
260 };
261 };
262 };
263
264 &pci0 {
265 status = "okay";
266 gpio-reset = <&gpio 21 GPIO_ACTIVE_HIGH>;
267
268 wifi@1814,3091 {
269 compatible = "pci1814,3091";
270 reg = <0x7000 0 0 0 0>;
271 ralink,mtd-eeprom = <&boardconfig 0x410>;
272 ralink,mtd-eeprom-swap;
273 mtd-mac-address = <&boardconfig 0x16>;
274 mtd-mac-address-increment = <1>;
275 };
276 };
277
278 &pcie0 {
279 status = "disabled";
280 };
281
282 &stp {
283 status = "okay";
284 lantiq,shadow = <0xffff>;
285 lantiq,groups = <0x3>;
286 lantiq,dsl = <0x0>;
287 lantiq,phy1 = <0x0>;
288 lantiq,phy2 = <0x0>;
289 /* lantiq,rising; */
290 };
291
292 &usb_phy0 {
293 status = "okay";
294 };
295
296 &usb_phy1 {
297 status = "okay";
298 };
299
300 &usb0 {
301 status = "okay";
302 vbus-supply = <&usb_vbus>;
303 };
304
305 &usb1 {
306 status = "okay";
307 vbus-supply = <&usb_vbus>;
308 };
309
310 &vmmc {
311 status = "okay";
312 gpios = <&gpio 30 GPIO_ACTIVE_HIGH //fxs relay
313 &gpio 31 GPIO_ACTIVE_HIGH //still unknown
314 &gpio 3 GPIO_ACTIVE_HIGH>; //reset_slic?
315 };