aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2014-11-28 16:34:33 -0500
committerArnd Bergmann <arnd@arndb.de>2014-11-28 16:34:33 -0500
commit2f84411d9f3f93057e71d1480e8768ed7c5b3274 (patch)
tree34ee647798536412d332022f39de56ae79fab4f0
parentb6072143e53b2e23ca3f0d404efd7b14f1456e7f (diff)
parent623394def7ef023aa44e338de680222cdc93c4a5 (diff)
Merge tag 'mvebu-dt-usb-phy-3.19-3' of git://git.infradead.org/linux-mvebu into next/dt2
Pull "mvebu DT changes for v3.19 (round 3)" from Jason Cooper: - Armada 375 - Add PHY and USB cluster controller support * tag 'mvebu-dt-usb-phy-3.19-3' of git://git.infradead.org/linux-mvebu: ARM: mvebu: add PHY support to the dts for the USB controllers on Armada 375 ARM: mvebu: add Device Tree description of USB cluster controller on Armada 375 Signed-off-by: Arnd Bergmann <arnd@arndb.de>
-rw-r--r--arch/arm/boot/dts/Makefile6
-rw-r--r--arch/arm/boot/dts/armada-370-db.dts106
-rw-r--r--arch/arm/boot/dts/armada-370-mirabox.dts25
-rw-r--r--arch/arm/boot/dts/armada-370-netgear-rn102.dts84
-rw-r--r--arch/arm/boot/dts/armada-370-netgear-rn104.dts64
-rw-r--r--arch/arm/boot/dts/armada-370-rd.dts73
-rw-r--r--arch/arm/boot/dts/armada-370-synology-ds213j.dts316
-rw-r--r--arch/arm/boot/dts/armada-370-xp.dtsi11
-rw-r--r--arch/arm/boot/dts/armada-370.dtsi189
-rw-r--r--arch/arm/boot/dts/armada-375.dtsi11
-rw-r--r--arch/arm/boot/dts/armada-385-db.dts2
-rw-r--r--arch/arm/boot/dts/armada-38x.dtsi6
-rw-r--r--arch/arm/boot/dts/armada-xp-axpwifiap.dts7
-rw-r--r--arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts2
-rw-r--r--arch/arm/boot/dts/armada-xp-synology-ds414.dts330
-rw-r--r--arch/arm/boot/dts/armada-xp.dtsi102
-rw-r--r--arch/arm/boot/dts/kirkwood-synology.dtsi2
17 files changed, 1080 insertions, 256 deletions
diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index bbce4f434178..2b093f12ac27 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -506,7 +506,8 @@ dtb-$(CONFIG_MACH_ARMADA_370) += \
506 armada-370-mirabox.dtb \ 506 armada-370-mirabox.dtb \
507 armada-370-netgear-rn102.dtb \ 507 armada-370-netgear-rn102.dtb \
508 armada-370-netgear-rn104.dtb \ 508 armada-370-netgear-rn104.dtb \
509 armada-370-rd.dtb 509 armada-370-rd.dtb \
510 armada-370-synology-ds213j.dtb
510dtb-$(CONFIG_MACH_ARMADA_375) += \ 511dtb-$(CONFIG_MACH_ARMADA_375) += \
511 armada-375-db.dtb 512 armada-375-db.dtb
512dtb-$(CONFIG_MACH_ARMADA_38X) += \ 513dtb-$(CONFIG_MACH_ARMADA_38X) += \
@@ -519,7 +520,8 @@ dtb-$(CONFIG_MACH_ARMADA_XP) += \
519 armada-xp-lenovo-ix4-300d.dtb \ 520 armada-xp-lenovo-ix4-300d.dtb \
520 armada-xp-matrix.dtb \ 521 armada-xp-matrix.dtb \
521 armada-xp-netgear-rn2120.dtb \ 522 armada-xp-netgear-rn2120.dtb \
522 armada-xp-openblocks-ax3-4.dtb 523 armada-xp-openblocks-ax3-4.dtb \
524 armada-xp-synology-ds414.dtb
523dtb-$(CONFIG_MACH_DOVE) += dove-cm-a510.dtb \ 525dtb-$(CONFIG_MACH_DOVE) += dove-cm-a510.dtb \
524 dove-cubox.dtb \ 526 dove-cubox.dtb \
525 dove-cubox-es.dtb \ 527 dove-cubox-es.dtb \
diff --git a/arch/arm/boot/dts/armada-370-db.dts b/arch/arm/boot/dts/armada-370-db.dts
index a495e5821ab8..1466580be295 100644
--- a/arch/arm/boot/dts/armada-370-db.dts
+++ b/arch/arm/boot/dts/armada-370-db.dts
@@ -75,6 +75,7 @@
75 clock-frequency = <100000>; 75 clock-frequency = <100000>;
76 status = "okay"; 76 status = "okay";
77 audio_codec: audio-codec@4a { 77 audio_codec: audio-codec@4a {
78 #sound-dai-cells = <0>;
78 compatible = "cirrus,cs42l51"; 79 compatible = "cirrus,cs42l51";
79 reg = <0x4a>; 80 reg = <0x4a>;
80 }; 81 };
@@ -102,30 +103,6 @@
102 broken-cd; 103 broken-cd;
103 }; 104 };
104 105
105 pinctrl {
106 /*
107 * These pins might be muxed as I2S by
108 * the bootloader, but it conflicts
109 * with the real I2S pins that are
110 * muxed using i2s_pins. We must mux
111 * those pins to a function other than
112 * I2S.
113 */
114 pinctrl-0 = <&hog_pins1 &hog_pins2>;
115 pinctrl-names = "default";
116
117 hog_pins1: hog-pins1 {
118 marvell,pins = "mpp6", "mpp8", "mpp10",
119 "mpp12", "mpp13";
120 marvell,function = "gpio";
121 };
122
123 hog_pins2: hog-pins2 {
124 marvell,pins = "mpp5", "mpp7", "mpp9";
125 marvell,function = "gpo";
126 };
127 };
128
129 usb@50000 { 106 usb@50000 {
130 status = "okay"; 107 status = "okay";
131 }; 108 };
@@ -135,6 +112,8 @@
135 }; 112 };
136 113
137 spi0: spi@10600 { 114 spi0: spi@10600 {
115 pinctrl-0 = <&spi0_pins2>;
116 pinctrl-names = "default";
138 status = "okay"; 117 status = "okay";
139 118
140 spi-flash@0 { 119 spi-flash@0 {
@@ -167,17 +146,84 @@
167 }; 146 };
168 147
169 sound { 148 sound {
170 compatible = "marvell,a370db-audio"; 149 compatible = "simple-audio-card";
171 marvell,audio-controller = <&audio_controller>; 150 simple-audio-card,name = "Armada 370 DB Audio";
172 marvell,audio-codec = <&audio_codec &spdif_out &spdif_in>; 151 simple-audio-card,mclk-fs = <256>;
173 status = "okay"; 152 simple-audio-card,widgets =
153 "Headphone", "Out Jack",
154 "Line", "In Jack";
155 simple-audio-card,routing =
156 "Out Jack", "HPL",
157 "Out Jack", "HPR",
158 "AIN1L", "In Jack",
159 "AIN1L", "In Jack";
160 status = "okay";
161
162 simple-audio-card,dai-link@0 {
163 format = "i2s";
164 cpu {
165 sound-dai = <&audio_controller 0>;
166 };
167
168 codec {
169 sound-dai = <&audio_codec>;
170 };
171 };
172
173 simple-audio-card,dai-link@1 {
174 format = "i2s";
175 cpu {
176 sound-dai = <&audio_controller 1>;
177 };
178
179 codec {
180 sound-dai = <&spdif_out>;
181 };
182 };
183
184 simple-audio-card,dai-link@2 {
185 format = "i2s";
186 cpu {
187 sound-dai = <&audio_controller 1>;
188 };
189
190 codec {
191 sound-dai = <&spdif_in>;
192 };
193 };
174 }; 194 };
175 195
176 spdif_out: spdif-out { 196 spdif_out: spdif-out {
177 compatible = "linux,spdif-dit"; 197 #sound-dai-cells = <0>;
198 compatible = "linux,spdif-dit";
178 }; 199 };
179 200
180 spdif_in: spdif-in { 201 spdif_in: spdif-in {
181 compatible = "linux,spdif-dir"; 202 #sound-dai-cells = <0>;
203 compatible = "linux,spdif-dir";
204 };
205};
206
207&pinctrl {
208 /*
209 * These pins might be muxed as I2S by
210 * the bootloader, but it conflicts
211 * with the real I2S pins that are
212 * muxed using i2s_pins. We must mux
213 * those pins to a function other than
214 * I2S.
215 */
216 pinctrl-0 = <&hog_pins1 &hog_pins2>;
217 pinctrl-names = "default";
218
219 hog_pins1: hog-pins1 {
220 marvell,pins = "mpp6", "mpp8", "mpp10",
221 "mpp12", "mpp13";
222 marvell,function = "gpio";
223 };
224
225 hog_pins2: hog-pins2 {
226 marvell,pins = "mpp5", "mpp7", "mpp9";
227 marvell,function = "gpo";
182 }; 228 };
183}; 229};
diff --git a/arch/arm/boot/dts/armada-370-mirabox.dts b/arch/arm/boot/dts/armada-370-mirabox.dts
index 2b6d24e0d1e8..e1b0eb6b091f 100644
--- a/arch/arm/boot/dts/armada-370-mirabox.dts
+++ b/arch/arm/boot/dts/armada-370-mirabox.dts
@@ -54,18 +54,6 @@
54 status = "okay"; 54 status = "okay";
55 }; 55 };
56 56
57 pinctrl {
58 pwr_led_pin: pwr-led-pin {
59 marvell,pins = "mpp63";
60 marvell,function = "gpo";
61 };
62
63 stat_led_pins: stat-led-pins {
64 marvell,pins = "mpp64", "mpp65";
65 marvell,function = "gpio";
66 };
67 };
68
69 gpio_leds { 57 gpio_leds {
70 compatible = "gpio-leds"; 58 compatible = "gpio-leds";
71 pinctrl-names = "default"; 59 pinctrl-names = "default";
@@ -169,3 +157,16 @@
169 }; 157 };
170 }; 158 };
171}; 159};
160
161&pinctrl {
162 pwr_led_pin: pwr-led-pin {
163 marvell,pins = "mpp63";
164 marvell,function = "gpo";
165 };
166
167 stat_led_pins: stat-led-pins {
168 marvell,pins = "mpp64", "mpp65";
169 marvell,function = "gpio";
170 };
171};
172
diff --git a/arch/arm/boot/dts/armada-370-netgear-rn102.dts b/arch/arm/boot/dts/armada-370-netgear-rn102.dts
index 1e38628f4060..4e24932c6e30 100644
--- a/arch/arm/boot/dts/armada-370-netgear-rn102.dts
+++ b/arch/arm/boot/dts/armada-370-netgear-rn102.dts
@@ -59,48 +59,6 @@
59 status = "okay"; 59 status = "okay";
60 }; 60 };
61 61
62 pinctrl {
63 power_led_pin: power-led-pin {
64 marvell,pins = "mpp57";
65 marvell,function = "gpio";
66 };
67
68 sata1_led_pin: sata1-led-pin {
69 marvell,pins = "mpp15";
70 marvell,function = "gpio";
71 };
72
73 sata2_led_pin: sata2-led-pin {
74 marvell,pins = "mpp14";
75 marvell,function = "gpio";
76 };
77
78 backup_led_pin: backup-led-pin {
79 marvell,pins = "mpp56";
80 marvell,function = "gpio";
81 };
82
83 backup_button_pin: backup-button-pin {
84 marvell,pins = "mpp58";
85 marvell,function = "gpio";
86 };
87
88 power_button_pin: power-button-pin {
89 marvell,pins = "mpp62";
90 marvell,function = "gpio";
91 };
92
93 reset_button_pin: reset-button-pin {
94 marvell,pins = "mpp6";
95 marvell,function = "gpio";
96 };
97
98 poweroff: poweroff {
99 marvell,pins = "mpp8";
100 marvell,function = "gpio";
101 };
102 };
103
104 mdio { 62 mdio {
105 pinctrl-0 = <&mdio_pins>; 63 pinctrl-0 = <&mdio_pins>;
106 pinctrl-names = "default"; 64 pinctrl-names = "default";
@@ -257,3 +215,45 @@
257 gpios = <&gpio0 8 GPIO_ACTIVE_LOW>; 215 gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
258 }; 216 };
259}; 217};
218
219&pinctrl {
220 power_led_pin: power-led-pin {
221 marvell,pins = "mpp57";
222 marvell,function = "gpio";
223 };
224
225 sata1_led_pin: sata1-led-pin {
226 marvell,pins = "mpp15";
227 marvell,function = "gpio";
228 };
229
230 sata2_led_pin: sata2-led-pin {
231 marvell,pins = "mpp14";
232 marvell,function = "gpio";
233 };
234
235 backup_led_pin: backup-led-pin {
236 marvell,pins = "mpp56";
237 marvell,function = "gpio";
238 };
239
240 backup_button_pin: backup-button-pin {
241 marvell,pins = "mpp58";
242 marvell,function = "gpio";
243 };
244
245 power_button_pin: power-button-pin {
246 marvell,pins = "mpp62";
247 marvell,function = "gpio";
248 };
249
250 reset_button_pin: reset-button-pin {
251 marvell,pins = "mpp6";
252 marvell,function = "gpio";
253 };
254
255 poweroff: poweroff {
256 marvell,pins = "mpp8";
257 marvell,function = "gpio";
258 };
259};
diff --git a/arch/arm/boot/dts/armada-370-netgear-rn104.dts b/arch/arm/boot/dts/armada-370-netgear-rn104.dts
index c2f414bb9aba..30586e47986a 100644
--- a/arch/arm/boot/dts/armada-370-netgear-rn104.dts
+++ b/arch/arm/boot/dts/armada-370-netgear-rn104.dts
@@ -53,38 +53,6 @@
53 status = "okay"; 53 status = "okay";
54 }; 54 };
55 55
56 pinctrl {
57 poweroff: poweroff {
58 marvell,pins = "mpp60";
59 marvell,function = "gpio";
60 };
61
62 backup_button_pin: backup-button-pin {
63 marvell,pins = "mpp52";
64 marvell,function = "gpio";
65 };
66
67 power_button_pin: power-button-pin {
68 marvell,pins = "mpp62";
69 marvell,function = "gpio";
70 };
71
72 backup_led_pin: backup-led-pin {
73 marvell,pins = "mpp63";
74 marvell,function = "gpo";
75 };
76
77 power_led_pin: power-led-pin {
78 marvell,pins = "mpp64";
79 marvell,function = "gpio";
80 };
81
82 reset_button_pin: reset-button-pin {
83 marvell,pins = "mpp65";
84 marvell,function = "gpio";
85 };
86 };
87
88 mdio { 56 mdio {
89 pinctrl-0 = <&mdio_pins>; 57 pinctrl-0 = <&mdio_pins>;
90 pinctrl-names = "default"; 58 pinctrl-names = "default";
@@ -269,3 +237,35 @@
269 gpios = <&gpio1 28 GPIO_ACTIVE_LOW>; 237 gpios = <&gpio1 28 GPIO_ACTIVE_LOW>;
270 }; 238 };
271}; 239};
240
241&pinctrl {
242 poweroff: poweroff {
243 marvell,pins = "mpp60";
244 marvell,function = "gpio";
245 };
246
247 backup_button_pin: backup-button-pin {
248 marvell,pins = "mpp52";
249 marvell,function = "gpio";
250 };
251
252 power_button_pin: power-button-pin {
253 marvell,pins = "mpp62";
254 marvell,function = "gpio";
255 };
256
257 backup_led_pin: backup-led-pin {
258 marvell,pins = "mpp63";
259 marvell,function = "gpo";
260 };
261
262 power_led_pin: power-led-pin {
263 marvell,pins = "mpp64";
264 marvell,function = "gpio";
265 };
266
267 reset_button_pin: reset-button-pin {
268 marvell,pins = "mpp65";
269 marvell,function = "gpio";
270 };
271};
diff --git a/arch/arm/boot/dts/armada-370-rd.dts b/arch/arm/boot/dts/armada-370-rd.dts
index f57a8f841498..394308951ed9 100644
--- a/arch/arm/boot/dts/armada-370-rd.dts
+++ b/arch/arm/boot/dts/armada-370-rd.dts
@@ -59,18 +59,6 @@
59 }; 59 };
60 60
61 internal-regs { 61 internal-regs {
62 pinctrl {
63 fan_pins: fan-pins {
64 marvell,pins = "mpp8";
65 marvell,function = "gpio";
66 };
67
68 led_pins: led-pins {
69 marvell,pins = "mpp32";
70 marvell,function = "gpio";
71 };
72 };
73
74 serial@12000 { 62 serial@12000 {
75 status = "okay"; 63 status = "okay";
76 }; 64 };
@@ -85,10 +73,6 @@
85 phy0: ethernet-phy@0 { 73 phy0: ethernet-phy@0 {
86 reg = <0>; 74 reg = <0>;
87 }; 75 };
88
89 phy1: ethernet-phy@1 {
90 reg = <1>;
91 };
92 }; 76 };
93 77
94 ethernet@70000 { 78 ethernet@70000 {
@@ -100,8 +84,11 @@
100 pinctrl-0 = <&ge1_rgmii_pins>; 84 pinctrl-0 = <&ge1_rgmii_pins>;
101 pinctrl-names = "default"; 85 pinctrl-names = "default";
102 status = "okay"; 86 status = "okay";
103 phy = <&phy1>;
104 phy-mode = "rgmii-id"; 87 phy-mode = "rgmii-id";
88 fixed-link {
89 speed = <1000>;
90 full-duplex;
91 };
105 }; 92 };
106 93
107 mvsdio@d4000 { 94 mvsdio@d4000 {
@@ -173,4 +160,56 @@
173 }; 160 };
174 }; 161 };
175 }; 162 };
163
164 dsa@0 {
165 compatible = "marvell,dsa";
166 #address-cells = <2>;
167 #size-cells = <0>;
168
169 dsa,ethernet = <&eth1>;
170 dsa,mii-bus = <&mdio>;
171
172 switch@0 {
173 #address-cells = <1>;
174 #size-cells = <0>;
175 reg = <0x10 0>; /* MDIO address 16, switch 0 in tree */
176
177 port@0 {
178 reg = <0>;
179 label = "lan0";
180 };
181
182 port@1 {
183 reg = <1>;
184 label = "lan1";
185 };
186
187 port@2 {
188 reg = <2>;
189 label = "lan2";
190 };
191
192 port@3 {
193 reg = <3>;
194 label = "lan3";
195 };
196
197 port@5 {
198 reg = <5>;
199 label = "cpu";
200 };
201 };
202 };
176 }; 203 };
204
205&pinctrl {
206 fan_pins: fan-pins {
207 marvell,pins = "mpp8";
208 marvell,function = "gpio";
209 };
210
211 led_pins: led-pins {
212 marvell,pins = "mpp32";
213 marvell,function = "gpio";
214 };
215};
diff --git a/arch/arm/boot/dts/armada-370-synology-ds213j.dts b/arch/arm/boot/dts/armada-370-synology-ds213j.dts
new file mode 100644
index 000000000000..70fecde76ccb
--- /dev/null
+++ b/arch/arm/boot/dts/armada-370-synology-ds213j.dts
@@ -0,0 +1,316 @@
1/*
2 * Device Tree file for Synology DS213j
3 *
4 * Copyright (C) 2014, Arnaud EBALARD <arno@natisbad.org>
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version
9 * 2 of the License, or (at your option) any later version.
10 *
11 * Note: this Device Tree assumes that the bootloader has remapped the
12 * internal registers to 0xf1000000 (instead of the old 0xd0000000).
13 * The 0xf1000000 is the default used by the recent, DT-capable, U-Boot
14 * bootloaders provided by Marvell. It is used in recent versions of
15 * DSM software provided by Synology. Nonetheless, some earlier boards
16 * were delivered with an older version of u-boot that left internal
17 * registers mapped at 0xd0000000. If you have such a device you will
18 * not be able to directly boot a kernel based on this Device Tree. In
19 * that case, the preferred solution is to update your bootloader (e.g.
20 * by upgrading to latest version of DSM, or building a new one and
21 * installing it from u-boot prompt) or adjust the Devive Tree
22 * (s/0xf1000000/0xd0000000/ in 'ranges' below).
23 */
24
25/dts-v1/;
26
27#include <dt-bindings/input/input.h>
28#include <dt-bindings/gpio/gpio.h>
29#include "armada-370.dtsi"
30
31/ {
32 model = "Synology DS213j";
33 compatible = "synology,ds213j", "marvell,armada370",
34 "marvell,armada-370-xp";
35
36 chosen {
37 bootargs = "console=ttyS0,115200 earlyprintk";
38 stdout-path = &uart0;
39 };
40
41 memory {
42 device_type = "memory";
43 reg = <0x00000000 0x20000000>; /* 512 MB */
44 };
45
46 soc {
47 ranges = <MBUS_ID(0xf0, 0x01) 0 0xf1000000 0x100000
48 MBUS_ID(0x01, 0xe0) 0 0xfff00000 0x100000>;
49
50 internal-regs {
51
52 /* RTC provided by Seiko S-35390A I2C RTC chip below */
53 rtc@10300 {
54 status = "disabled";
55 };
56
57 spi0: spi@10600 {
58 status = "okay";
59
60 spi-flash@0 {
61 #address-cells = <1>;
62 #size-cells = <1>;
63 compatible = "micron,n25q064";
64 reg = <0>; /* Chip select 0 */
65 spi-max-frequency = <20000000>;
66
67 /*
68 * Warning!
69 *
70 * Synology u-boot uses its compiled-in environment
71 * and it seems Synology did not care to change u-boot
72 * default configuration in order to allow saving a
73 * modified environment at a sensible location. So,
74 * if you do a 'saveenv' under u-boot, your modified
75 * environment will be saved at 1MB after the start
76 * of the flash, i.e. in the middle of the uImage.
77 * For that reason, it is strongly advised not to
78 * change the default environment, unless you know
79 * what you are doing.
80 */
81 partition@00000000 { /* u-boot */
82 label = "RedBoot";
83 reg = <0x00000000 0x000c0000>; /* 768KB */
84 };
85
86 partition@000c0000 { /* uImage */
87 label = "zImage";
88 reg = <0x000c0000 0x002d0000>; /* 2880KB */
89 };
90
91 partition@00390000 { /* uInitramfs */
92 label = "rd.gz";
93 reg = <0x00390000 0x00440000>; /* 4250KB */
94 };
95
96 partition@007d0000 { /* MAC address and serial number */
97 label = "vendor";
98 reg = <0x007d0000 0x00010000>; /* 64KB */
99 };
100
101 partition@007e0000 {
102 label = "RedBoot config";
103 reg = <0x007e0000 0x00010000>; /* 64KB */
104 };
105
106 partition@007f0000 {
107 label = "FIS directory";
108 reg = <0x007f0000 0x00010000>; /* 64KB */
109 };
110 };
111 };
112
113 i2c@11000 {
114 compatible = "marvell,mv64xxx-i2c";
115 pinctrl-0 = <&i2c0_pins>;
116 pinctrl-names = "default";
117 clock-frequency = <400000>;
118 status = "okay";
119
120 /* Main device RTC chip */
121 s35390a: s35390a@30 {
122 compatible = "sii,s35390a";
123 reg = <0x30>;
124 };
125 };
126
127 /* Connected to a header on device's PCB */
128 serial@12000 {
129 status = "okay";
130 };
131
132 /* Connected to a TI MSP430F2111 for power control */
133 serial@12100 {
134 status = "okay";
135 };
136
137 poweroff@12100 {
138 compatible = "synology,power-off";
139 reg = <0x12100 0x100>;
140 clocks = <&coreclk 0>;
141 };
142
143 /* rear USB port, near reset button */
144 usb@50000 {
145 status = "okay";
146 };
147
148 /* rear USB port, near RJ45 port */
149 usb@51000 {
150 status = "okay";
151 };
152
153 mdio {
154 phy1: ethernet-phy@1 { /* Marvell 88E1512 */
155 reg = <1>;
156 };
157 };
158
159 ethernet@70000 {
160 status = "okay";
161 phy = <&phy1>;
162 phy-mode = "sgmii";
163 };
164
165 sata@a0000 {
166 nr-ports = <2>;
167 status = "okay";
168 };
169 };
170 };
171
172 gpio-fan-32-38 {
173 status = "okay";
174 compatible = "gpio-fan";
175 pinctrl-0 = <&fan_ctrl_low_pin &fan_ctrl_mid_pin
176 &fan_ctrl_high_pin &fan_alarm_pin>;
177 pinctrl-names = "default";
178 gpios = <&gpio1 31 GPIO_ACTIVE_HIGH
179 &gpio2 0 GPIO_ACTIVE_HIGH
180 &gpio2 1 GPIO_ACTIVE_HIGH>;
181 alarm-gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>;
182 gpio-fan,speed-map = < 0 0
183 1000 1
184 1150 2
185 1350 4
186 1500 3
187 1650 5
188 1750 6
189 1900 7 >;
190 };
191
192 gpio-leds {
193 compatible = "gpio-leds";
194 pinctrl-0 = <&disk1_led_pin
195 &disk2_led_pin>;
196 pinctrl-names = "default";
197
198 disk1-led-amber {
199 label = "synology:amber:disk1";
200 gpios = <&gpio0 31 GPIO_ACTIVE_LOW>;
201 default-state = "keep";
202 };
203
204 disk2-led-amber {
205 label = "synology:amber:disk2";
206 gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
207 default-state = "keep";
208 };
209 };
210
211 regulators {
212 compatible = "simple-bus";
213 #address-cells = <1>;
214 #size-cells = <0>;
215 pinctrl-0 = <&sata1_pwr_pin &sata2_pwr_pin>;
216 pinctrl-names = "default";
217
218 sata1_regulator: sata1-regulator {
219 compatible = "regulator-fixed";
220 reg = <1>;
221 regulator-name = "SATA1 Power";
222 regulator-min-microvolt = <5000000>;
223 regulator-max-microvolt = <5000000>;
224 startup-delay-us = <2000000>;
225 enable-active-high;
226 regulator-always-on;
227 regulator-boot-on;
228 gpio = <&gpio1 5 GPIO_ACTIVE_HIGH>;
229 };
230
231 sata2_regulator: sata2-regulator {
232 compatible = "regulator-fixed";
233 reg = <2>;
234 regulator-name = "SATA2 Power";
235 regulator-min-microvolt = <5000000>;
236 regulator-max-microvolt = <5000000>;
237 startup-delay-us = <4000000>;
238 enable-active-high;
239 regulator-always-on;
240 regulator-boot-on;
241 gpio = <&gpio1 30 GPIO_ACTIVE_HIGH>;
242 };
243 };
244};
245
246&pinctrl {
247 disk1_led_pin: disk1-led-pin {
248 marvell,pins = "mpp31";
249 marvell,function = "gpio";
250 };
251
252 disk2_led_pin: disk2-led-pin {
253 marvell,pins = "mpp32";
254 marvell,function = "gpio";
255 };
256
257 sata1_pwr_pin: sata1-pwr-pin {
258 marvell,pins = "mpp37";
259 marvell,function = "gpio";
260 };
261
262 sata2_pwr_pin: sata2-pwr-pin {
263 marvell,pins = "mpp62";
264 marvell,function = "gpio";
265 };
266
267 sata1_pres_pin: sata1-pres-pin {
268 marvell,pins = "mpp60";
269 marvell,function = "gpio";
270 };
271
272 sata2_pres_pin: sata2-pres-pin {
273 marvell,pins = "mpp48";
274 marvell,function = "gpio";
275 };
276
277 syno_id_bit0_pin: syno-id-bit0-pin {
278 marvell,pins = "mpp55";
279 marvell,function = "gpio";
280 };
281
282 syno_id_bit1_pin: syno-id-bit1-pin {
283 marvell,pins = "mpp56";
284 marvell,function = "gpio";
285 };
286
287 syno_id_bit2_pin: syno-id-bit2-pin {
288 marvell,pins = "mpp57";
289 marvell,function = "gpio";
290 };
291
292 syno_id_bit3_pin: syno-id-bit3-pin {
293 marvell,pins = "mpp58";
294 marvell,function = "gpio";
295 };
296
297 fan_ctrl_low_pin: fan-ctrl-low-pin {
298 marvell,pins = "mpp65";
299 marvell,function = "gpio";
300 };
301
302 fan_ctrl_mid_pin: fan-ctrl-mid-pin {
303 marvell,pins = "mpp64";
304 marvell,function = "gpio";
305 };
306
307 fan_ctrl_high_pin: fan-ctrl-high-pin {
308 marvell,pins = "mpp63";
309 marvell,function = "gpo";
310 };
311
312 fan_alarm_pin: fan-alarm-pin {
313 marvell,pins = "mpp38";
314 marvell,function = "gpio";
315 };
316};
diff --git a/arch/arm/boot/dts/armada-370-xp.dtsi b/arch/arm/boot/dts/armada-370-xp.dtsi
index 83286ec9702c..83c31c86dd09 100644
--- a/arch/arm/boot/dts/armada-370-xp.dtsi
+++ b/arch/arm/boot/dts/armada-370-xp.dtsi
@@ -151,7 +151,7 @@
151 status = "disabled"; 151 status = "disabled";
152 }; 152 };
153 153
154 serial@12000 { 154 uart0: serial@12000 {
155 compatible = "snps,dw-apb-uart"; 155 compatible = "snps,dw-apb-uart";
156 reg = <0x12000 0x100>; 156 reg = <0x12000 0x100>;
157 reg-shift = <2>; 157 reg-shift = <2>;
@@ -160,7 +160,8 @@
160 clocks = <&coreclk 0>; 160 clocks = <&coreclk 0>;
161 status = "disabled"; 161 status = "disabled";
162 }; 162 };
163 serial@12100 { 163
164 uart1: serial@12100 {
164 compatible = "snps,dw-apb-uart"; 165 compatible = "snps,dw-apb-uart";
165 reg = <0x12100 0x100>; 166 reg = <0x12100 0x100>;
166 reg-shift = <2>; 167 reg-shift = <2>;
@@ -170,6 +171,10 @@
170 status = "disabled"; 171 status = "disabled";
171 }; 172 };
172 173
174 pinctrl: pin-ctrl@18000 {
175 reg = <0x18000 0x38>;
176 };
177
173 coredivclk: corediv-clock@18740 { 178 coredivclk: corediv-clock@18740 {
174 compatible = "marvell,armada-370-corediv-clock"; 179 compatible = "marvell,armada-370-corediv-clock";
175 reg = <0x18740 0xc>; 180 reg = <0x18740 0xc>;
@@ -232,7 +237,7 @@
232 status = "disabled"; 237 status = "disabled";
233 }; 238 };
234 239
235 mdio { 240 mdio: mdio {
236 #address-cells = <1>; 241 #address-cells = <1>;
237 #size-cells = <0>; 242 #size-cells = <0>;
238 compatible = "marvell,orion-mdio"; 243 compatible = "marvell,orion-mdio";
diff --git a/arch/arm/boot/dts/armada-370.dtsi b/arch/arm/boot/dts/armada-370.dtsi
index 7851942e244a..fdb3c12a6139 100644
--- a/arch/arm/boot/dts/armada-370.dtsi
+++ b/arch/arm/boot/dts/armada-370.dtsi
@@ -99,78 +99,26 @@
99 wt-override; 99 wt-override;
100 }; 100 };
101 101
102 i2c0: i2c@11000 { 102 /*
103 reg = <0x11000 0x20>; 103 * Default SPI pinctrl setting, can be overwritten on
104 * board level if a different configuration is used.
105 */
106 spi0: spi@10600 {
107 pinctrl-0 = <&spi0_pins1>;
108 pinctrl-names = "default";
104 }; 109 };
105 110
106 i2c1: i2c@11100 { 111 spi1: spi@10680 {
107 reg = <0x11100 0x20>; 112 pinctrl-0 = <&spi1_pins>;
113 pinctrl-names = "default";
108 }; 114 };
109 115
110 system-controller@18200 { 116 i2c0: i2c@11000 {
111 compatible = "marvell,armada-370-xp-system-controller"; 117 reg = <0x11000 0x20>;
112 reg = <0x18200 0x100>;
113 }; 118 };
114 119
115 pinctrl { 120 i2c1: i2c@11100 {
116 compatible = "marvell,mv88f6710-pinctrl"; 121 reg = <0x11100 0x20>;
117 reg = <0x18000 0x38>;
118
119 sdio_pins1: sdio-pins1 {
120 marvell,pins = "mpp9", "mpp11", "mpp12",
121 "mpp13", "mpp14", "mpp15";
122 marvell,function = "sd0";
123 };
124
125 sdio_pins2: sdio-pins2 {
126 marvell,pins = "mpp47", "mpp48", "mpp49",
127 "mpp50", "mpp51", "mpp52";
128 marvell,function = "sd0";
129 };
130
131 sdio_pins3: sdio-pins3 {
132 marvell,pins = "mpp48", "mpp49", "mpp50",
133 "mpp51", "mpp52", "mpp53";
134 marvell,function = "sd0";
135 };
136
137 i2c0_pins: i2c0-pins {
138 marvell,pins = "mpp2", "mpp3";
139 marvell,function = "i2c0";
140 };
141
142 i2s_pins1: i2s-pins1 {
143 marvell,pins = "mpp5", "mpp6", "mpp7",
144 "mpp8", "mpp9", "mpp10",
145 "mpp12", "mpp13";
146 marvell,function = "audio";
147 };
148
149 i2s_pins2: i2s-pins2 {
150 marvell,pins = "mpp49", "mpp47", "mpp50",
151 "mpp59", "mpp57", "mpp61",
152 "mpp62", "mpp60", "mpp58";
153 marvell,function = "audio";
154 };
155
156 mdio_pins: mdio-pins {
157 marvell,pins = "mpp17", "mpp18";
158 marvell,function = "ge";
159 };
160
161 ge0_rgmii_pins: ge0-rgmii-pins {
162 marvell,pins = "mpp5", "mpp6", "mpp7", "mpp8",
163 "mpp9", "mpp10", "mpp11", "mpp12",
164 "mpp13", "mpp14", "mpp15", "mpp16";
165 marvell,function = "ge0";
166 };
167
168 ge1_rgmii_pins: ge1-rgmii-pins {
169 marvell,pins = "mpp19", "mpp20", "mpp21", "mpp22",
170 "mpp23", "mpp24", "mpp25", "mpp26",
171 "mpp27", "mpp28", "mpp29", "mpp30";
172 marvell,function = "ge1";
173 };
174 }; 122 };
175 123
176 gpio0: gpio@18100 { 124 gpio0: gpio@18100 {
@@ -206,6 +154,26 @@
206 interrupts = <91>; 154 interrupts = <91>;
207 }; 155 };
208 156
157 /*
158 * Default UART pinctrl setting without RTS/CTS, can
159 * be overwritten on board level if a different
160 * configuration is used.
161 */
162 uart0: serial@12000 {
163 pinctrl-0 = <&uart0_pins>;
164 pinctrl-names = "default";
165 };
166
167 uart1: serial@12100 {
168 pinctrl-0 = <&uart1_pins>;
169 pinctrl-names = "default";
170 };
171
172 system-controller@18200 {
173 compatible = "marvell,armada-370-xp-system-controller";
174 reg = <0x18200 0x100>;
175 };
176
209 gateclk: clock-gating-control@18220 { 177 gateclk: clock-gating-control@18220 {
210 compatible = "marvell,armada-370-gating-clock"; 178 compatible = "marvell,armada-370-gating-clock";
211 reg = <0x18220 0x4>; 179 reg = <0x18220 0x4>;
@@ -250,6 +218,7 @@
250 }; 218 };
251 219
252 audio_controller: audio-controller@30000 { 220 audio_controller: audio-controller@30000 {
221 #sound-dai-cells = <1>;
253 compatible = "marvell,armada370-audio"; 222 compatible = "marvell,armada370-audio";
254 reg = <0x30000 0x4000>; 223 reg = <0x30000 0x4000>;
255 interrupts = <93>; 224 interrupts = <93>;
@@ -306,3 +275,91 @@
306 }; 275 };
307 }; 276 };
308}; 277};
278
279&pinctrl {
280 compatible = "marvell,mv88f6710-pinctrl";
281
282 spi0_pins1: spi0-pins1 {
283 marvell,pins = "mpp33", "mpp34",
284 "mpp35", "mpp36";
285 marvell,function = "spi0";
286 };
287
288 spi0_pins2: spi0_pins2 {
289 marvell,pins = "mpp32", "mpp63",
290 "mpp64", "mpp65";
291 marvell,function = "spi0";
292 };
293
294 spi1_pins: spi1-pins {
295 marvell,pins = "mpp49", "mpp50",
296 "mpp51", "mpp52";
297 marvell,function = "spi1";
298 };
299
300 uart0_pins: uart0-pins {
301 marvell,pins = "mpp0", "mpp1";
302 marvell,function = "uart0";
303 };
304
305 uart1_pins: uart1-pins {
306 marvell,pins = "mpp41", "mpp42";
307 marvell,function = "uart1";
308 };
309
310 sdio_pins1: sdio-pins1 {
311 marvell,pins = "mpp9", "mpp11", "mpp12",
312 "mpp13", "mpp14", "mpp15";
313 marvell,function = "sd0";
314 };
315
316 sdio_pins2: sdio-pins2 {
317 marvell,pins = "mpp47", "mpp48", "mpp49",
318 "mpp50", "mpp51", "mpp52";
319 marvell,function = "sd0";
320 };
321
322 sdio_pins3: sdio-pins3 {
323 marvell,pins = "mpp48", "mpp49", "mpp50",
324 "mpp51", "mpp52", "mpp53";
325 marvell,function = "sd0";
326 };
327
328 i2c0_pins: i2c0-pins {
329 marvell,pins = "mpp2", "mpp3";
330 marvell,function = "i2c0";
331 };
332
333 i2s_pins1: i2s-pins1 {
334 marvell,pins = "mpp5", "mpp6", "mpp7",
335 "mpp8", "mpp9", "mpp10",
336 "mpp12", "mpp13";
337 marvell,function = "audio";
338 };
339
340 i2s_pins2: i2s-pins2 {
341 marvell,pins = "mpp49", "mpp47", "mpp50",
342 "mpp59", "mpp57", "mpp61",
343 "mpp62", "mpp60", "mpp58";
344 marvell,function = "audio";
345 };
346
347 mdio_pins: mdio-pins {
348 marvell,pins = "mpp17", "mpp18";
349 marvell,function = "ge";
350 };
351
352 ge0_rgmii_pins: ge0-rgmii-pins {
353 marvell,pins = "mpp5", "mpp6", "mpp7", "mpp8",
354 "mpp9", "mpp10", "mpp11", "mpp12",
355 "mpp13", "mpp14", "mpp15", "mpp16";
356 marvell,function = "ge0";
357 };
358
359 ge1_rgmii_pins: ge1-rgmii-pins {
360 marvell,pins = "mpp19", "mpp20", "mpp21", "mpp22",
361 "mpp23", "mpp24", "mpp25", "mpp26",
362 "mpp27", "mpp28", "mpp29", "mpp30";
363 marvell,function = "ge1";
364 };
365};
diff --git a/arch/arm/boot/dts/armada-375.dtsi b/arch/arm/boot/dts/armada-375.dtsi
index 9721e55384ce..50096d3427eb 100644
--- a/arch/arm/boot/dts/armada-375.dtsi
+++ b/arch/arm/boot/dts/armada-375.dtsi
@@ -14,6 +14,7 @@
14#include "skeleton.dtsi" 14#include "skeleton.dtsi"
15#include <dt-bindings/interrupt-controller/arm-gic.h> 15#include <dt-bindings/interrupt-controller/arm-gic.h>
16#include <dt-bindings/interrupt-controller/irq.h> 16#include <dt-bindings/interrupt-controller/irq.h>
17#include <dt-bindings/phy/phy.h>
17 18
18#define MBUS_ID(target,attributes) (((target) << 24) | ((attributes) << 16)) 19#define MBUS_ID(target,attributes) (((target) << 24) | ((attributes) << 16))
19 20
@@ -348,6 +349,12 @@
348 #clock-cells = <1>; 349 #clock-cells = <1>;
349 }; 350 };
350 351
352 usbcluster: usb-cluster@18400 {
353 compatible = "marvell,armada-375-usb-cluster";
354 reg = <0x18400 0x4>;
355 #phy-cells = <1>;
356 };
357
351 mbusc: mbus-controller@20000 { 358 mbusc: mbus-controller@20000 {
352 compatible = "marvell,mbus-controller"; 359 compatible = "marvell,mbus-controller";
353 reg = <0x20000 0x100>, <0x20180 0x20>; 360 reg = <0x20000 0x100>, <0x20180 0x20>;
@@ -398,6 +405,8 @@
398 reg = <0x50000 0x500>; 405 reg = <0x50000 0x500>;
399 interrupts = <GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>; 406 interrupts = <GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
400 clocks = <&gateclk 18>; 407 clocks = <&gateclk 18>;
408 phys = <&usbcluster PHY_TYPE_USB2>;
409 phy-names = "usb";
401 status = "disabled"; 410 status = "disabled";
402 }; 411 };
403 412
@@ -414,6 +423,8 @@
414 reg = <0x58000 0x20000>,<0x5b880 0x80>; 423 reg = <0x58000 0x20000>,<0x5b880 0x80>;
415 interrupts = <GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>; 424 interrupts = <GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>;
416 clocks = <&gateclk 16>; 425 clocks = <&gateclk 16>;
426 phys = <&usbcluster PHY_TYPE_USB3>;
427 phy-names = "usb";
417 status = "disabled"; 428 status = "disabled";
418 }; 429 };
419 430
diff --git a/arch/arm/boot/dts/armada-385-db.dts b/arch/arm/boot/dts/armada-385-db.dts
index 1af886f1e486..2aaa9d2ac284 100644
--- a/arch/arm/boot/dts/armada-385-db.dts
+++ b/arch/arm/boot/dts/armada-385-db.dts
@@ -116,11 +116,11 @@
116 }; 116 };
117 117
118 sdhci@d8000 { 118 sdhci@d8000 {
119 clock-frequency = <200000000>;
120 broken-cd; 119 broken-cd;
121 wp-inverted; 120 wp-inverted;
122 bus-width = <8>; 121 bus-width = <8>;
123 status = "okay"; 122 status = "okay";
123 no-1-8-v;
124 }; 124 };
125 125
126 usb3@f0000 { 126 usb3@f0000 {
diff --git a/arch/arm/boot/dts/armada-38x.dtsi b/arch/arm/boot/dts/armada-38x.dtsi
index 242d0ecc99f3..74391dace9e7 100644
--- a/arch/arm/boot/dts/armada-38x.dtsi
+++ b/arch/arm/boot/dts/armada-38x.dtsi
@@ -25,9 +25,9 @@
25 aliases { 25 aliases {
26 gpio0 = &gpio0; 26 gpio0 = &gpio0;
27 gpio1 = &gpio1; 27 gpio1 = &gpio1;
28 eth0 = &eth0; 28 ethernet0 = &eth0;
29 eth1 = &eth1; 29 ethernet1 = &eth1;
30 eth2 = &eth2; 30 ethernet2 = &eth2;
31 }; 31 };
32 32
33 soc { 33 soc {
diff --git a/arch/arm/boot/dts/armada-xp-axpwifiap.dts b/arch/arm/boot/dts/armada-xp-axpwifiap.dts
index 0e53fad111de..c9d25bdbe795 100644
--- a/arch/arm/boot/dts/armada-xp-axpwifiap.dts
+++ b/arch/arm/boot/dts/armada-xp-axpwifiap.dts
@@ -100,8 +100,6 @@
100 100
101 spi0: spi@10600 { 101 spi0: spi@10600 {
102 status = "okay"; 102 status = "okay";
103 pinctrl-0 = <&pmx_spi>;
104 pinctrl-names = "default";
105 103
106 spi-flash@0 { 104 spi-flash@0 {
107 #address-cells = <1>; 105 #address-cells = <1>;
@@ -138,11 +136,6 @@
138 marvell,function = "gpio"; 136 marvell,function = "gpio";
139 }; 137 };
140 138
141 pmx_spi: pmx-spi {
142 marvell,pins = "mpp36", "mpp37", "mpp38", "mpp39";
143 marvell,function = "spi";
144 };
145
146 pmx_phy_int: pmx-phy-int { 139 pmx_phy_int: pmx-phy-int {
147 marvell,pins = "mpp32"; 140 marvell,pins = "mpp32";
148 marvell,function = "gpio"; 141 marvell,function = "gpio";
diff --git a/arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts b/arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts
index aa5463c91924..088d8d2fe9eb 100644
--- a/arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts
+++ b/arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts
@@ -22,7 +22,7 @@
22 22
23 chosen { 23 chosen {
24 bootargs = "console=ttyS0,115200 earlyprintk"; 24 bootargs = "console=ttyS0,115200 earlyprintk";
25 stdout-path = "/soc/internal-regs/serial@12000"; 25 stdout-path = &uart0;
26 }; 26 };
27 27
28 memory { 28 memory {
diff --git a/arch/arm/boot/dts/armada-xp-synology-ds414.dts b/arch/arm/boot/dts/armada-xp-synology-ds414.dts
new file mode 100644
index 000000000000..ba5e94d27c21
--- /dev/null
+++ b/arch/arm/boot/dts/armada-xp-synology-ds414.dts
@@ -0,0 +1,330 @@
1/*
2 * Device Tree file for Synology DS414
3 *
4 * Copyright (C) 2014, Arnaud EBALARD <arno@natisbad.org>
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version
9 * 2 of the License, or (at your option) any later version.
10 *
11 * Note: this Device Tree assumes that the bootloader has remapped the
12 * internal registers to 0xf1000000 (instead of the old 0xd0000000).
13 * The 0xf1000000 is the default used by the recent, DT-capable, U-Boot
14 * bootloaders provided by Marvell. It is used in recent versions of
15 * DSM software provided by Synology. Nonetheless, some earlier boards
16 * were delivered with an older version of u-boot that left internal
17 * registers mapped at 0xd0000000. If you have such a device you will
18 * not be able to directly boot a kernel based on this Device Tree. In
19 * that case, the preferred solution is to update your bootloader (e.g.
20 * by upgrading to latest version of DSM, or building a new one and
21 * installing it from u-boot prompt) or adjust the Devive Tree
22 * (s/0xf1000000/0xd0000000/ in 'ranges' below).
23 */
24
25/dts-v1/;
26
27#include <dt-bindings/input/input.h>
28#include <dt-bindings/gpio/gpio.h>
29#include "armada-xp-mv78230.dtsi"
30
31/ {
32 model = "Synology DS414";
33 compatible = "synology,ds414", "marvell,armadaxp-mv78230",
34 "marvell,armadaxp", "marvell,armada-370-xp";
35
36 chosen {
37 bootargs = "console=ttyS0,115200 earlyprintk";
38 stdout-path = &uart0;
39 };
40
41 memory {
42 device_type = "memory";
43 reg = <0 0x00000000 0 0x40000000>; /* 1GB */
44 };
45
46 soc {
47 ranges = <MBUS_ID(0xf0, 0x01) 0 0 0xf1000000 0x100000
48 MBUS_ID(0x01, 0x1d) 0 0 0xfff00000 0x100000>;
49
50 pcie-controller {
51 status = "okay";
52
53 /*
54 * Connected to Marvell 88SX7042 SATA-II controller
55 * handling the four disks.
56 */
57 pcie@1,0 {
58 /* Port 0, Lane 0 */
59 status = "okay";
60 };
61
62 /*
63 * Connected to EtronTech EJ168A XHCI controller
64 * providing the two rear USB 3.0 ports.
65 */
66 pcie@5,0 {
67 /* Port 1, Lane 0 */
68 status = "okay";
69 };
70 };
71
72 internal-regs {
73
74 /* RTC is provided by Seiko S-35390A below */
75 rtc@10300 {
76 status = "disabled";
77 };
78
79 spi0: spi@10600 {
80 status = "okay";
81
82 spi-flash@0 {
83 #address-cells = <1>;
84 #size-cells = <1>;
85 compatible = "micron,n25q064";
86 reg = <0>; /* Chip select 0 */
87 spi-max-frequency = <20000000>;
88
89 /*
90 * Warning!
91 *
92 * Synology u-boot uses its compiled-in environment
93 * and it seems Synology did not care to change u-boot
94 * default configuration in order to allow saving a
95 * modified environment at a sensible location. So,
96 * if you do a 'saveenv' under u-boot, your modified
97 * environment will be saved at 1MB after the start
98 * of the flash, i.e. in the middle of the uImage.
99 * For that reason, it is strongly advised not to
100 * change the default environment, unless you know
101 * what you are doing.
102 */
103 partition@00000000 { /* u-boot */
104 label = "RedBoot";
105 reg = <0x00000000 0x000d0000>; /* 832KB */
106 };
107
108 partition@000c0000 { /* uImage */
109 label = "zImage";
110 reg = <0x000d0000 0x002d0000>; /* 2880KB */
111 };
112
113 partition@003a0000 { /* uInitramfs */
114 label = "rd.gz";
115 reg = <0x003a0000 0x00430000>; /* 4250KB */
116 };
117
118 partition@007d0000 { /* MAC address and serial number */
119 label = "vendor";
120 reg = <0x007d0000 0x00010000>; /* 64KB */
121 };
122
123 partition@007e0000 {
124 label = "RedBoot config";
125 reg = <0x007e0000 0x00010000>; /* 64KB */
126 };
127
128 partition@007f0000 {
129 label = "FIS directory";
130 reg = <0x007f0000 0x00010000>; /* 64KB */
131 };
132 };
133 };
134
135 i2c@11000 {
136 clock-frequency = <400000>;
137 status = "okay";
138
139 s35390a: s35390a@30 {
140 compatible = "sii,s35390a";
141 reg = <0x30>;
142 };
143 };
144
145 /* Connected to a header on device's PCB. This
146 * provides the main console for the device.
147 *
148 * Warning: the device may not boot with a 3.3V
149 * USB-serial converter connected when the power
150 * button is pressed. The converter needs to be
151 * connected a few seconds after pressing the
152 * power button. This is possibly due to UART0_TXD
153 * pin being sampled at reset (bit 0 of SAR).
154 */
155 serial@12000 {
156 status = "okay";
157 };
158
159 /* Connected to a Microchip PIC16F883 for power control */
160 serial@12100 {
161 status = "okay";
162 };
163
164 poweroff@12100 {
165 compatible = "synology,power-off";
166 reg = <0x12100 0x100>;
167 clocks = <&coreclk 0>;
168 };
169
170 /* Front USB 2.0 port */
171 usb@50000 {
172 status = "okay";
173 };
174
175 mdio {
176 phy0: ethernet-phy@0 { /* Marvell 88E1512 */
177 reg = <0>;
178 };
179
180 phy1: ethernet-phy@1 { /* Marvell 88E1512 */
181 reg = <1>;
182 };
183 };
184
185 ethernet@70000 {
186 status = "okay";
187 pinctrl-0 = <&pmx_ge0_rgmii>;
188 pinctrl-names = "default";
189 phy = <&phy1>;
190 phy-mode = "rgmii-id";
191 };
192
193 ethernet@74000 {
194 pinctrl-0 = <&pmx_ge1_rgmii>;
195 pinctrl-names = "default";
196 status = "okay";
197 phy = <&phy0>;
198 phy-mode = "rgmii-id";
199 };
200 };
201 };
202
203 regulators {
204 compatible = "simple-bus";
205 #address-cells = <1>;
206 #size-cells = <0>;
207 pinctrl-0 = <&sata1_pwr_pin &sata2_pwr_pin
208 &sata3_pwr_pin &sata4_pwr_pin>;
209 pinctrl-names = "default";
210
211 sata1_regulator: sata1-regulator {
212 compatible = "regulator-fixed";
213 reg = <1>;
214 regulator-name = "SATA1 Power";
215 regulator-min-microvolt = <5000000>;
216 regulator-max-microvolt = <5000000>;
217 startup-delay-us = <2000000>;
218 enable-active-high;
219 regulator-always-on;
220 regulator-boot-on;
221 gpio = <&gpio1 10 GPIO_ACTIVE_HIGH>;
222 };
223
224 sata2_regulator: sata2-regulator {
225 compatible = "regulator-fixed";
226 reg = <2>;
227 regulator-name = "SATA2 Power";
228 regulator-min-microvolt = <5000000>;
229 regulator-max-microvolt = <5000000>;
230 startup-delay-us = <4000000>;
231 enable-active-high;
232 regulator-always-on;
233 regulator-boot-on;
234 gpio = <&gpio1 12 GPIO_ACTIVE_HIGH>;
235 };
236
237 sata3_regulator: sata3-regulator {
238 compatible = "regulator-fixed";
239 reg = <3>;
240 regulator-name = "SATA3 Power";
241 regulator-min-microvolt = <5000000>;
242 regulator-max-microvolt = <5000000>;
243 startup-delay-us = <6000000>;
244 enable-active-high;
245 regulator-always-on;
246 regulator-boot-on;
247 gpio = <&gpio1 13 GPIO_ACTIVE_HIGH>;
248 };
249
250 sata4_regulator: sata4-regulator {
251 compatible = "regulator-fixed";
252 reg = <4>;
253 regulator-name = "SATA4 Power";
254 regulator-min-microvolt = <5000000>;
255 regulator-max-microvolt = <5000000>;
256 startup-delay-us = <8000000>;
257 enable-active-high;
258 regulator-always-on;
259 regulator-boot-on;
260 gpio = <&gpio1 14 GPIO_ACTIVE_HIGH>;
261 };
262 };
263};
264
265&pinctrl {
266 sata1_pwr_pin: sata1-pwr-pin {
267 marvell,pins = "mpp42";
268 marvell,function = "gpio";
269 };
270
271 sata2_pwr_pin: sata2-pwr-pin {
272 marvell,pins = "mpp44";
273 marvell,function = "gpio";
274 };
275
276 sata3_pwr_pin: sata3-pwr-pin {
277 marvell,pins = "mpp45";
278 marvell,function = "gpio";
279 };
280
281 sata4_pwr_pin: sata4-pwr-pin {
282 marvell,pins = "mpp46";
283 marvell,function = "gpio";
284 };
285
286 sata1_pres_pin: sata1-pres-pin {
287 marvell,pins = "mpp34";
288 marvell,function = "gpio";
289 };
290
291 sata2_pres_pin: sata2-pres-pin {
292 marvell,pins = "mpp35";
293 marvell,function = "gpio";
294 };
295
296 sata3_pres_pin: sata3-pres-pin {
297 marvell,pins = "mpp40";
298 marvell,function = "gpio";
299 };
300
301 sata4_pres_pin: sata4-pres-pin {
302 marvell,pins = "mpp41";
303 marvell,function = "gpio";
304 };
305
306 syno_id_bit0_pin: syno-id-bit0-pin {
307 marvell,pins = "mpp26";
308 marvell,function = "gpio";
309 };
310
311 pmx_syno_id_bit1: syno-id-bit1-pin {
312 marvell,pins = "mpp28";
313 marvell,function = "gpio";
314 };
315
316 pmx_syno_id_bit2: syno-id-bit2-pin {
317 marvell,pins = "mpp29";
318 marvell,function = "gpio";
319 };
320
321 pmx_fan1_alarm: fan1-alarm-pin {
322 marvell,pins = "mpp33";
323 marvell,function = "gpio";
324 };
325
326 fan2_alarm_pin: fan2-alarm-pin {
327 marvell,pins = "mpp32";
328 marvell,function = "gpio";
329 };
330};
diff --git a/arch/arm/boot/dts/armada-xp.dtsi b/arch/arm/boot/dts/armada-xp.dtsi
index a3919b644737..bdb36a05c039 100644
--- a/arch/arm/boot/dts/armada-xp.dtsi
+++ b/arch/arm/boot/dts/armada-xp.dtsi
@@ -43,6 +43,11 @@
43 wt-override; 43 wt-override;
44 }; 44 };
45 45
46 spi0: spi@10600 {
47 pinctrl-0 = <&spi0_pins>;
48 pinctrl-names = "default";
49 };
50
46 i2c0: i2c@11000 { 51 i2c0: i2c@11000 {
47 compatible = "marvell,mv78230-i2c", "marvell,mv64xxx-i2c"; 52 compatible = "marvell,mv78230-i2c", "marvell,mv64xxx-i2c";
48 reg = <0x11000 0x100>; 53 reg = <0x11000 0x100>;
@@ -53,8 +58,10 @@
53 reg = <0x11100 0x100>; 58 reg = <0x11100 0x100>;
54 }; 59 };
55 60
56 serial@12200 { 61 uart2: serial@12200 {
57 compatible = "snps,dw-apb-uart"; 62 compatible = "snps,dw-apb-uart";
63 pinctrl-0 = <&uart2_pins>;
64 pinctrl-names = "default";
58 reg = <0x12200 0x100>; 65 reg = <0x12200 0x100>;
59 reg-shift = <2>; 66 reg-shift = <2>;
60 interrupts = <43>; 67 interrupts = <43>;
@@ -62,8 +69,11 @@
62 clocks = <&coreclk 0>; 69 clocks = <&coreclk 0>;
63 status = "disabled"; 70 status = "disabled";
64 }; 71 };
65 serial@12300 { 72
73 uart3: serial@12300 {
66 compatible = "snps,dw-apb-uart"; 74 compatible = "snps,dw-apb-uart";
75 pinctrl-0 = <&uart3_pins>;
76 pinctrl-names = "default";
67 reg = <0x12300 0x100>; 77 reg = <0x12300 0x100>;
68 reg-shift = <2>; 78 reg-shift = <2>;
69 interrupts = <44>; 79 interrupts = <44>;
@@ -72,43 +82,6 @@
72 status = "disabled"; 82 status = "disabled";
73 }; 83 };
74 84
75 pinctrl: pin-ctrl@18000 {
76 reg = <0x18000 0x38>;
77
78 pmx_ge0_gmii: pmx-ge0-gmii {
79 marvell,pins =
80 "mpp0", "mpp1", "mpp2", "mpp3",
81 "mpp4", "mpp5", "mpp6", "mpp7",
82 "mpp8", "mpp9", "mpp10", "mpp11",
83 "mpp12", "mpp13", "mpp14", "mpp15",
84 "mpp16", "mpp17", "mpp18", "mpp19",
85 "mpp20", "mpp21", "mpp22", "mpp23";
86 marvell,function = "ge0";
87 };
88
89 pmx_ge0_rgmii: pmx-ge0-rgmii {
90 marvell,pins =
91 "mpp0", "mpp1", "mpp2", "mpp3",
92 "mpp4", "mpp5", "mpp6", "mpp7",
93 "mpp8", "mpp9", "mpp10", "mpp11";
94 marvell,function = "ge0";
95 };
96
97 pmx_ge1_rgmii: pmx-ge1-rgmii {
98 marvell,pins =
99 "mpp12", "mpp13", "mpp14", "mpp15",
100 "mpp16", "mpp17", "mpp18", "mpp19",
101 "mpp20", "mpp21", "mpp22", "mpp23";
102 marvell,function = "ge1";
103 };
104
105 sdio_pins: sdio-pins {
106 marvell,pins = "mpp30", "mpp31", "mpp32",
107 "mpp33", "mpp34", "mpp35";
108 marvell,function = "sd0";
109 };
110 };
111
112 system-controller@18200 { 85 system-controller@18200 {
113 compatible = "marvell,armada-370-xp-system-controller"; 86 compatible = "marvell,armada-370-xp-system-controller";
114 reg = <0x18200 0x500>; 87 reg = <0x18200 0x500>;
@@ -237,3 +210,54 @@
237 }; 210 };
238 }; 211 };
239}; 212};
213
214&pinctrl {
215 pmx_ge0_gmii: pmx-ge0-gmii {
216 marvell,pins =
217 "mpp0", "mpp1", "mpp2", "mpp3",
218 "mpp4", "mpp5", "mpp6", "mpp7",
219 "mpp8", "mpp9", "mpp10", "mpp11",
220 "mpp12", "mpp13", "mpp14", "mpp15",
221 "mpp16", "mpp17", "mpp18", "mpp19",
222 "mpp20", "mpp21", "mpp22", "mpp23";
223 marvell,function = "ge0";
224 };
225
226 pmx_ge0_rgmii: pmx-ge0-rgmii {
227 marvell,pins =
228 "mpp0", "mpp1", "mpp2", "mpp3",
229 "mpp4", "mpp5", "mpp6", "mpp7",
230 "mpp8", "mpp9", "mpp10", "mpp11";
231 marvell,function = "ge0";
232 };
233
234 pmx_ge1_rgmii: pmx-ge1-rgmii {
235 marvell,pins =
236 "mpp12", "mpp13", "mpp14", "mpp15",
237 "mpp16", "mpp17", "mpp18", "mpp19",
238 "mpp20", "mpp21", "mpp22", "mpp23";
239 marvell,function = "ge1";
240 };
241
242 sdio_pins: sdio-pins {
243 marvell,pins = "mpp30", "mpp31", "mpp32",
244 "mpp33", "mpp34", "mpp35";
245 marvell,function = "sd0";
246 };
247
248 spi0_pins: spi0-pins {
249 marvell,pins = "mpp36", "mpp37",
250 "mpp38", "mpp39";
251 marvell,function = "spi";
252 };
253
254 uart2_pins: uart2-pins {
255 marvell,pins = "mpp42", "mpp43";
256 marvell,function = "uart2";
257 };
258
259 uart3_pins: uart3-pins {
260 marvell,pins = "mpp44", "mpp45";
261 marvell,function = "uart3";
262 };
263};
diff --git a/arch/arm/boot/dts/kirkwood-synology.dtsi b/arch/arm/boot/dts/kirkwood-synology.dtsi
index 811e0971fc58..8be5b2e4626e 100644
--- a/arch/arm/boot/dts/kirkwood-synology.dtsi
+++ b/arch/arm/boot/dts/kirkwood-synology.dtsi
@@ -266,7 +266,7 @@
266 266
267 s35390a: s35390a@30 { 267 s35390a: s35390a@30 {
268 status = "disabled"; 268 status = "disabled";
269 compatible = "ssi,s35390a"; 269 compatible = "sii,s35390a";
270 reg = <0x30>; 270 reg = <0x30>;
271 }; 271 };
272 }; 272 };