blob: 89ff404a528c74f3869c6afcfcfdb34cdc7cde46 [file] [log] [blame]
Thomas Petazzoni07f645d2012-11-16 16:39:46 +01001/*
2 * Copyright (C) 2012 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
3 *
4 * This file is licensed under the terms of the GNU General Public
5 * License version 2. This program is licensed "as is" without any
6 * warranty of any kind, whether express or implied.
7 */
8
Thomas Petazzoni9c4d82e2014-04-22 23:26:36 +02009/*
10 * TODO: add Orion USB device port init when kernel.org support is added.
11 * TODO: add flash write support: see below.
12 * TODO: add power-off support.
13 * TODO: add I2C EEPROM support.
14 */
15
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010016/dts-v1/;
Thomas Petazzoni48be9702014-04-22 23:26:15 +020017
Thomas Petazzoni2a934742014-04-22 23:26:16 +020018#include <dt-bindings/gpio/gpio.h>
19#include <dt-bindings/input/input.h>
Thomas Petazzoni39eabec2014-04-22 23:26:33 +020020#include <dt-bindings/interrupt-controller/irq.h>
Thomas Petazzoni5c697662014-04-22 23:26:17 +020021#include "orion5x-mv88f5182.dtsi"
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010022
23/ {
24 model = "LaCie Ethernet Disk mini V2";
Thomas Petazzonib2d57222013-03-06 11:23:36 +010025 compatible = "lacie,ethernet-disk-mini-v2", "marvell,orion5x-88f5182", "marvell,orion5x";
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010026
27 memory {
28 reg = <0x00000000 0x4000000>; /* 64 MB */
29 };
30
31 chosen {
32 bootargs = "console=ttyS0,115200n8 earlyprintk";
Thomas Petazzoni1fca8a22014-04-22 23:26:20 +020033 linux,stdout-path = &uart0;
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010034 };
35
Thomas Petazzoni5c697662014-04-22 23:26:17 +020036 soc {
37 ranges = <MBUS_ID(0xf0, 0x01) 0 0xf1000000 0x100000>,
Thomas Petazzonia54cd732014-04-22 23:26:35 +020038 <MBUS_ID(0x09, 0x00) 0 0xf2200000 0x800>,
39 <MBUS_ID(0x01, 0x0f) 0 0xfff80000 0x80000>;
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010040 };
41
Thomas Petazzoni7ca63532014-04-22 23:26:19 +020042 gpio-keys {
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010043 compatible = "gpio-keys";
Thomas Petazzoni43be7e02014-04-22 23:26:32 +020044 pinctrl-0 = <&pmx_power_button>;
45 pinctrl-names = "default";
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010046 #address-cells = <1>;
47 #size-cells = <0>;
48 button@1 {
49 label = "Power-on Switch";
Thomas Petazzoni2a934742014-04-22 23:26:16 +020050 linux,code = <KEY_POWER>;
51 gpios = <&gpio0 18 GPIO_ACTIVE_HIGH>;
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010052 };
53 };
54
Thomas Petazzoni7ca63532014-04-22 23:26:19 +020055 gpio-leds {
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010056 compatible = "gpio-leds";
Thomas Petazzoni43be7e02014-04-22 23:26:32 +020057 pinctrl-0 = <&pmx_power_led>;
58 pinctrl-names = "default";
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010059
60 led@1 {
61 label = "power:blue";
Thomas Petazzoni2a934742014-04-22 23:26:16 +020062 gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
Thomas Petazzoni07f645d2012-11-16 16:39:46 +010063 };
64 };
65};
Sebastian Hesselbarth99d64552013-07-02 13:00:20 +020066
Thomas Petazzonia54cd732014-04-22 23:26:35 +020067&devbus_bootcs {
68 status = "okay";
69
70 /* Read parameters */
71 devbus,bus-width = <8>;
72 devbus,turn-off-ps = <90000>;
73 devbus,badr-skew-ps = <0>;
74 devbus,acc-first-ps = <186000>;
75 devbus,acc-next-ps = <186000>;
76
77 /* Write parameters */
78 devbus,wr-high-ps = <90000>;
79 devbus,wr-low-ps = <90000>;
80 devbus,ale-wr-ps = <90000>;
81
82 /*
83 * Currently the MTD code does not recognize the MX29LV400CBCT
84 * as a bottom-type device. This could cause risks of
85 * accidentally erasing critical flash sectors. We thus define
86 * a single, write-protected partition covering the whole
87 * flash. TODO: once the flash part TOP/BOTTOM detection
88 * issue is sorted out in the MTD code, break this into at
89 * least three partitions: 'u-boot code', 'u-boot environment'
90 * and 'whatever is left'.
91 */
92 flash@0 {
93 compatible = "cfi-flash";
94 reg = <0 0x80000>;
95 bank-width = <1>;
96 #address-cells = <1>;
97 #size-cells = <1>;
98
99 partition@0 {
100 label = "Full512Kb";
101 reg = <0 0x80000>;
102 read-only;
103 };
104 };
105};
106
Thomas Petazzonia665fce2014-04-22 23:26:34 +0200107&ehci0 {
108 status = "okay";
109};
110
Thomas Petazzoni7e0878f2014-04-22 23:26:21 +0200111&eth {
112 status = "okay";
113
114 ethernet-port@0 {
115 phy-handle = <&ethphy>;
116 };
117};
118
Thomas Petazzoni39eabec2014-04-22 23:26:33 +0200119&i2c {
120 status = "okay";
121 clock-frequency = <100000>;
122 #address-cells = <1>;
123
124 rtc@32 {
125 compatible = "ricoh,rs5c372a";
126 reg = <0x32>;
127 interrupt-parent = <&gpio0>;
128 interrupts = <3 IRQ_TYPE_LEVEL_LOW>;
129 };
130};
131
Sebastian Hesselbarth99d64552013-07-02 13:00:20 +0200132&mdio {
133 status = "okay";
134
135 ethphy: ethernet-phy {
Sebastian Hesselbarth99d64552013-07-02 13:00:20 +0200136 reg = <8>;
137 };
138};
139
Thomas Petazzoni43be7e02014-04-22 23:26:32 +0200140&pinctrl {
141 pinctrl-0 = <&pmx_rtc &pmx_power_led_ctrl>;
142 pinctrl-names = "default";
143
144 pmx_power_button: pmx-power-button {
145 marvell,pins = "mpp18";
146 marvell,function = "gpio";
147 };
148
149 pmx_power_led: pmx-power-led {
150 marvell,pins = "mpp16";
151 marvell,function = "gpio";
152 };
153
154 pmx_power_led_ctrl: pmx-power-led-ctrl {
155 marvell,pins = "mpp17";
156 marvell,function = "gpio";
157 };
158
159 pmx_rtc: pmx-rtc {
160 marvell,pins = "mpp3";
161 marvell,function = "gpio";
162 };
163};
164
Thomas Petazzoni7e0878f2014-04-22 23:26:21 +0200165&sata {
Thomas Petazzoni43be7e02014-04-22 23:26:32 +0200166 pinctrl-0 = <&pmx_sata0 &pmx_sata1>;
167 pinctrl-names = "default";
Sebastian Hesselbarth99d64552013-07-02 13:00:20 +0200168 status = "okay";
Thomas Petazzoni7e0878f2014-04-22 23:26:21 +0200169 nr-ports = <2>;
170};
Sebastian Hesselbarth99d64552013-07-02 13:00:20 +0200171
Thomas Petazzoni7e0878f2014-04-22 23:26:21 +0200172&uart0 {
Thomas Petazzoni7e0878f2014-04-22 23:26:21 +0200173 status = "okay";
Sebastian Hesselbarth99d64552013-07-02 13:00:20 +0200174};