blob: 5fbfe02964dc5a08c0da65ecf1bae7de18af359f [file] [log] [blame]
Arnaud Ebalard45e88152013-10-22 20:56:13 +02001/*
2 * Device Tree file for NETGEAR ReadyNAS 104
3 *
4 * Copyright (C) 2013, 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
12/dts-v1/;
13
Arnaud Ebalard96b09e32013-11-29 21:27:48 +010014#include <dt-bindings/input/input.h>
Arnaud Ebalard100a5fa2013-11-22 00:00:12 +010015#include <dt-bindings/gpio/gpio.h>
Arnaud Ebalard96b09e32013-11-29 21:27:48 +010016#include "armada-370.dtsi"
Arnaud Ebalard45e88152013-10-22 20:56:13 +020017
18/ {
19 model = "NETGEAR ReadyNAS 104";
20 compatible = "netgear,readynas-104", "marvell,armada370", "marvell,armada-370-xp";
21
22 chosen {
23 bootargs = "console=ttyS0,115200 earlyprintk";
24 };
25
26 memory {
27 device_type = "memory";
28 reg = <0x00000000 0x20000000>; /* 512 MB */
29 };
30
31 soc {
32 ranges = <MBUS_ID(0xf0, 0x01) 0 0xd0000000 0x100000
33 MBUS_ID(0x01, 0xe0) 0 0xfff00000 0x100000>;
34
35 pcie-controller {
36 status = "okay";
37
38 /* Connected to FL1009 USB 3.0 controller */
39 pcie@1,0 {
40 /* Port 0, Lane 0 */
41 status = "okay";
42 };
43
44 /* Connected to Marvell 88SE9215 SATA controller */
45 pcie@2,0 {
46 /* Port 1, Lane 0 */
47 status = "okay";
48 };
49 };
50
51 internal-regs {
52 serial@12000 {
Arnaud Ebalard45e88152013-10-22 20:56:13 +020053 status = "okay";
54 };
55
Arnaud Ebalard45e88152013-10-22 20:56:13 +020056 mdio {
Ezequiel Garciaa1451ab2014-08-11 09:14:40 -030057 pinctrl-0 = <&mdio_pins>;
58 pinctrl-names = "default";
Arnaud Ebalard96b09e32013-11-29 21:27:48 +010059 phy0: ethernet-phy@0 { /* Marvell 88E1318 */
Arnaud Ebalard45e88152013-10-22 20:56:13 +020060 reg = <0>;
61 };
62
Arnaud Ebalard96b09e32013-11-29 21:27:48 +010063 phy1: ethernet-phy@1 { /* Marvell 88E1318 */
Arnaud Ebalard45e88152013-10-22 20:56:13 +020064 reg = <1>;
65 };
66 };
67
68 ethernet@70000 {
Ezequiel Garciaa1451ab2014-08-11 09:14:40 -030069 pinctrl-0 = <&ge0_rgmii_pins>;
70 pinctrl-names = "default";
Arnaud Ebalard45e88152013-10-22 20:56:13 +020071 status = "okay";
72 phy = <&phy0>;
73 phy-mode = "rgmii-id";
74 };
75
76 ethernet@74000 {
Ezequiel Garciaa1451ab2014-08-11 09:14:40 -030077 pinctrl-0 = <&ge1_rgmii_pins>;
78 pinctrl-names = "default";
Arnaud Ebalard45e88152013-10-22 20:56:13 +020079 status = "okay";
80 phy = <&phy1>;
81 phy-mode = "rgmii-id";
82 };
83
84 usb@50000 {
85 status = "okay";
86 };
87
88 i2c@11000 {
89 compatible = "marvell,mv64xxx-i2c";
90 clock-frequency = <100000>;
91 status = "okay";
92
Arnaud Ebalardc0d1c262013-12-19 23:02:15 +010093 isl12057: isl12057@68 {
Philipp Zabel7a6540c2014-09-08 11:19:18 +020094 compatible = "isil,isl12057";
Arnaud Ebalardc0d1c262013-12-19 23:02:15 +010095 reg = <0x68>;
Arnaud Ebalard1a67e252015-02-13 14:40:39 -080096 isil,irq2-can-wakeup-machine;
Arnaud Ebalardc0d1c262013-12-19 23:02:15 +010097 };
98
Arnaud Ebalard45e88152013-10-22 20:56:13 +020099 g762: g762@3e {
100 compatible = "gmt,g762";
101 reg = <0x3e>;
102 clocks = <&g762_clk>; /* input clock */
103 fan_gear_mode = <0>;
104 fan_startv = <1>;
105 pwm_polarity = <0>;
106 };
Arnaud Ebalard100a5fa2013-11-22 00:00:12 +0100107
108 pca9554: pca9554@23 {
109 compatible = "nxp,pca9554";
110 gpio-controller;
111 #gpio-cells = <2>;
112 reg = <0x23>;
113 };
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200114 };
Arnaud Ebalard0373a552013-12-07 00:13:18 +0100115
116 nand@d0000 {
117 status = "okay";
118 num-cs = <1>;
119 marvell,nand-keep-config;
120 marvell,nand-enable-arbiter;
121 nand-on-flash-bbt;
122
Arnaud Ebalard225b94c2014-09-06 22:49:25 +0200123 /* Use Hardware BCH ECC */
124 nand-ecc-strength = <4>;
125 nand-ecc-step-size = <512>;
126
Arnaud Ebalard0373a552013-12-07 00:13:18 +0100127 partition@0 {
128 label = "u-boot";
129 reg = <0x0000000 0x180000>; /* 1.5MB */
130 read-only;
131 };
132
133 partition@180000 {
134 label = "u-boot-env";
135 reg = <0x180000 0x20000>; /* 128KB */
136 read-only;
137 };
138
139 partition@200000 {
140 label = "uImage";
141 reg = <0x0200000 0x600000>; /* 6MB */
142 };
143
144 partition@800000 {
145 label = "minirootfs";
146 reg = <0x0800000 0x400000>; /* 4MB */
147 };
148
149 /* Last MB is for the BBT, i.e. not writable */
150 partition@c00000 {
151 label = "ubifs";
152 reg = <0x0c00000 0x7400000>; /* 116MB */
153 };
154 };
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200155 };
156 };
157
158 clocks {
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100159 g762_clk: g762-oscillator {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200160 compatible = "fixed-clock";
161 #clock-cells = <0>;
162 clock-frequency = <8192>;
163 };
164 };
165
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100166 gpio-leds {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200167 compatible = "gpio-leds";
168 pinctrl-0 = <&backup_led_pin &power_led_pin>;
169 pinctrl-names = "default";
170
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100171 blue-backup-led {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200172 label = "rn104:blue:backup";
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100173 gpios = <&gpio1 31 GPIO_ACTIVE_HIGH>;
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200174 default-state = "off";
175 };
176
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100177 blue-power-led {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200178 label = "rn104:blue:pwr";
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100179 gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200180 linux,default-trigger = "keep";
181 };
Arnaud Ebalard100a5fa2013-11-22 00:00:12 +0100182
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100183 blue-sata1-led {
Arnaud Ebalard100a5fa2013-11-22 00:00:12 +0100184 label = "rn104:blue:sata1";
185 gpios = <&pca9554 0 GPIO_ACTIVE_LOW>;
186 default-state = "off";
187 };
188
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100189 blue-sata2-led {
Arnaud Ebalard100a5fa2013-11-22 00:00:12 +0100190 label = "rn104:blue:sata2";
191 gpios = <&pca9554 1 GPIO_ACTIVE_LOW>;
192 default-state = "off";
193 };
194
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100195 blue-sata3-led {
Arnaud Ebalard100a5fa2013-11-22 00:00:12 +0100196 label = "rn104:blue:sata3";
197 gpios = <&pca9554 2 GPIO_ACTIVE_LOW>;
198 default-state = "off";
199 };
200
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100201 blue-sata4-led {
Arnaud Ebalard100a5fa2013-11-22 00:00:12 +0100202 label = "rn104:blue:sata4";
203 gpios = <&pca9554 3 GPIO_ACTIVE_LOW>;
204 default-state = "off";
205 };
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200206 };
207
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100208 gpio-keys {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200209 compatible = "gpio-keys";
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100210 pinctrl-0 = <&backup_button_pin
211 &power_button_pin
212 &reset_button_pin>;
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200213 pinctrl-names = "default";
214
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100215 backup-button {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200216 label = "Backup Button";
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100217 linux,code = <KEY_COPY>;
218 gpios = <&gpio1 20 GPIO_ACTIVE_LOW>;
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200219 };
220
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100221 power-button {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200222 label = "Power Button";
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100223 linux,code = <KEY_POWER>;
224 gpios = <&gpio1 30 GPIO_ACTIVE_HIGH>;
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200225 };
226
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100227 reset-button {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200228 label = "Reset Button";
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100229 linux,code = <KEY_RESTART>;
230 gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200231 };
232 };
233
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100234 gpio-poweroff {
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200235 compatible = "gpio-poweroff";
236 pinctrl-0 = <&poweroff>;
237 pinctrl-names = "default";
Arnaud Ebalard96b09e32013-11-29 21:27:48 +0100238 gpios = <&gpio1 28 GPIO_ACTIVE_LOW>;
Arnaud Ebalard45e88152013-10-22 20:56:13 +0200239 };
240};
Arnaud Ebalard4904a822014-11-22 00:45:56 +0100241
242&pinctrl {
243 poweroff: poweroff {
244 marvell,pins = "mpp60";
245 marvell,function = "gpio";
246 };
247
248 backup_button_pin: backup-button-pin {
249 marvell,pins = "mpp52";
250 marvell,function = "gpio";
251 };
252
253 power_button_pin: power-button-pin {
254 marvell,pins = "mpp62";
255 marvell,function = "gpio";
256 };
257
258 backup_led_pin: backup-led-pin {
259 marvell,pins = "mpp63";
260 marvell,function = "gpo";
261 };
262
263 power_led_pin: power-led-pin {
264 marvell,pins = "mpp64";
265 marvell,function = "gpio";
266 };
267
268 reset_button_pin: reset-button-pin {
269 marvell,pins = "mpp65";
270 marvell,function = "gpio";
271 };
272};