From 082e2e862a9ccfefb6d80a5228dc602919f42a34 Mon Sep 17 00:00:00 2001 From: Eric Miao Date: Fri, 11 Jul 2008 14:02:20 +0800 Subject: [PATCH] --- yaml --- r: 105183 b: refs/heads/master c: faf64ed4968e354624f330c6da6c1ce8b05a0713 h: refs/heads/master i: 105181: d6cd66bee04918f5a4f97751fb61dd32a2fd5821 105179: 9dc0a8b006dced67c62d20cf689b946378ea88f3 105175: 3bbbf537111d594ce946e9e0eb2267ca17790bb5 105167: 5bf62fee5955cb8926069462c3b74f32af3a36c0 105151: 8c5a2e8123bd43f0240b2f86f13b07c15c89ef87 v: v3 --- [refs] | 2 +- trunk/arch/arm/mach-pxa/Kconfig | 5 ++ trunk/arch/arm/mach-pxa/Makefile | 1 + trunk/arch/arm/mach-pxa/saar.c | 84 ++++++++++++++++++++++++++++++++ 4 files changed, 91 insertions(+), 1 deletion(-) create mode 100644 trunk/arch/arm/mach-pxa/saar.c diff --git a/[refs] b/[refs] index 66f867003159..e840004b7c46 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: bae033111cda415365ad40e9befb4b332d501c52 +refs/heads/master: faf64ed4968e354624f330c6da6c1ce8b05a0713 diff --git a/trunk/arch/arm/mach-pxa/Kconfig b/trunk/arch/arm/mach-pxa/Kconfig index 7e5578509c02..e8ee7ec9ff6d 100644 --- a/trunk/arch/arm/mach-pxa/Kconfig +++ b/trunk/arch/arm/mach-pxa/Kconfig @@ -201,6 +201,11 @@ config MACH_TAVOREVB select PXA3xx select PXA930 +config MACH_SAAR + bool "PXA930 Handheld Platform (aka SAAR)" + select PXA3xx + select PXA930 + config MACH_ARMCORE bool "CompuLab CM-X270 modules" select PXA27x diff --git a/trunk/arch/arm/mach-pxa/Makefile b/trunk/arch/arm/mach-pxa/Makefile index 24b20bc9dd6d..99ecbe7f8506 100644 --- a/trunk/arch/arm/mach-pxa/Makefile +++ b/trunk/arch/arm/mach-pxa/Makefile @@ -51,6 +51,7 @@ ifeq ($(CONFIG_MACH_ZYLONITE),y) endif obj-$(CONFIG_MACH_LITTLETON) += littleton.o obj-$(CONFIG_MACH_TAVOREVB) += tavorevb.o +obj-$(CONFIG_MACH_SAAR) += saar.o obj-$(CONFIG_MACH_ARMCORE) += cm-x270.o obj-$(CONFIG_PXA_EZX) += ezx.o diff --git a/trunk/arch/arm/mach-pxa/saar.c b/trunk/arch/arm/mach-pxa/saar.c new file mode 100644 index 000000000000..d02bc6f8bb93 --- /dev/null +++ b/trunk/arch/arm/mach-pxa/saar.c @@ -0,0 +1,84 @@ +/* + * linux/arch/arm/mach-pxa/saar.c + * + * Support for the Marvell PXA930 Handheld Platform (aka SAAR) + * + * Copyright (C) 2007-2008 Marvell International Ltd. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * publishhed by the Free Software Foundation. + */ + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include + +#include "devices.h" +#include "generic.h" + +/* SAAR MFP configurations */ +static mfp_cfg_t saar_mfp_cfg[] __initdata = { + /* Ethernet */ + DF_nCS1_nCS3, + GPIO97_GPIO, +}; + +#define SAAR_ETH_PHYS (0x14000000) + +static struct resource smc91x_resources[] = { + [0] = { + .start = (SAAR_ETH_PHYS + 0x300), + .end = (SAAR_ETH_PHYS + 0xfffff), + .flags = IORESOURCE_MEM, + }, + [1] = { + .start = gpio_to_irq(mfp_to_gpio(MFP_PIN_GPIO97)), + .end = gpio_to_irq(mfp_to_gpio(MFP_PIN_GPIO97)), + .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHEDGE, + } +}; + +static struct smc91x_platdata saar_smc91x_info = { + .flags = SMC91X_USE_16BIT | SMC91X_NOWAIT | SMC91X_USE_DMA, +}; + +static struct platform_device smc91x_device = { + .name = "smc91x", + .id = 0, + .num_resources = ARRAY_SIZE(smc91x_resources), + .resource = smc91x_resources, + .dev = { + .platform_data = &saar_smc91x_info, + }, +}; + +static void __init saar_init(void) +{ + /* initialize MFP configurations */ + pxa3xx_mfp_config(ARRAY_AND_SIZE(saar_mfp_cfg)); + + platform_device_register(&smc91x_device); +} + +MACHINE_START(SAAR, "PXA930 Handheld Platform (aka SAAR)") + /* Maintainer: Eric Miao */ + .phys_io = 0x40000000, + .boot_params = 0xa0000100, + .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc, + .map_io = pxa_map_io, + .init_irq = pxa3xx_init_irq, + .timer = &pxa_timer, + .init_machine = saar_init, +MACHINE_END