21877f48c3e67aa4c53eadabdc2cf01de5e76751
[openwrt/svn-archive/archive.git] / target / linux / kirkwood / patches-3.10 / 0025-ARM-kirkwood-remove-redundant-DT-board-files.patch
1 From 3bfe255171bf03fa4b776e8e10b93d4dbd7df1e8 Mon Sep 17 00:00:00 2001
2 From: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
3 Date: Tue, 2 Jul 2013 13:00:22 +0200
4 Subject: [PATCH 25/29] ARM: kirkwood: remove redundant DT board files
5
6 With DT support for mv643xx_eth board specific init for some boards now
7 is unneccessary. Remove those board files, Kconfig entries, and
8 corresponding entries in kirkwood_defconfig.
9
10 Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
11 ---
12 arch/arm/mach-kirkwood/Kconfig | 148 --------------------------------
13 arch/arm/mach-kirkwood/Makefile | 22 +----
14 arch/arm/mach-kirkwood/board-dnskw.c | 7 --
15 arch/arm/mach-kirkwood/board-dt.c | 80 +----------------
16 arch/arm/mach-kirkwood/board-lsxl.c | 52 -----------
17 arch/arm/mach-kirkwood/board-readynas.c | 28 ------
18 6 files changed, 2 insertions(+), 335 deletions(-)
19 delete mode 100644 arch/arm/mach-kirkwood/board-lsxl.c
20 delete mode 100644 arch/arm/mach-kirkwood/board-readynas.c
21
22 diff --git a/arch/arm/mach-kirkwood/Kconfig b/arch/arm/mach-kirkwood/Kconfig
23 index b56bd3d..dc99588 100644
24 --- a/arch/arm/mach-kirkwood/Kconfig
25 +++ b/arch/arm/mach-kirkwood/Kconfig
26 @@ -140,20 +140,6 @@ config ARCH_KIRKWOOD_DT
27 Say 'Y' here if you want your kernel to support the
28 Marvell Kirkwood using flattened device tree.
29
30 -config MACH_CLOUDBOX_DT
31 - bool "LaCie CloudBox NAS (Flattened Device Tree)"
32 - select ARCH_KIRKWOOD_DT
33 - help
34 - Say 'Y' here if you want your kernel to support the LaCie
35 - CloudBox NAS, using Flattened Device Tree.
36 -
37 -config MACH_DB88F628X_BP_DT
38 - bool "Marvell DB-88F628x-BP Development Board (Flattened Device Tree)"
39 - help
40 - Say 'Y' here if you want your kernel to support the Marvell
41 - DB-88F6281-BP and DB-88F6282-BP Development Board (Flattened
42 - Device Tree).
43 -
44 config MACH_DLINK_KIRKWOOD_DT
45 bool "D-Link Kirkwood-based NAS (Flattened Device Tree)"
46 select ARCH_KIRKWOOD_DT
47 @@ -162,140 +148,6 @@ config MACH_DLINK_KIRKWOOD_DT
48 Kirkwood-based D-Link NASes such as DNS-320 & DNS-325,
49 using Flattened Device Tree.
50
51 -config MACH_DOCKSTAR_DT
52 - bool "Seagate FreeAgent Dockstar (Flattened Device Tree)"
53 - select ARCH_KIRKWOOD_DT
54 - help
55 - Say 'Y' here if you want your kernel to support the
56 - Seagate FreeAgent Dockstar (Flattened Device Tree).
57 -
58 -config MACH_DREAMPLUG_DT
59 - bool "Marvell DreamPlug (Flattened Device Tree)"
60 - select ARCH_KIRKWOOD_DT
61 - help
62 - Say 'Y' here if you want your kernel to support the
63 - Marvell DreamPlug (Flattened Device Tree).
64 -
65 -config MACH_GOFLEXNET_DT
66 - bool "Seagate GoFlex Net (Flattened Device Tree)"
67 - select ARCH_KIRKWOOD_DT
68 - help
69 - Say 'Y' here if you want your kernel to support the
70 - Seagate GoFlex Net (Flattened Device Tree).
71 -
72 -config MACH_GURUPLUG_DT
73 - bool "Marvell GuruPlug Reference Board (Flattened Device Tree)"
74 - select ARCH_KIRKWOOD_DT
75 - help
76 - Say 'Y' here if you want your kernel to support the
77 - Marvell GuruPlug Reference Board (Flattened Device Tree).
78 -
79 -config MACH_IB62X0_DT
80 - bool "RaidSonic IB-NAS6210, IB-NAS6220 (Flattened Device Tree)"
81 - select ARCH_KIRKWOOD_DT
82 - help
83 - Say 'Y' here if you want your kernel to support the
84 - RaidSonic IB-NAS6210 & IB-NAS6220 devices, using
85 - Flattened Device Tree.
86 -
87 -config MACH_ICONNECT_DT
88 - bool "Iomega Iconnect (Flattened Device Tree)"
89 - select ARCH_KIRKWOOD_DT
90 - help
91 - Say 'Y' here to enable Iomega Iconnect support.
92 -
93 -config MACH_INETSPACE_V2_DT
94 - bool "LaCie Internet Space v2 NAS (Flattened Device Tree)"
95 - select ARCH_KIRKWOOD_DT
96 - help
97 - Say 'Y' here if you want your kernel to support the LaCie
98 - Internet Space v2 NAS, using Flattened Device Tree.
99 -
100 -config MACH_IOMEGA_IX2_200_DT
101 - bool "Iomega StorCenter ix2-200 (Flattened Device Tree)"
102 - select ARCH_KIRKWOOD_DT
103 - help
104 - Say 'Y' here if you want your kernel to support the
105 - Iomega StorCenter ix2-200 (Flattened Device Tree).
106 -
107 -config MACH_KM_KIRKWOOD_DT
108 - bool "Keymile Kirkwood Reference Design (Flattened Device Tree)"
109 - select ARCH_KIRKWOOD_DT
110 - help
111 - Say 'Y' here if you want your kernel to support the
112 - Keymile Kirkwood Reference Desgin, using Flattened Device Tree.
113 -
114 -config MACH_LSXL_DT
115 - bool "Buffalo Linkstation LS-XHL, LS-CHLv2 (Flattened Device Tree)"
116 - select ARCH_KIRKWOOD_DT
117 - help
118 - Say 'Y' here if you want your kernel to support the
119 - Buffalo Linkstation LS-XHL & LS-CHLv2 devices, using
120 - Flattened Device Tree.
121 -
122 -config MACH_MPLCEC4_DT
123 - bool "MPL CEC4 (Flattened Device Tree)"
124 - select ARCH_KIRKWOOD_DT
125 - help
126 - Say 'Y' here if you want your kernel to support the
127 - MPL CEC4 (Flattened Device Tree).
128 -
129 -config MACH_NETSPACE_LITE_V2_DT
130 - bool "LaCie Network Space Lite v2 NAS (Flattened Device Tree)"
131 - select ARCH_KIRKWOOD_DT
132 - help
133 - Say 'Y' here if you want your kernel to support the LaCie
134 - Network Space Lite v2 NAS, using Flattened Device Tree.
135 -
136 -config MACH_NETSPACE_MAX_V2_DT
137 - bool "LaCie Network Space Max v2 NAS (Flattened Device Tree)"
138 - select ARCH_KIRKWOOD_DT
139 - help
140 - Say 'Y' here if you want your kernel to support the LaCie
141 - Network Space Max v2 NAS, using Flattened Device Tree.
142 -
143 -config MACH_NETSPACE_MINI_V2_DT
144 - bool "LaCie Network Space Mini v2 NAS (Flattened Device Tree)"
145 - select ARCH_KIRKWOOD_DT
146 - help
147 - Say 'Y' here if you want your kernel to support the LaCie
148 - Network Space Mini v2 NAS using Flattened Device Tree.
149 -
150 - This board is embedded in a product named CloudBox, which
151 - provides automatic backup on a 100GB cloud storage. This
152 - should not confused with a more recent LaCie NAS also named
153 - CloudBox. For this last, the disk capacity is 1TB or above.
154 -
155 -config MACH_NETSPACE_V2_DT
156 - bool "LaCie Network Space v2 NAS (Flattened Device Tree)"
157 - select ARCH_KIRKWOOD_DT
158 - help
159 - Say 'Y' here if you want your kernel to support the LaCie
160 - Network Space v2 NAS, using Flattened Device Tree.
161 -
162 -config MACH_OPENBLOCKS_A6_DT
163 - bool "Plat'Home OpenBlocks A6 (Flattened Device Tree)"
164 - select ARCH_KIRKWOOD_DT
165 - help
166 - Say 'Y' here if you want your kernel to support the
167 - Plat'Home OpenBlocks A6 (Flattened Device Tree).
168 -
169 -config MACH_READYNAS_DT
170 - bool "NETGEAR ReadyNAS Duo v2 (Flattened Device Tree)"
171 - select ARCH_KIRKWOOD_DT
172 - select ARM_APPENDED_DTB
173 - select ARM_ATAG_DTB_COMPAT
174 - help
175 - Say 'Y' here if you want your kernel to support the
176 - NETGEAR ReadyNAS Duo v2 using Fattened Device Tree.
177 -
178 -config MACH_TOPKICK_DT
179 - bool "USI Topkick (Flattened Device Tree)"
180 - select ARCH_KIRKWOOD_DT
181 - help
182 - Say 'Y' here if you want your kernel to support the
183 - USI Topkick, using Flattened Device Tree
184 -
185 config MACH_TS219_DT
186 bool "Device Tree for QNAP TS-11X, TS-21X NAS"
187 select ARCH_KIRKWOOD_DT
188 diff --git a/arch/arm/mach-kirkwood/Makefile b/arch/arm/mach-kirkwood/Makefile
189 index 2fdc3a7..062f8c7 100644
190 --- a/arch/arm/mach-kirkwood/Makefile
191 +++ b/arch/arm/mach-kirkwood/Makefile
192 @@ -19,25 +19,5 @@ obj-$(CONFIG_MACH_TS219) += ts219-setup.o tsx1x-common.o
193 obj-$(CONFIG_MACH_TS41X) += ts41x-setup.o tsx1x-common.o
194
195 obj-$(CONFIG_ARCH_KIRKWOOD_DT) += board-dt.o
196 -obj-$(CONFIG_MACH_CLOUDBOX_DT) += board-ns2.o
197 -obj-$(CONFIG_MACH_DB88F628X_BP_DT) += board-db88f628x-bp.o
198 obj-$(CONFIG_MACH_DLINK_KIRKWOOD_DT) += board-dnskw.o
199 -obj-$(CONFIG_MACH_DOCKSTAR_DT) += board-dockstar.o
200 -obj-$(CONFIG_MACH_DREAMPLUG_DT) += board-dreamplug.o
201 -obj-$(CONFIG_MACH_GOFLEXNET_DT) += board-goflexnet.o
202 -obj-$(CONFIG_MACH_GURUPLUG_DT) += board-guruplug.o
203 -obj-$(CONFIG_MACH_IB62X0_DT) += board-ib62x0.o
204 -obj-$(CONFIG_MACH_ICONNECT_DT) += board-iconnect.o
205 -obj-$(CONFIG_MACH_INETSPACE_V2_DT) += board-ns2.o
206 -obj-$(CONFIG_MACH_IOMEGA_IX2_200_DT) += board-iomega_ix2_200.o
207 -obj-$(CONFIG_MACH_KM_KIRKWOOD_DT) += board-km_kirkwood.o
208 -obj-$(CONFIG_MACH_LSXL_DT) += board-lsxl.o
209 -obj-$(CONFIG_MACH_MPLCEC4_DT) += board-mplcec4.o
210 -obj-$(CONFIG_MACH_NETSPACE_LITE_V2_DT) += board-ns2.o
211 -obj-$(CONFIG_MACH_NETSPACE_MAX_V2_DT) += board-ns2.o
212 -obj-$(CONFIG_MACH_NETSPACE_MINI_V2_DT) += board-ns2.o
213 -obj-$(CONFIG_MACH_NETSPACE_V2_DT) += board-ns2.o
214 -obj-$(CONFIG_MACH_OPENBLOCKS_A6_DT) += board-openblocks_a6.o
215 -obj-$(CONFIG_MACH_READYNAS_DT) += board-readynas.o
216 -obj-$(CONFIG_MACH_TOPKICK_DT) += board-usi_topkick.o
217 -obj-$(CONFIG_MACH_TS219_DT) += board-ts219.o tsx1x-common.o
218 +obj-$(CONFIG_MACH_TS219_DT) += tsx1x-common.o
219 diff --git a/arch/arm/mach-kirkwood/board-dnskw.c b/arch/arm/mach-kirkwood/board-dnskw.c
220 index a1aa87f..2af7a95 100644
221 --- a/arch/arm/mach-kirkwood/board-dnskw.c
222 +++ b/arch/arm/mach-kirkwood/board-dnskw.c
223 @@ -14,14 +14,9 @@
224 #include <linux/kernel.h>
225 #include <linux/init.h>
226 #include <linux/platform_device.h>
227 -#include <linux/mv643xx_eth.h>
228 #include <linux/gpio.h>
229 #include "common.h"
230
231 -static struct mv643xx_eth_platform_data dnskw_ge00_data = {
232 - .phy_addr = MV643XX_ETH_PHY_ADDR(8),
233 -};
234 -
235 /* Register any GPIO for output and set the value */
236 static void __init dnskw_gpio_register(unsigned gpio, char *name, int def)
237 {
238 @@ -36,8 +31,6 @@ static void __init dnskw_gpio_register(unsigned gpio, char *name, int def)
239
240 void __init dnskw_init(void)
241 {
242 - kirkwood_ge00_init(&dnskw_ge00_data);
243 -
244 /* Set NAS to turn back on after a power failure */
245 dnskw_gpio_register(37, "dnskw:power:recover", 1);
246 }
247 diff --git a/arch/arm/mach-kirkwood/board-dt.c b/arch/arm/mach-kirkwood/board-dt.c
248 index f5aed1f..15e61c8 100644
249 --- a/arch/arm/mach-kirkwood/board-dt.c
250 +++ b/arch/arm/mach-kirkwood/board-dt.c
251 @@ -106,92 +106,14 @@ static void __init kirkwood_dt_init(void)
252 kexec_reinit = kirkwood_enable_pcie;
253 #endif
254
255 - if (of_machine_is_compatible("globalscale,dreamplug"))
256 - dreamplug_init();
257 -
258 - if (of_machine_is_compatible("globalscale,guruplug"))
259 - guruplug_dt_init();
260 -
261 if (of_machine_is_compatible("dlink,dns-kirkwood"))
262 dnskw_init();
263
264 - if (of_machine_is_compatible("iom,iconnect"))
265 - iconnect_init();
266 -
267 - if (of_machine_is_compatible("raidsonic,ib-nas62x0"))
268 - ib62x0_init();
269 -
270 - if (of_machine_is_compatible("qnap,ts219"))
271 - qnap_dt_ts219_init();
272 -
273 - if (of_machine_is_compatible("seagate,dockstar"))
274 - dockstar_dt_init();
275 -
276 - if (of_machine_is_compatible("seagate,goflexnet"))
277 - goflexnet_init();
278 -
279 - if (of_machine_is_compatible("buffalo,lsxl"))
280 - lsxl_init();
281 -
282 - if (of_machine_is_compatible("iom,ix2-200"))
283 - iomega_ix2_200_init();
284 -
285 - if (of_machine_is_compatible("keymile,km_kirkwood"))
286 - km_kirkwood_init();
287 -
288 - if (of_machine_is_compatible("lacie,cloudbox") ||
289 - of_machine_is_compatible("lacie,inetspace_v2") ||
290 - of_machine_is_compatible("lacie,netspace_lite_v2") ||
291 - of_machine_is_compatible("lacie,netspace_max_v2") ||
292 - of_machine_is_compatible("lacie,netspace_mini_v2") ||
293 - of_machine_is_compatible("lacie,netspace_v2"))
294 - ns2_init();
295 -
296 - if (of_machine_is_compatible("marvell,db-88f6281-bp") ||
297 - of_machine_is_compatible("marvell,db-88f6282-bp"))
298 - db88f628x_init();
299 -
300 - if (of_machine_is_compatible("mpl,cec4"))
301 - mplcec4_init();
302 -
303 - if (of_machine_is_compatible("netgear,readynas-duo-v2"))
304 - netgear_readynas_init();
305 -
306 - if (of_machine_is_compatible("plathome,openblocks-a6"))
307 - openblocks_a6_init();
308 -
309 - if (of_machine_is_compatible("usi,topkick"))
310 - usi_topkick_init();
311 -
312 of_platform_populate(NULL, kirkwood_dt_match_table, NULL, NULL);
313 }
314
315 static const char * const kirkwood_dt_board_compat[] = {
316 - "globalscale,dreamplug",
317 - "globalscale,guruplug",
318 - "dlink,dns-320",
319 - "dlink,dns-325",
320 - "iom,iconnect",
321 - "raidsonic,ib-nas62x0",
322 - "qnap,ts219",
323 - "seagate,dockstar",
324 - "seagate,goflexnet",
325 - "buffalo,lsxl",
326 - "iom,ix2-200",
327 - "keymile,km_kirkwood",
328 - "lacie,cloudbox",
329 - "lacie,inetspace_v2",
330 - "lacie,netspace_lite_v2",
331 - "lacie,netspace_max_v2",
332 - "lacie,netspace_mini_v2",
333 - "lacie,netspace_v2",
334 - "marvell,db-88f6281-bp",
335 - "marvell,db-88f6282-bp",
336 - "mpl,cec4",
337 - "netgear,readynas-duo-v2",
338 - "plathome,openblocks-a6",
339 - "usi,topkick",
340 - "zyxel,nsa310",
341 + "marvell,kirkwood",
342 NULL
343 };
344
345 diff --git a/arch/arm/mach-kirkwood/board-lsxl.c b/arch/arm/mach-kirkwood/board-lsxl.c
346 deleted file mode 100644
347 index 4ec8b7a..0000000
348 --- a/arch/arm/mach-kirkwood/board-lsxl.c
349 +++ /dev/null
350 @@ -1,52 +0,0 @@
351 -/*
352 - * Copyright 2012 (C), Michael Walle <michael@walle.cc>
353 - *
354 - * arch/arm/mach-kirkwood/board-lsxl.c
355 - *
356 - * Buffalo Linkstation LS-XHL and LS-CHLv2 init for drivers not
357 - * converted to flattened device tree yet.
358 - *
359 - * This file is licensed under the terms of the GNU General Public
360 - * License version 2. This program is licensed "as is" without any
361 - * warranty of any kind, whether express or implied.
362 - */
363 -
364 -#include <linux/kernel.h>
365 -#include <linux/init.h>
366 -#include <linux/platform_device.h>
367 -#include <linux/mv643xx_eth.h>
368 -#include "common.h"
369 -
370 -static struct mv643xx_eth_platform_data lsxl_ge00_data = {
371 - .phy_addr = MV643XX_ETH_PHY_ADDR(0),
372 -};
373 -
374 -static struct mv643xx_eth_platform_data lsxl_ge01_data = {
375 - .phy_addr = MV643XX_ETH_PHY_ADDR(8),
376 -};
377 -
378 -/*
379 - * On the LS-XHL/LS-CHLv2, the shutdown process is following:
380 - * - Userland monitors key events until the power switch goes to off position
381 - * - The board reboots
382 - * - U-boot starts and goes into an idle mode waiting for the user
383 - * to move the switch to ON position
384 - *
385 - */
386 -static void lsxl_power_off(void)
387 -{
388 - kirkwood_restart('h', NULL);
389 -}
390 -
391 -void __init lsxl_init(void)
392 -{
393 - /*
394 - * Basic setup. Needs to be called early.
395 - */
396 -
397 - kirkwood_ge00_init(&lsxl_ge00_data);
398 - kirkwood_ge01_init(&lsxl_ge01_data);
399 -
400 - /* register power-off method */
401 - pm_power_off = lsxl_power_off;
402 -}
403 diff --git a/arch/arm/mach-kirkwood/board-readynas.c b/arch/arm/mach-kirkwood/board-readynas.c
404 deleted file mode 100644
405 index fb42c20..0000000
406 --- a/arch/arm/mach-kirkwood/board-readynas.c
407 +++ /dev/null
408 @@ -1,28 +0,0 @@
409 -/*
410 - * NETGEAR ReadyNAS Duo v2 Board setup for drivers not already
411 - * converted to DT.
412 - *
413 - * Copyright (C) 2013, Arnaud EBALARD <arno@natisbad.org>
414 - *
415 - * This program is free software; you can redistribute it and/or
416 - * modify it under the terms of the GNU General Public License
417 - * as published by the Free Software Foundation; either version
418 - * 2 of the License, or (at your option) any later version.
419 - */
420 -
421 -#include <linux/kernel.h>
422 -#include <linux/init.h>
423 -#include <linux/platform_device.h>
424 -#include <linux/mv643xx_eth.h>
425 -#include <mach/kirkwood.h>
426 -#include "common.h"
427 -
428 -static struct mv643xx_eth_platform_data netgear_readynas_ge00_data = {
429 - .phy_addr = MV643XX_ETH_PHY_ADDR(0),
430 -};
431 -
432 -void __init netgear_readynas_init(void)
433 -{
434 - kirkwood_ge00_init(&netgear_readynas_ge00_data);
435 - kirkwood_pcie_init(KW_PCIE0);
436 -}
437 --
438 1.8.4.rc1
439