summaryrefslogtreecommitdiff
path: root/arch/arm/mach-mx3
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2010-08-18 16:20:24 (GMT)
committerUwe Kleine-König <u.kleine-koenig@pengutronix.de>2010-09-27 10:52:55 (GMT)
commitd17e1c1ac3a1e4befecb34c20dc8cb901aa72aba (patch)
treed7448db74a0dd871ee4747bfcf3e7c0689465ef6 /arch/arm/mach-mx3
parent3b161e51b254fa7bd3a9b0bd7ca7a2ac8ceaae8b (diff)
downloadlinux-fsl-qoriq-d17e1c1ac3a1e4befecb34c20dc8cb901aa72aba.tar.xz
ARM: mx3/mx35_3ds: add physmap-flash NOR at CS0
The mx35_3ds comes with 64 MiByte for NOR flash at CS0, add physmap-flash platform device for it. Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-mx3')
-rw-r--r--arch/arm/mach-mx3/mach-mx35_3ds.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/arch/arm/mach-mx3/mach-mx35_3ds.c b/arch/arm/mach-mx3/mach-mx35_3ds.c
index 1c30d72..73149b8 100644
--- a/arch/arm/mach-mx3/mach-mx35_3ds.c
+++ b/arch/arm/mach-mx3/mach-mx35_3ds.c
@@ -1,5 +1,6 @@
/*
* Copyright 2009 Freescale Semiconductor, Inc. All Rights Reserved.
+ * Copyright (C) 2009 Marc Kleine-Budde, Pengutronix
*
* Author: Fabio Estevam <fabio.estevam@freescale.com>
*
@@ -27,6 +28,8 @@
#include <linux/gpio.h>
#include <linux/fsl_devices.h>
+#include <linux/mtd/physmap.h>
+
#include <asm/mach-types.h>
#include <asm/mach/arch.h>
#include <asm/mach/time.h>
@@ -43,8 +46,29 @@ static const struct imxuart_platform_data uart_pdata __initconst = {
.flags = IMXUART_HAVE_RTSCTS,
};
+static struct physmap_flash_data mx35pdk_flash_data = {
+ .width = 2,
+};
+
+static struct resource mx35pdk_flash_resource = {
+ .start = MX35_CS0_BASE_ADDR,
+ .end = MX35_CS0_BASE_ADDR + SZ_64M - 1,
+ .flags = IORESOURCE_MEM,
+};
+
+static struct platform_device mx35pdk_flash = {
+ .name = "physmap-flash",
+ .id = 0,
+ .dev = {
+ .platform_data = &mx35pdk_flash_data,
+ },
+ .resource = &mx35pdk_flash_resource,
+ .num_resources = 1,
+};
+
static struct platform_device *devices[] __initdata = {
&mxc_fec_device,
+ &mx35pdk_flash,
};
static struct pad_desc mx35pdk_pads[] = {