]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/blame - arch/arm/boot/dts/kirkwood-lswvl.dts
Merge remote-tracking branches 'asoc/topic/atmel', 'asoc/topic/bcm2835' and 'asoc...
[mirror_ubuntu-zesty-kernel.git] / arch / arm / boot / dts / kirkwood-lswvl.dts
CommitLineData
c43379e1
RS
1/*
2 * Device Tree file for Buffalo Linkstation LS-WVL/VL
3 *
6f86e9ad
RS
4 * Copyright (C) 2015, 2016
5 * Roger Shimizu <rogershimizu@gmail.com>
c43379e1
RS
6 *
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version
10 * 2 of the License, or (at your option) any later version.
11 */
12
13/dts-v1/;
14
15#include "kirkwood.dtsi"
16#include "kirkwood-6282.dtsi"
17
18/ {
19 model = "Buffalo Linkstation LS-WVL/VL";
20 compatible = "buffalo,lswvl", "buffalo,lsvl", "marvell,kirkwood-88f6282", "marvell,kirkwood";
21
22 memory { /* 256 MB */
23 device_type = "memory";
24 reg = <0x00000000 0x10000000>;
25 };
26
27 chosen {
28 bootargs = "console=ttyS0,115200n8 earlyprintk";
29 stdout-path = &uart0;
30 };
31
32 mbus {
33 pcie-controller {
34 status = "okay";
35 pcie@1,0 {
36 status = "okay";
37 };
38 };
39 };
40
41 ocp@f1000000 {
42 pinctrl: pin-controller@10000 {
43 pmx_power_hdd0: pmx-power-hdd0 {
44 marvell,pins = "mpp8";
45 marvell,function = "gpio";
46 };
47 pmx_power_hdd1: pmx-power-hdd1 {
48 marvell,pins = "mpp9";
49 marvell,function = "gpio";
50 };
51 pmx_usb_vbus: pmx-usb-vbus {
52 marvell,pins = "mpp12";
53 marvell,function = "gpio";
54 };
55 pmx_fan_high: pmx-fan-high {
56 marvell,pins = "mpp16";
57 marvell,function = "gpio";
58 };
59 pmx_fan_low: pmx-fan-low {
60 marvell,pins = "mpp17";
61 marvell,function = "gpio";
62 };
63 pmx_led_hdderr0: pmx-led-hdderr0 {
64 marvell,pins = "mpp34";
65 marvell,function = "gpio";
66 };
67 pmx_led_hdderr1: pmx-led-hdderr1 {
68 marvell,pins = "mpp35";
69 marvell,function = "gpio";
70 };
71 pmx_led_alarm: pmx-led-alarm {
72 marvell,pins = "mpp36";
73 marvell,function = "gpio";
74 };
75 pmx_led_function_red: pmx-led-function-red {
76 marvell,pins = "mpp37";
77 marvell,function = "gpio";
78 };
79 pmx_led_info: pmx-led-info {
80 marvell,pins = "mpp38";
81 marvell,function = "gpio";
82 };
83 pmx_led_function_blue: pmx-led-function-blue {
84 marvell,pins = "mpp39";
85 marvell,function = "gpio";
86 };
87 pmx_led_power: pmx-led-power {
88 marvell,pins = "mpp40";
89 marvell,function = "gpio";
90 };
91 pmx_fan_lock: pmx-fan-lock {
92 marvell,pins = "mpp43";
93 marvell,function = "gpio";
94 };
95 pmx_button_function: pmx-button-function {
96 marvell,pins = "mpp45";
97 marvell,function = "gpio";
98 };
99 pmx_power_switch: pmx-power-switch {
100 marvell,pins = "mpp46";
101 marvell,function = "gpio";
102 };
103 pmx_power_auto_switch: pmx-power-auto-switch {
104 marvell,pins = "mpp47";
105 marvell,function = "gpio";
106 };
107 };
108
109 serial@12000 {
110 status = "okay";
111 };
112
113 sata@80000 {
114 status = "okay";
115 nr-ports = <2>;
116 };
117
118 spi@10600 {
119 status = "okay";
120
121 m25p40@0 {
122 #address-cells = <1>;
123 #size-cells = <1>;
124 compatible = "st,m25p40", "jedec,spi-nor";
125 reg = <0>;
126 spi-max-frequency = <25000000>;
127 mode = <0>;
128
129 partition@0 {
130 reg = <0x0 0x60000>;
131 label = "uboot";
132 read-only;
133 };
134
135 partition@60000 {
136 reg = <0x60000 0x10000>;
137 label = "dtb";
138 read-only;
139 };
140
141 partition@70000 {
142 reg = <0x70000 0x10000>;
143 label = "uboot_env";
144 };
145 };
146 };
147 };
148
149 gpio_keys {
150 compatible = "gpio-keys";
151 #address-cells = <1>;
152 #size-cells = <0>;
153 pinctrl-0 = <&pmx_button_function &pmx_power_switch
154 &pmx_power_auto_switch>;
155 pinctrl-names = "default";
156
157 button@1 {
158 label = "Function Button";
159 linux,code = <KEY_OPTION>;
6f86e9ad 160 gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
c43379e1
RS
161 };
162
163 button@2 {
164 label = "Power-on Switch";
165 linux,code = <KEY_RESERVED>;
166 linux,input-type = <5>;
6f86e9ad 167 gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
c43379e1
RS
168 };
169
170 button@3 {
171 label = "Power-auto Switch";
172 linux,code = <KEY_ESC>;
173 linux,input-type = <5>;
6f86e9ad 174 gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
c43379e1
RS
175 };
176 };
177
178 gpio_leds {
179 compatible = "gpio-leds";
180 pinctrl-0 = <&pmx_led_function_red &pmx_led_alarm
181 &pmx_led_info &pmx_led_power
182 &pmx_led_function_blue
183 &pmx_led_hdderr0
184 &pmx_led_hdderr1>;
185 pinctrl-names = "default";
186
187 led@1 {
188 label = "lswvl:red:alarm";
0418138e 189 gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
c43379e1
RS
190 };
191
192 led@2 {
193 label = "lswvl:red:func";
0418138e 194 gpios = <&gpio1 5 GPIO_ACTIVE_HIGH>;
c43379e1
RS
195 };
196
197 led@3 {
198 label = "lswvl:amber:info";
0418138e 199 gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>;
c43379e1
RS
200 };
201
202 led@4 {
203 label = "lswvl:blue:func";
0418138e 204 gpios = <&gpio1 7 GPIO_ACTIVE_HIGH>;
c43379e1
RS
205 };
206
207 led@5 {
208 label = "lswvl:blue:power";
6f86e9ad 209 gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
c43379e1
RS
210 default-state = "keep";
211 };
212
213 led@6 {
214 label = "lswvl:red:hdderr0";
0418138e 215 gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
c43379e1
RS
216 };
217
218 led@7 {
219 label = "lswvl:red:hdderr1";
0418138e 220 gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
c43379e1
RS
221 };
222 };
223
224 gpio_fan {
225 compatible = "gpio-fan";
226 pinctrl-0 = <&pmx_fan_low &pmx_fan_high &pmx_fan_lock>;
227 pinctrl-names = "default";
228
229 gpios = <&gpio0 17 GPIO_ACTIVE_LOW
230 &gpio0 16 GPIO_ACTIVE_LOW>;
231
232 gpio-fan,speed-map = <0 3
233 1500 2
234 3250 1
235 5000 0>;
236
6f86e9ad 237 alarm-gpios = <&gpio1 11 GPIO_ACTIVE_HIGH>;
c43379e1
RS
238 };
239
240 restart_poweroff {
241 compatible = "restart-poweroff";
242 };
243
244 regulators {
245 compatible = "simple-bus";
246 #address-cells = <1>;
247 #size-cells = <0>;
248 pinctrl-0 = <&pmx_power_hdd0 &pmx_power_hdd1 &pmx_usb_vbus>;
249 pinctrl-names = "default";
250
251 usb_power: regulator@1 {
252 compatible = "regulator-fixed";
253 reg = <1>;
254 regulator-name = "USB Power";
255 regulator-min-microvolt = <5000000>;
256 regulator-max-microvolt = <5000000>;
257 enable-active-high;
258 regulator-always-on;
259 regulator-boot-on;
260 gpio = <&gpio0 12 GPIO_ACTIVE_HIGH>;
261 };
262 hdd_power0: regulator@2 {
263 compatible = "regulator-fixed";
264 reg = <2>;
265 regulator-name = "HDD0 Power";
266 regulator-min-microvolt = <5000000>;
267 regulator-max-microvolt = <5000000>;
268 enable-active-high;
269 regulator-always-on;
270 regulator-boot-on;
271 gpio = <&gpio0 8 GPIO_ACTIVE_HIGH>;
272 };
273 hdd_power1: regulator@3 {
274 compatible = "regulator-fixed";
275 reg = <3>;
276 regulator-name = "HDD1 Power";
277 regulator-min-microvolt = <5000000>;
278 regulator-max-microvolt = <5000000>;
279 enable-active-high;
280 regulator-always-on;
281 regulator-boot-on;
282 gpio = <&gpio0 9 GPIO_ACTIVE_HIGH>;
283 };
284 };
285};
286
287&mdio {
288 status = "okay";
289
290 ethphy0: ethernet-phy@0 {
291 device_type = "ethernet-phy";
292 reg = <0>;
293 };
294};
295
296&eth0 {
297 status = "okay";
298
299 ethernet0-port@0 {
300 phy-handle = <&ethphy0>;
301 };
302};