feefc8519ed5932f92a5d240e892fb70404e5653
[openwrt/openwrt.git] / target / linux / lantiq / files-4.14 / arch / mips / boot / dts / BTHOMEHUBV5A.dts
1 /dts-v1/;
2
3 #include "vr9.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 compatible = "bt,homehub-v5a", "lantiq,xway", "lantiq,vr9";
9 model = "BT Home Hub 5A";
10
11 chosen {
12 bootargs = "console=ttyLTQ0,115200";
13 };
14
15 aliases {
16 led-boot = &power_green;
17 led-failsafe = &power_red;
18 led-running = &power_blue;
19
20 led-dsl = &broadband_blue;
21 led-wifi = &wireless_blue;
22 };
23
24 memory@0 {
25 reg = <0x0 0x8000000>;
26 };
27
28 gphy-xrx200 {
29 compatible = "lantiq,phy-xrx200";
30 firmware1 = "lantiq/xrx200_phy11g_a14.bin"; /*VR9 1.1*/
31 firmware2 = "lantiq/xrx200_phy11g_a22.bin"; /*VR9 1.2*/
32 phys = [ 00 01 ];
33 };
34
35 gpio-keys-polled {
36 compatible = "gpio-keys-polled";
37 #address-cells = <1>;
38 #size-cells = <0>;
39 poll-interval = <100>;
40
41 reset {
42 label = "reset";
43 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
44 linux,code = <KEY_RESTART>;
45 };
46
47 wps {
48 label = "wps";
49 gpios = <&gpio 25 GPIO_ACTIVE_LOW>;
50 linux,code = <KEY_WPS_BUTTON>;
51 };
52
53 restart {
54 label = "restart";
55 gpios = <&gpio 39 GPIO_ACTIVE_LOW>;
56 linux,code = <KEY_POWER>;
57 };
58 };
59
60 gpio-leds {
61 compatible = "gpio-leds";
62
63 /* broadband-* is a single RGB led */
64 broadband-red {
65 label = "bthomehubv5a:red:broadband";
66 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
67 };
68 broadband-green {
69 label = "bthomehubv5a:green:broadband";
70 gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
71 };
72 broadband_blue: broadband-blue {
73 label = "bthomehubv5a:blue:broadband";
74 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
75 };
76
77 /* wireless-* is a single RGB led */
78 wireless-red {
79 label = "bthomehubv5a:red:wireless";
80 gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
81 };
82 wireless-green {
83 label = "bthomehubv5a:green:wireless";
84 gpios = <&gpio 10 GPIO_ACTIVE_LOW>;
85 };
86 wireless_blue: wireless-blue {
87 label = "bthomehubv5a:blue:wireless";
88 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
89 };
90
91 /* power-* is a single RGB led */
92 power_red: power-red {
93 label = "bthomehubv5a:red:power";
94 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
95 };
96 power_green: power-green {
97 label = "bthomehubv5a:green:power";
98 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
99 default-state = "keep";
100 };
101 power_blue: power-blue {
102 label = "bthomehubv5a:blue:power";
103 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
104 };
105
106 dimmed {
107 label = "dimmed";
108 gpios = <&gpio 19 GPIO_ACTIVE_HIGH>;
109 };
110 };
111 };
112
113 &eth0 {
114 lan: interface@0 {
115 compatible = "lantiq,xrx200-pdi";
116 #address-cells = <1>;
117 #size-cells = <0>;
118 reg = <0>;
119 lantiq,switch;
120
121 ethernet@0 {
122 compatible = "lantiq,xrx200-pdi-port";
123 reg = <0>;
124 phy-mode = "rgmii";
125 phy-handle = <&phy0>;
126 };
127 ethernet@1 {
128 compatible = "lantiq,xrx200-pdi-port";
129 reg = <1>;
130 phy-mode = "rgmii";
131 phy-handle = <&phy1>;
132 };
133 ethernet@2 {
134 compatible = "lantiq,xrx200-pdi-port";
135 reg = <2>;
136 phy-mode = "gmii";
137 phy-handle = <&phy11>;
138 };
139 ethernet@4 {
140 compatible = "lantiq,xrx200-pdi-port";
141 reg = <4>;
142 phy-mode = "gmii";
143 phy-handle = <&phy13>;
144 };
145 ethernet@5 {
146 compatible = "lantiq,xrx200-pdi-port";
147 reg = <5>;
148 phy-mode = "rgmii";
149 phy-handle = <&phy5>;
150 };
151 };
152
153 mdio@0 {
154 #address-cells = <1>;
155 #size-cells = <0>;
156 compatible = "lantiq,xrx200-mdio";
157 reg = <0>;
158
159 phy0: ethernet-phy@0 {
160 reg = <0x0>;
161 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
162 };
163 phy1: ethernet-phy@1 {
164 reg = <0x1>;
165 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
166 };
167 phy5: ethernet-phy@5 {
168 reg = <0x5>;
169 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
170 };
171 phy11: ethernet-phy@11 {
172 reg = <0x11>;
173 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
174 };
175 phy13: ethernet-phy@13 {
176 reg = <0x13>;
177 compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
178 };
179 };
180 };
181
182 &gpio {
183 pinctrl-names = "default";
184 pinctrl-0 = <&state_default>;
185
186 state_default: pinmux {
187 mdio {
188 lantiq,groups = "mdio";
189 lantiq,function = "mdio";
190 };
191 pci_rst {
192 lantiq,pins = "io21";
193 lantiq,output = <1>;
194 lantiq,open-drain;
195 };
196 pcie_rst {
197 lantiq,pins = "io38";
198 lantiq,pull = <0>;
199 lantiq,output = <1>;
200 lantiq,open-drain;
201 };
202 usb_vbus {
203 lantiq,pins = "io33";
204 lantiq,pull = <0>;
205 lantiq,open-drain = <0>;
206 lantiq,output = <1>;
207 };
208 nand_out {
209 lantiq,groups = "nand cle", "nand ale";
210 lantiq,function = "ebu";
211 lantiq,output = <1>;
212 lantiq,open-drain = <0>;
213 lantiq,pull = <0>;
214 };
215 nand_cs1 {
216 lantiq,groups = "nand cs1";
217 lantiq,function = "ebu";
218 lantiq,open-drain = <0>;
219 lantiq,pull = <0>;
220 };
221 };
222 };
223
224 &localbus {
225 nand@1 {
226 compatible = "lantiq,nand-xway";
227 lantiq,cs = <1>;
228 bank-width = <2>;
229 reg = <0x1 0x0 0x2000000>;
230 #address-cells = <1>;
231 #size-cells = <1>;
232 nand-on-flash-bbt;
233 nand-ecc-strength = <3>;
234 nand-ecc-step-size = <256>;
235
236 partitions {
237 compatible = "fixed-partitions";
238 #address-cells = <1>;
239 #size-cells = <1>;
240
241 partition@0 {
242 label = "u-boot";
243 reg = <0x0 0xa0000>;
244 read-only;
245 };
246 partition@a0000 {
247 label = "uboot-env";
248 reg = <0xa0000 0x20000>;
249 read-only;
250 };
251 partition@c0000 {
252 label = "unused";
253 reg = <0xc0000 0x40000>;
254 };
255 partition@100000 {
256 label = "ubi";
257 reg = <0x100000 0x7e80000>;
258 };
259 /*
260 * last 512 KiB are for the bad block table, not writable
261 */
262 };
263 };
264 };
265
266 &pci0 {
267 status = "okay";
268 gpio-reset = <&gpio 21 GPIO_ACTIVE_HIGH>;
269
270 wifi@168c,002d {
271 compatible = "pci168c,002d";
272 reg = <0x7000 0 0 0 0>;
273 qca,no-eeprom; /* load from ath9k-eeprom-pci-0000:00:0e.0.bin */
274 qca,disable-5ghz;
275 };
276 };
277
278 &usb0 {
279 status = "okay";
280 gpios = <&gpio 33 GPIO_ACTIVE_HIGH>;
281 };