aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/boot/dts/Makefile1
-rw-r--r--arch/arm/boot/dts/kirkwood-netgear_readynas_duo_v2.dts180
-rw-r--r--arch/arm/configs/kirkwood_defconfig1
-rw-r--r--arch/arm/mach-kirkwood/Kconfig9
-rw-r--r--arch/arm/mach-kirkwood/Makefile1
-rw-r--r--arch/arm/mach-kirkwood/board-dt.c4
-rw-r--r--arch/arm/mach-kirkwood/board-readynas.c28
-rw-r--r--arch/arm/mach-kirkwood/common.h6
8 files changed, 230 insertions, 0 deletions
diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 9c6255884cbb..125211d2aa36 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -65,6 +65,7 @@ dtb-$(CONFIG_ARCH_KIRKWOOD) += kirkwood-dns320.dtb \
65 kirkwood-lschlv2.dtb \ 65 kirkwood-lschlv2.dtb \
66 kirkwood-lsxhl.dtb \ 66 kirkwood-lsxhl.dtb \
67 kirkwood-mplcec4.dtb \ 67 kirkwood-mplcec4.dtb \
68 kirkwood-netgear_readynas_duo_v2.dtb \
68 kirkwood-ns2.dtb \ 69 kirkwood-ns2.dtb \
69 kirkwood-ns2lite.dtb \ 70 kirkwood-ns2lite.dtb \
70 kirkwood-ns2max.dtb \ 71 kirkwood-ns2max.dtb \
diff --git a/arch/arm/boot/dts/kirkwood-netgear_readynas_duo_v2.dts b/arch/arm/boot/dts/kirkwood-netgear_readynas_duo_v2.dts
new file mode 100644
index 000000000000..1ca66ab83ad6
--- /dev/null
+++ b/arch/arm/boot/dts/kirkwood-netgear_readynas_duo_v2.dts
@@ -0,0 +1,180 @@
1/dts-v1/;
2
3/include/ "kirkwood.dtsi"
4/include/ "kirkwood-6282.dtsi"
5
6/ {
7 model = "NETGEAR ReadyNAS Duo v2";
8 compatible = "netgear,readynas-duo-v2", "netgear,readynas", "marvell,kirkwood-88f6282", "marvell,kirkwood";
9
10 memory { /* 256 MB */
11 device_type = "memory";
12 reg = <0x00000000 0x10000000>;
13 };
14
15 chosen {
16 bootargs = "console=ttyS0,115200n8 earlyprintk";
17 };
18
19 ocp@f1000000 {
20 pinctrl: pinctrl@10000 {
21
22 pinctrl-0 = < &pmx_uart0
23 &pmx_button_power
24 &pmx_button_backup
25 &pmx_button_reset
26 &pmx_led_blue_power
27 &pmx_led_blue_activity
28 &pmx_led_blue_disk1
29 &pmx_led_blue_disk2
30 &pmx_led_blue_backup >;
31 pinctrl-names = "default";
32
33 pmx_button_power: pmx-button-power {
34 marvell,pins = "mpp47";
35 marvell,function = "gpio";
36 };
37 pmx_button_backup: pmx-button-backup {
38 marvell,pins = "mpp45";
39 marvell,function = "gpio";
40 };
41 pmx_button_reset: pmx-button-reset {
42 marvell,pins = "mpp13";
43 marvell,function = "gpio";
44 };
45 pmx_led_blue_power: pmx-led-blue-power {
46 marvell,pins = "mpp31";
47 marvell,function = "gpio";
48 };
49 pmx_led_blue_activity: pmx-led-blue-activity {
50 marvell,pins = "mpp38";
51 marvell,function = "gpio";
52 };
53 pmx_led_blue_disk1: pmx-led-blue-disk1 {
54 marvell,pins = "mpp23";
55 marvell,function = "gpio";
56 };
57 pmx_led_blue_disk2: pmx-led-blue-disk2 {
58 marvell,pins = "mpp22";
59 marvell,function = "gpio";
60 };
61 pmx_led_blue_backup: pmx-led-blue-backup {
62 marvell,pins = "mpp29";
63 marvell,function = "gpio";
64 };
65 };
66
67 i2c@11000 {
68 status = "okay";
69
70 rs5c372a: rs5c372a@32 {
71 compatible = "ricoh,rs5c372a";
72 reg = <0x32>;
73 };
74 };
75
76 serial@12000 {
77 status = "okay";
78 };
79
80 nand@3000000 {
81 status = "okay";
82
83 partition@0 {
84 label = "u-boot";
85 reg = <0x0000000 0x180000>;
86 read-only;
87 };
88
89 partition@180000 {
90 label = "u-boot-env";
91 reg = <0x180000 0x20000>;
92 };
93
94 partition@200000 {
95 label = "uImage";
96 reg = <0x0200000 0x600000>;
97 };
98
99 partition@800000 {
100 label = "minirootfs";
101 reg = <0x0800000 0x1000000>;
102 };
103
104 partition@1800000 {
105 label = "jffs2";
106 reg = <0x1800000 0x6800000>;
107 };
108 };
109
110 sata@80000 {
111 status = "okay";
112 nr-ports = <2>;
113 };
114 };
115
116 gpio-leds {
117 compatible = "gpio-leds";
118
119 power_led {
120 label = "status:blue:power_led";
121 gpios = <&gpio0 31 1>; /* GPIO 31 Active Low */
122 linux,default-trigger = "default-on";
123 };
124 activity_led {
125 label = "status:blue:activity_led";
126 gpios = <&gpio1 6 1>; /* GPIO 38 Active Low */
127 };
128 disk1_led {
129 label = "status:blue:disk1_led";
130 gpios = <&gpio0 23 1>; /* GPIO 23 Active Low */
131 };
132 disk2_led {
133 label = "status:blue:disk2_led";
134 gpios = <&gpio0 22 1>; /* GPIO 22 Active Low */
135 };
136 backup_led {
137 label = "status:blue:backup_led";
138 gpios = <&gpio0 29 1>; /* GPIO 29 Active Low*/
139 };
140 };
141
142 gpio_keys {
143 compatible = "gpio-keys";
144 #address-cells = <1>;
145 #size-cells = <0>;
146 button@1 {
147 label = "Power Button";
148 linux,code = <116>; /* KEY_POWER */
149 gpios = <&gpio1 15 1>;
150 };
151 button@2 {
152 label = "Reset Button";
153 linux,code = <0x198>; /* KEY_RESTART */
154 gpios = <&gpio0 13 1>;
155 };
156 button@3 {
157 label = "Backup Button";
158 linux,code = <133>; /* KEY_COPY */
159 gpios = <&gpio1 13 1>;
160 };
161 };
162
163 regulators {
164 compatible = "simple-bus";
165 #address-cells = <1>;
166 #size-cells = <0>;
167
168 usb_power: regulator@1 {
169 compatible = "regulator-fixed";
170 reg = <1>;
171 regulator-name = "USB 3.0 Power";
172 regulator-min-microvolt = <5000000>;
173 regulator-max-microvolt = <5000000>;
174 enable-active-high;
175 regulator-always-on;
176 regulator-boot-on;
177 gpio = <&gpio1 14 0>;
178 };
179 };
180};
diff --git a/arch/arm/configs/kirkwood_defconfig b/arch/arm/configs/kirkwood_defconfig
index 13482ea58b09..9eb9f48d92bb 100644
--- a/arch/arm/configs/kirkwood_defconfig
+++ b/arch/arm/configs/kirkwood_defconfig
@@ -34,6 +34,7 @@ CONFIG_MACH_NETSPACE_MAX_V2_DT=y
34CONFIG_MACH_NETSPACE_LITE_V2_DT=y 34CONFIG_MACH_NETSPACE_LITE_V2_DT=y
35CONFIG_MACH_NETSPACE_MINI_V2_DT=y 35CONFIG_MACH_NETSPACE_MINI_V2_DT=y
36CONFIG_MACH_OPENBLOCKS_A6_DT=y 36CONFIG_MACH_OPENBLOCKS_A6_DT=y
37CONFIG_MACH_READYNAS_DT=y
37CONFIG_MACH_TOPKICK_DT=y 38CONFIG_MACH_TOPKICK_DT=y
38CONFIG_MACH_TS219=y 39CONFIG_MACH_TS219=y
39CONFIG_MACH_TS41X=y 40CONFIG_MACH_TS41X=y
diff --git a/arch/arm/mach-kirkwood/Kconfig b/arch/arm/mach-kirkwood/Kconfig
index 7b6a64bc5f40..3fd07ebcb126 100644
--- a/arch/arm/mach-kirkwood/Kconfig
+++ b/arch/arm/mach-kirkwood/Kconfig
@@ -194,6 +194,15 @@ config MACH_OPENBLOCKS_A6_DT
194 Say 'Y' here if you want your kernel to support the 194 Say 'Y' here if you want your kernel to support the
195 Plat'Home OpenBlocks A6 (Flattened Device Tree). 195 Plat'Home OpenBlocks A6 (Flattened Device Tree).
196 196
197config MACH_READYNAS_DT
198 bool "NETGEAR ReadyNAS Duo v2 (Flattened Device Tree)"
199 select ARCH_KIRKWOOD_DT
200 select ARM_APPENDED_DTB
201 select ARM_ATAG_DTB_COMPAT
202 help
203 Say 'Y' here if you want your kernel to support the
204 NETGEAR ReadyNAS Duo v2 using Fattened Device Tree.
205
197config MACH_TOPKICK_DT 206config MACH_TOPKICK_DT
198 bool "USI Topkick (Flattened Device Tree)" 207 bool "USI Topkick (Flattened Device Tree)"
199 select ARCH_KIRKWOOD_DT 208 select ARCH_KIRKWOOD_DT
diff --git a/arch/arm/mach-kirkwood/Makefile b/arch/arm/mach-kirkwood/Makefile
index 4cc4bee4d0cf..ff0f3cb7b4e3 100644
--- a/arch/arm/mach-kirkwood/Makefile
+++ b/arch/arm/mach-kirkwood/Makefile
@@ -39,4 +39,5 @@ obj-$(CONFIG_MACH_NETSPACE_LITE_V2_DT) += board-ns2.o
39obj-$(CONFIG_MACH_NETSPACE_MINI_V2_DT) += board-ns2.o 39obj-$(CONFIG_MACH_NETSPACE_MINI_V2_DT) += board-ns2.o
40obj-$(CONFIG_MACH_NSA310_DT) += board-nsa310.o 40obj-$(CONFIG_MACH_NSA310_DT) += board-nsa310.o
41obj-$(CONFIG_MACH_OPENBLOCKS_A6_DT) += board-openblocks_a6.o 41obj-$(CONFIG_MACH_OPENBLOCKS_A6_DT) += board-openblocks_a6.o
42obj-$(CONFIG_MACH_READYNAS_DT) += board-readynas.o
42obj-$(CONFIG_MACH_TOPKICK_DT) += board-usi_topkick.o 43obj-$(CONFIG_MACH_TOPKICK_DT) += board-usi_topkick.o
diff --git a/arch/arm/mach-kirkwood/board-dt.c b/arch/arm/mach-kirkwood/board-dt.c
index d367aa6b47bb..e5a3cfec3d62 100644
--- a/arch/arm/mach-kirkwood/board-dt.c
+++ b/arch/arm/mach-kirkwood/board-dt.c
@@ -149,6 +149,9 @@ static void __init kirkwood_dt_init(void)
149 if (of_machine_is_compatible("mpl,cec4")) 149 if (of_machine_is_compatible("mpl,cec4"))
150 mplcec4_init(); 150 mplcec4_init();
151 151
152 if (of_machine_is_compatible("netgear,readynas-duo-v2"))
153 netgear_readynas_init();
154
152 if (of_machine_is_compatible("plathome,openblocks-a6")) 155 if (of_machine_is_compatible("plathome,openblocks-a6"))
153 openblocks_a6_init(); 156 openblocks_a6_init();
154 157
@@ -177,6 +180,7 @@ static const char * const kirkwood_dt_board_compat[] = {
177 "lacie,netspace_lite_v2", 180 "lacie,netspace_lite_v2",
178 "lacie,netspace_mini_v2", 181 "lacie,netspace_mini_v2",
179 "mpl,cec4", 182 "mpl,cec4",
183 "netgear,readynas-duo-v2",
180 "plathome,openblocks-a6", 184 "plathome,openblocks-a6",
181 "usi,topkick", 185 "usi,topkick",
182 "zyxel,nsa310", 186 "zyxel,nsa310",
diff --git a/arch/arm/mach-kirkwood/board-readynas.c b/arch/arm/mach-kirkwood/board-readynas.c
new file mode 100644
index 000000000000..fb42c20e273f
--- /dev/null
+++ b/arch/arm/mach-kirkwood/board-readynas.c
@@ -0,0 +1,28 @@
1/*
2 * NETGEAR ReadyNAS Duo v2 Board setup for drivers not already
3 * converted to DT.
4 *
5 * Copyright (C) 2013, Arnaud EBALARD <arno@natisbad.org>
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#include <linux/kernel.h>
14#include <linux/init.h>
15#include <linux/platform_device.h>
16#include <linux/mv643xx_eth.h>
17#include <mach/kirkwood.h>
18#include "common.h"
19
20static struct mv643xx_eth_platform_data netgear_readynas_ge00_data = {
21 .phy_addr = MV643XX_ETH_PHY_ADDR(0),
22};
23
24void __init netgear_readynas_init(void)
25{
26 kirkwood_ge00_init(&netgear_readynas_ge00_data);
27 kirkwood_pcie_init(KW_PCIE0);
28}
diff --git a/arch/arm/mach-kirkwood/common.h b/arch/arm/mach-kirkwood/common.h
index 5ed70565c843..7ee8670eb944 100644
--- a/arch/arm/mach-kirkwood/common.h
+++ b/arch/arm/mach-kirkwood/common.h
@@ -141,6 +141,12 @@ void openblocks_a6_init(void);
141static inline void openblocks_a6_init(void) {}; 141static inline void openblocks_a6_init(void) {};
142#endif 142#endif
143 143
144#ifdef CONFIG_MACH_READYNAS_DT
145void netgear_readynas_init(void);
146#else
147static inline void netgear_readynas_init(void) {};
148#endif
149
144#ifdef CONFIG_MACH_TOPKICK_DT 150#ifdef CONFIG_MACH_TOPKICK_DT
145void usi_topkick_init(void); 151void usi_topkick_init(void);
146#else 152#else