9429d5caf3f8aafb455aec5e964efae83337866c
[openwrt/openwrt.git] / target / linux / lantiq / dts / P2812HNUFX.dtsi
1 #include "vr9.dtsi"
2
3 #include <dt-bindings/input/input.h>
4
5 / {
6 compatible = "zyxel,p-2812hnu", "lantiq,xway", "lantiq,vr9";
7
8 chosen {
9 bootargs = "console=ttyLTQ0,115200";
10 };
11
12 aliases {
13 led-boot = &power_green;
14 led-failsafe = &power_red;
15 led-running = &power_green;
16
17 led-dsl = &dsl_green;
18 led-internet = &internet_green;
19 led-wifi = &wireless_green;
20 };
21
22 memory@0 {
23 reg = <0x0 0x8000000>;
24 };
25
26 fpi@10000000 {
27 gpio: pinmux@E100B10 {
28 pinctrl-names = "default";
29 pinctrl-0 = <&state_default>;
30
31 state_default: pinmux {
32 exin3 {
33 lantiq,groups = "exin3";
34 lantiq,function = "exin";
35 };
36 mdio {
37 lantiq,groups = "mdio";
38 lantiq,function = "mdio";
39 };
40 gphy-leds {
41 lantiq,groups = "gphy0 led1", "gphy1 led1",
42 "gphy0 led2", "gphy1 led2";
43 lantiq,function = "gphy";
44 lantiq,pull = <2>;
45 lantiq,open-drain = <0>;
46 lantiq,output = <1>;
47 };
48 stp {
49 lantiq,groups = "stp";
50 lantiq,function = "stp";
51 lantiq,pull = <2>;
52 lantiq,open-drain = <0>;
53 lantiq,output = <1>;
54 };
55 pci-in {
56 lantiq,groups = "req1";
57 lantiq,function = "pci";
58 lantiq,output = <0>;
59 lantiq,open-drain = <1>;
60 lantiq,pull = <2>;
61 };
62 pci-out {
63 lantiq,groups = "gnt1";
64 lantiq,function = "pci";
65 lantiq,output = <1>;
66 lantiq,open-drain = <0>;
67 lantiq,pull = <0>;
68 };
69 pci_rst {
70 lantiq,pins = "io21";
71 lantiq,output = <1>;
72 lantiq,open-drain = <0>;
73 lantiq,pull = <2>;
74 };
75 pcie-rst {
76 lantiq,pins = "io38";
77 lantiq,pull = <0>;
78 lantiq,output = <1>;
79 };
80 ifxhcd-rst {
81 lantiq,pins = "io33";
82 lantiq,pull = <0>;
83 lantiq,open-drain = <0>;
84 lantiq,output = <1>;
85 };
86 nand_out {
87 lantiq,groups = "nand cle", "nand ale";
88 lantiq,function = "ebu";
89 lantiq,output = <1>;
90 lantiq,open-drain = <0>;
91 lantiq,pull = <0>;
92 };
93 nand_cs1 {
94 lantiq,groups = "nand cs1";
95 lantiq,function = "ebu";
96 lantiq,open-drain = <0>;
97 lantiq,pull = <0>;
98 };
99 };
100 };
101
102 stp: stp@E100BB0 {
103 compatible = "lantiq,gpio-stp-xway";
104 reg = <0xE100BB0 0x40>;
105 #gpio-cells = <2>;
106 gpio-controller;
107
108 lantiq,shadow = <0xffffff>;
109 lantiq,groups = <0x7>;
110 lantiq,dsl = <0x0>;
111 lantiq,phy1 = <0x0>;
112 lantiq,phy2 = <0x0>;
113 };
114
115 ifxhcd@E101000 {
116 status = "okay";
117 gpios = <&gpio 33 GPIO_ACTIVE_HIGH>;
118 lantiq,portmask = <0x3>;
119 };
120
121 ifxhcd@E106000 {
122 status = "okay";
123 gpios = <&gpio 33 GPIO_ACTIVE_HIGH>;
124 };
125
126 pci@E105400 {
127 status = "okay";
128 gpio-reset = <&gpio 21 GPIO_ACTIVE_HIGH>;
129 };
130 };
131
132 gphy-xrx200 {
133 compatible = "lantiq,phy-xrx200";
134 firmware1 = "lantiq/vr9_phy11g_a1x.bin"; /*VR9 1.1*/
135 firmware2 = "lantiq/vr9_phy11g_a2x.bin"; /*VR9 1.2*/
136 phys = [ 00 01 ];
137 };
138
139 gpio-keys-polled {
140 compatible = "gpio-keys-polled";
141 #address-cells = <1>;
142 #size-cells = <0>;
143 poll-interval = <100>;
144
145 reset {
146 label = "reset";
147 gpios = <&gpio 39 GPIO_ACTIVE_LOW>;
148 linux,code = <KEY_RESTART>;
149 };
150
151 rfkill {
152 label = "rfkill";
153 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
154 linux,code = <KEY_RFKILL>;
155 };
156 };
157
158 gpio-leds {
159 compatible = "gpio-leds";
160
161 internet_red {
162 label = "p2812hnufx:red:internet";
163 gpios = <&stp 16 GPIO_ACTIVE_LOW>;
164 };
165 internet_green: internet_green {
166 label = "p2812hnufx:green:internet";
167 gpios = <&stp 17 GPIO_ACTIVE_LOW>;
168 };
169 dsl_green: dsl_green {
170 label = "p2812hnufx:green:dsl";
171 gpios = <&stp 18 GPIO_ACTIVE_LOW>;
172 };
173 dsl_orange {
174 label = "p2812hnufx:orange:dsl";
175 gpios = <&stp 19 GPIO_ACTIVE_LOW>;
176 };
177 wireless_orange {
178 label = "p2812hnufx:orange:wlan";
179 gpios = <&stp 20 GPIO_ACTIVE_LOW>;
180 };
181 wireless_green: wireless_green {
182 label = "p2812hnufx:green:wlan";
183 gpios = <&stp 21 GPIO_ACTIVE_LOW>;
184 };
185 power_red: power {
186 label = "p2812hnufx:red:power";
187 gpios = <&stp 22 GPIO_ACTIVE_LOW>;
188 };
189 power_green: power2 {
190 label = "p2812hnufx:green:power";
191 gpios = <&stp 23 GPIO_ACTIVE_LOW>;
192 default-state = "keep";
193 };
194 phone1 {
195 label = "p2812hnufx:green:phone";
196 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
197 };
198 phone1warn {
199 label = "p2812hnufx:orange:phone";
200 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
201 };
202 phone2warn {
203 label = "p2812hnufx:orange:phone2";
204 gpios = <&gpio 26 GPIO_ACTIVE_LOW>;
205 };
206 phone2 {
207 label = "p2812hnufx:green:phone2";
208 gpios = <&gpio 28 GPIO_ACTIVE_LOW>;
209 };
210 };
211 };
212
213 &eth0 {
214 lan: interface@0 {
215 compatible = "lantiq,xrx200-pdi";
216 #address-cells = <1>;
217 #size-cells = <0>;
218 reg = <0>;
219 mac-address = [ 00 11 22 33 44 55 ];
220 lantiq,switch;
221
222 ethernet@0 {
223 compatible = "lantiq,xrx200-pdi-port";
224 reg = <0>;
225 phy-mode = "rgmii";
226 phy-handle = <&phy0>;
227 };
228 ethernet@1 {
229 compatible = "lantiq,xrx200-pdi-port";
230 reg = <1>;
231 phy-mode = "rgmii";
232 phy-handle = <&phy1>;
233 };
234 ethernet@2 {
235 compatible = "lantiq,xrx200-pdi-port";
236 reg = <2>;
237 phy-mode = "gmii";
238 phy-handle = <&phy11>;
239 };
240 ethernet@4 {
241 compatible = "lantiq,xrx200-pdi-port";
242 reg = <4>;
243 phy-mode = "gmii";
244 phy-handle = <&phy13>;
245 };
246 ethernet@5 {
247 compatible = "lantiq,xrx200-pdi-port";
248 reg = <5>;
249 phy-mode = "rgmii";
250 phy-handle = <&phy5>;
251 };
252 };
253
254 mdio@0 {
255 #address-cells = <1>;
256 #size-cells = <0>;
257 compatible = "lantiq,xrx200-mdio";
258
259 phy0: ethernet-phy@0 {
260 reg = <0x0>;
261 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
262 };
263 phy1: ethernet-phy@1 {
264 reg = <0x1>;
265 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
266 };
267 phy5: ethernet-phy@5 {
268 reg = <0x5>;
269 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
270 };
271 phy11: ethernet-phy@11 {
272 reg = <0x11>;
273 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
274 };
275 phy13: ethernet-phy@13 {
276 reg = <0x13>;
277 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
278 };
279 };
280 };