lantiq: kernel 4.14: use vbus-supply devicetree property
[openwrt/openwrt.git] / target / linux / lantiq / files-4.14 / arch / mips / boot / dts / ARV452CQW.dts
1 /dts-v1/;
2
3 #include "danube.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 compatible = "arcadyan,arv452cqw", "lantiq,xway", "lantiq,danube";
9 model = "Arcor 801";
10
11 chosen {
12 bootargs = "console=ttyLTQ0,115200";
13 };
14
15 aliases {
16 led-boot = &power_blue;
17 led-failsafe = &power_red;
18 led-running = &power_blue;
19
20 led-dsl = &dsl_blue;
21 led-usb = &led_usb;
22 led-wifi = &wifi;
23 };
24
25 memory@0 {
26 reg = <0x0 0x2000000>;
27 };
28
29 ath5k_eep {
30 compatible = "ath5k,eeprom";
31 ath,eep-flash = <&boardconfig 0x400>;
32 ath,mac-offset = <0x0>;
33 ath,eep-swap;
34 };
35
36 gpio-keys-polled {
37 compatible = "gpio-keys-polled";
38 #address-cells = <1>;
39 #size-cells = <0>;
40 poll-interval = <100>;
41
42 rfkill {
43 label = "rfkill";
44 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
45 linux,code = <KEY_RFKILL>;
46 };
47 wps {
48 label = "wps";
49 gpios = <&gpio 29 GPIO_ACTIVE_LOW>;
50 linux,code = <KEY_WPS_BUTTON>;
51 };
52 reset {
53 label = "reset";
54 gpios = <&gpio 30 GPIO_ACTIVE_LOW>;
55 linux,code = <KEY_RESTART>;
56 };
57 };
58
59 gpio-leds {
60 compatible = "gpio-leds";
61 power_blue: power0 {
62 label = "arv452cqw:blue:power";
63 gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
64 default-state = "keep";
65 };
66 dsl_blue: dsl {
67 label = "arv452cqw:blue:dsl";
68 gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
69 };
70 isdn {
71 label = "arv452cqw:blue:isdn";
72 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
73 };
74 power_red: power1 {
75 label = "arv452cqw:red:power";
76 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
77 };
78 wps {
79 label = "arv452cqw:blue:wps";
80 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
81 };
82 wps1 {
83 label = "arv452cqw:yellow:wps";
84 gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
85 };
86 fxs1 {
87 label = "arv452cqw:blue:telefon1";
88 gpios = <&gpiomm 0 GPIO_ACTIVE_LOW>;
89 };
90 fxs2 {
91 label = "arv452cqw:blue:telefon2";
92 gpios = <&gpiomm 1 GPIO_ACTIVE_LOW>;
93 };
94 wps2 {
95 label = "arv452cqw:red:wps";
96 gpios = <&gpiomm 2 GPIO_ACTIVE_LOW>;
97 };
98 fxo {
99 label = "arv452cqw:blue:line";
100 gpios = <&gpiomm 3 GPIO_ACTIVE_LOW>;
101 };
102 voice {
103 label = "arv452cqw:blue:sprache";
104 gpios = <&gpiomm 4 1>;
105 };
106 led_usb: usb {
107 label = "arv452cqw:blue:usb";
108 gpios = <&gpiomm 5 GPIO_ACTIVE_LOW>;
109 };
110 wifi: wifi {
111 label = "arv452cqw:blue:wlan";
112 gpios = <&gpiomm 6 GPIO_ACTIVE_LOW>;
113 };
114 /*
115 internet blue and internet red are missing
116 dsl2 and dsl3 are not referenced in manual
117 */
118 dsl2 {
119 label = "arv452cqw:yellow:dsl";
120 gpios = <&gpiomm 8 GPIO_ACTIVE_LOW>;
121 };
122 dsl3 {
123 label = "arv452cqw:red:dsl";
124 gpios = <&gpiomm 9 GPIO_ACTIVE_LOW>;
125 };
126 };
127
128 usb_vbus: regulator-usb-vbus {
129 compatible = "regulator-fixed";
130
131 regulator-name = "USB_VBUS";
132
133 regulator-min-microvolt = <5000000>;
134 regulator-max-microvolt = <5000000>;
135
136 gpio = <&gpio 28 GPIO_ACTIVE_HIGH>;
137 enable-active-high;
138 };
139 };
140
141 &gpio {
142 pinctrl-names = "default";
143 pinctrl-0 = <&state_default>;
144
145 state_default: pinmux {
146 ebu {
147 lantiq,groups = "ebu cs1";
148 lantiq,function = "ebu";
149 };
150 pci_in {
151 lantiq,groups = "req1";
152 lantiq,function = "pci";
153 lantiq,open-drain = <1>;
154 lantiq,pull = <2>;
155 lantiq,output = <0>;
156 };
157 pci_out {
158 lantiq,groups = "gnt1";
159 lantiq,function = "pci";
160 lantiq,output = <1>;
161 };
162 pci_rst {
163 lantiq,pins = "io21";
164 lantiq,pull = <0>;
165 lantiq,output = <1>;
166 };
167 leds {
168 lantiq,pins = "io3", "io5", "io6", "io7", "io9";
169 lantiq,output = <1>;
170 };
171 };
172 };
173
174 &gpiomm {
175 status = "okay";
176 lantiq,shadow = <0x77f>;
177 };
178
179 /*
180 #define ARV452CPW_SWITCH_RESET 110
181 */
182 &gsw {
183 phy-mode = "rmii";
184 mtd-mac-address = <&boardconfig 0x16>;
185 };
186
187 &localbus {
188 nor@0 {
189 compatible = "lantiq,nor";
190 bank-width = <2>;
191 reg = <0 0x0 0x400000>;
192 #address-cells = <1>;
193 #size-cells = <1>;
194
195 partitions {
196 compatible = "fixed-partitions";
197 #address-cells = <1>;
198 #size-cells = <1>;
199
200 partition@0 {
201 label = "uboot";
202 reg = <0x00000 0x10000>;
203 read-only;
204 };
205
206 partition@10000 {
207 label = "uboot_env";
208 reg = <0x10000 0x10000>;
209 read-only;
210 };
211
212 partition@20000 {
213 label = "firmware";
214 reg = <0x20000 0x3d0000>;
215 };
216
217 boardconfig: partition@3f0000 {
218 label = "boardconfig";
219 reg = <0x3f0000 0x10000>;
220 read-only;
221 };
222 };
223 };
224 };
225
226 &pci0 {
227 status = "okay";
228 lantiq,external-clock;
229 gpio-reset = <&gpio 21 GPIO_ACTIVE_HIGH>;
230 };
231
232 &usb_phy {
233 status = "okay";
234 };
235
236 &usb {
237 status = "okay";
238 vbus-supply = <&usb_vbus>;
239 };
240
241 &vmmc {
242 status = "okay";
243 gpios = <&gpio 31 GPIO_ACTIVE_HIGH
244 &gpiomm 7 GPIO_ACTIVE_HIGH>;
245 };