From 93d85d700e030586af81caf4ed277bf7dd73c9ac Mon Sep 17 00:00:00 2001 From: Martin Michlmayr Date: Fri, 30 Oct 2009 10:37:33 +0000 Subject: [PATCH] Add OpenRD-Client support again. svn path=/dists/sid/linux-2.6/; revision=14520 --- debian/changelog | 1 + .../patches/features/arm/openrd-client.patch | 141 ++++++++++++++++++ debian/patches/series/2 | 1 + 3 files changed, 143 insertions(+) create mode 100644 debian/patches/features/arm/openrd-client.patch diff --git a/debian/changelog b/debian/changelog index 06fdfe05c..2ae3b5614 100644 --- a/debian/changelog +++ b/debian/changelog @@ -4,6 +4,7 @@ linux-2.6 (2.6.31-2) UNRELEASED; urgency=low * [armel/kirkwood] Enable CRYPTO_DEV_MV_CESA (Closes: #552270). * [armel/kirkwood, armel/orion5x] Enable ORION_WATCHDOG (the name of the config variable changed). + * Add OpenRD-Client support again. * mips: fix build of vmlinux.lds (Closes: #552422). -- Martin Michlmayr Tue, 27 Oct 2009 21:18:29 +0800 diff --git a/debian/patches/features/arm/openrd-client.patch b/debian/patches/features/arm/openrd-client.patch new file mode 100644 index 000000000..61627f1f3 --- /dev/null +++ b/debian/patches/features/arm/openrd-client.patch @@ -0,0 +1,141 @@ +--- a/arch/arm/mach-kirkwood/Kconfig 2009-09-25 19:49:01.000000000 +0000 ++++ b/arch/arm/mach-kirkwood/Kconfig 2009-09-25 19:50:08.000000000 +0000 +@@ -44,6 +44,12 @@ + Say 'Y' here if you want your kernel to support the + Marvell OpenRD Base Board. + ++config MACH_OPENRD_CLIENT ++ bool "Marvell OpenRD Client Board" ++ help ++ Say 'Y' here if you want your kernel to support the ++ Marvell OpenRD Client Board. ++ + endmenu + + endif +--- a/arch/arm/mach-kirkwood/Makefile 2009-09-25 19:49:07.000000000 +0000 ++++ b/arch/arm/mach-kirkwood/Makefile 2009-09-25 19:49:29.000000000 +0000 +@@ -7,5 +7,6 @@ + obj-$(CONFIG_MACH_SHEEVAPLUG) += sheevaplug-setup.o + obj-$(CONFIG_MACH_TS219) += ts219-setup.o + obj-$(CONFIG_MACH_OPENRD_BASE) += openrd_base-setup.o ++obj-$(CONFIG_MACH_OPENRD_CLIENT) += openrd_client-setup.o + + obj-$(CONFIG_CPU_IDLE) += cpuidle.o +--- /dev/null 2008-06-15 07:07:41.000000000 +0000 ++++ b/arch/arm/mach-kirkwood/openrd_client-setup.c 2009-09-25 19:52:36.000000000 +0000 +@@ -0,0 +1,107 @@ ++/* ++ * arch/arm/mach-kirkwood/openrd_client-setup.c ++ * ++ * Marvell OpenRD Base Client Setup ++ * ++ * This file is licensed under the terms of the GNU General Public ++ * License version 2. This program is licensed "as is" without any ++ * warranty of any kind, whether express or implied. ++ */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include "common.h" ++#include "mpp.h" ++ ++static struct mtd_partition openrd_client_nand_parts[] = { ++ { ++ .name = "u-boot", ++ .offset = 0, ++ .size = SZ_1M ++ }, { ++ .name = "uImage", ++ .offset = MTDPART_OFS_NXTBLK, ++ .size = SZ_4M ++ }, { ++ .name = "root", ++ .offset = MTDPART_OFS_NXTBLK, ++ .size = MTDPART_SIZ_FULL ++ }, ++}; ++ ++static struct mv643xx_eth_platform_data openrd_client_ge00_data = { ++ .phy_addr = MV643XX_ETH_PHY_ADDR(8), ++}; ++ ++static struct mv643xx_eth_platform_data openrd_client_ge01_data = { ++ .phy_addr = MV643XX_ETH_PHY_ADDR(24), ++}; ++ ++static struct mv_sata_platform_data openrd_client_sata_data = { ++ .n_ports = 2, ++}; ++ ++static struct mvsdio_platform_data openrd_client_mvsdio_data = { ++ .gpio_card_detect = 29, /* MPP29 used as SD card detect */ ++}; ++ ++static unsigned int openrd_client_mpp_config[] __initdata = { ++ MPP29_GPIO, ++ 0 ++}; ++ ++static void __init openrd_client_init(void) ++{ ++ /* ++ * Basic setup. Needs to be called early. ++ */ ++ kirkwood_init(); ++ kirkwood_mpp_conf(openrd_client_mpp_config); ++ ++ kirkwood_uart0_init(); ++ kirkwood_uart1_init(); ++ kirkwood_nand_init(ARRAY_AND_SIZE(openrd_client_nand_parts), 25); ++ ++ kirkwood_ehci_init(); ++ ++ /* initialize gbe0 and gbe1 */ ++ kirkwood_ge00_init(&openrd_client_ge00_data); ++ kirkwood_ge01_init(&openrd_client_ge01_data); ++ ++ kirkwood_sata_init(&openrd_client_sata_data); ++ kirkwood_sdio_init(&openrd_client_mvsdio_data); ++ ++ kirkwood_i2c_init(); ++} ++ ++static int __init openrd_client_pci_init(void) ++{ ++if (machine_is_openrd_client()) ++ kirkwood_pcie_init(); ++ ++ return 0; ++} ++subsys_initcall(openrd_client_pci_init); ++ ++ ++ ++ ++MACHINE_START(OPENRD_CLIENT, "Marvell OpenRD Client Board") ++ /* Maintainer: Dhaval Vasa */ ++ .phys_io = KIRKWOOD_REGS_PHYS_BASE, ++ .io_pg_offst = ((KIRKWOOD_REGS_VIRT_BASE) >> 18) & 0xfffc, ++ .boot_params = 0x00000100, ++ .init_machine = openrd_client_init, ++ .map_io = kirkwood_map_io, ++ .init_irq = kirkwood_init_irq, ++ .timer = &kirkwood_timer, ++MACHINE_END +--- a/arch/arm/tools/mach-types~ 2009-10-30 10:33:43.000000000 +0000 ++++ b/arch/arm/tools/mach-types 2009-10-30 10:33:46.000000000 +0000 +@@ -2281,3 +2281,4 @@ + matrix504 MACH_MATRIX504 MATRIX504 2294 + mrfsa MACH_MRFSA MRFSA 2295 + openrd_base MACH_OPENRD_BASE OPENRD_BASE 2325 ++openrd_client MACH_OPENRD_CLIENT OPENRD_CLIENT 2361 diff --git a/debian/patches/series/2 b/debian/patches/series/2 index 7a1c3bdb9..cd4b192f2 100644 --- a/debian/patches/series/2 +++ b/debian/patches/series/2 @@ -1 +1,2 @@ + bugfix/mips/fix-build-vmlinuxlds.patch ++ features/arm/openrd-client.patch