Skip to contentSkip to conversation

bcmring: mtd nand driver (v3)

PATCH In review Leo (Hao) Chen 3 participants 3 messages Oct 10, 2009 – Oct 19, 2009

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 bcmring: mtd nand driver (v3)

Hi,

I've updated the mtd nand driver for bcmring machine. It is applicable to the latest kernel.org git tree.

Is it possible for this patch to be merged into the 2.6.32 git tree?

Thanks a lot for your review.

Best,

Leo

Quoted 1 line

From 93c98c79ed9cb6cc7de40b35d8c730f1ba872dd4 Mon Sep 17 00:00:00 2001

From: Leo Chen <[email protected]>
Date: Mon, 28 Sep 2009 14:11:49 -0700
Subject: [PATCH] add bcmring mtd nand driver support

Add mtd umi driver for bcmring arm arch.
Add header files, register definition files,
add entry in Kconfig and Makefile.

remove superfluous comments from bcm nand driver.
use platform resource.
fix section mismatch warning in the driver.

---
 arch/arm/mach-bcmring/arch.c                  |   10 +
 arch/arm/mach-bcmring/include/mach/reg_nand.h |   66 +++
 arch/arm/mach-bcmring/include/mach/reg_umi.h  |  237 ++++++++++
 drivers/mtd/nand/Kconfig                      |   16 +
 drivers/mtd/nand/Makefile                     |    1 +
 drivers/mtd/nand/bcm_umi_bch.c                |  213 +++++++++
 drivers/mtd/nand/bcm_umi_nand.c               |  581 +++++++++++++++++++++++++
 drivers/mtd/nand/nand_bcm_umi.c               |  149 +++++++
 drivers/mtd/nand/nand_bcm_umi.h               |  358 +++++++++++++++
 9 files changed, 1631 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/mach-bcmring/include/mach/reg_nand.h
 create mode 100644 arch/arm/mach-bcmring/include/mach/reg_umi.h
 create mode 100644 drivers/mtd/nand/bcm_umi_bch.c
 create mode 100644 drivers/mtd/nand/bcm_umi_nand.c
 create mode 100644 drivers/mtd/nand/nand_bcm_umi.c
 create mode 100644 drivers/mtd/nand/nand_bcm_umi.h
arch/arm/mach-bcmring/arch.c +10 -0
index 0da693b..074dad6 100644
@@ -76,9 +76,19 @@ static struct ctl_table bcmring_sysctl_reboot[] = {
 	{}
 };
 
+static struct resource nand_resource[] = {
+	[0] = {
+		.start = MM_ADDR_IO_NAND,
+		.end = MM_ADDR_IO_NAND + 0x1000 - 1,
+		.flags = IORESOURCE_MEM,
+	},
+};
+
 static struct platform_device nand_device = {
 	.name = "bcm-nand",
 	.id = -1,
+	.resource = nand_resource,
+	.num_resources	= ARRAY_SIZE(nand_resource),
 };
 
 static struct platform_device *devices[] __initdata = {
arch/arm/mach-bcmring/include/mach/reg_nand.h new file +66 -0

66 lines not on this page · raw message

arch/arm/mach-bcmring/include/mach/reg_umi.h new file +237 -0

237 lines not on this page · raw message

drivers/mtd/nand/Kconfig +16 -0
index 2fda0b6..34598e9 100644
@@ -203,6 +203,22 @@ config MTD_NAND_S3C2410_CLKSTOP
 	  when the is NAND chip selected or released, but will save
 	  approximately 5mA of power when there is nothing happening.
 
+config MTD_NAND_BCM_UMI
+	tristate "NAND Flash support for BCM Reference Boards"
+	depends on ARCH_BCMRING && MTD_NAND
+	help
+	  This enables the NAND flash controller on the BCM UMI block.
+
+	  No board specfic support is done by this driver, each board
+	  must advertise a platform_device for the driver to attach.
+
+config MTD_NAND_BCM_UMI_HWCS
+	bool "BCM UMI NAND Hardware CS"
+	depends on MTD_NAND_BCM_UMI
+	help
+	  Enable the use of the BCM UMI block's internal CS using NAND.
+	  This should only be used if you know the external NAND CS can toggle.
+
 config MTD_NAND_DISKONCHIP
 	tristate "DiskOnChip 2000, Millennium and Millennium Plus (NAND reimplementation) (EXPERIMENTAL)"
 	depends on EXPERIMENTAL
drivers/mtd/nand/Makefile +1 -0
index 6950d3d..460a1f3 100644
@@ -42,5 +42,6 @@ obj-$(CONFIG_MTD_NAND_SOCRATES)		+= socrates_nand.o
 obj-$(CONFIG_MTD_NAND_TXX9NDFMC)	+= txx9ndfmc.o
 obj-$(CONFIG_MTD_NAND_W90P910)		+= w90p910_nand.o
 obj-$(CONFIG_MTD_NAND_NOMADIK)		+= nomadik_nand.o
+obj-$(CONFIG_MTD_NAND_BCM_UMI)		+= bcm_umi_nand.o nand_bcm_umi.o
 
 nand-objs := nand_base.o nand_bbt.o
drivers/mtd/nand/bcm_umi_bch.c new file +213 -0

213 lines not on this page · raw message

drivers/mtd/nand/bcm_umi_nand.c new file +581 -0

581 lines not on this page · raw message

drivers/mtd/nand/nand_bcm_umi.c new file +149 -0

149 lines not on this page · raw message

drivers/mtd/nand/nand_bcm_umi.h new file +358 -0

358 lines not on this page · raw message

Signature · 5 lines
1.6.0.6

-- 

Leo Hao Chen
#1 lore raw
Quoted 10 lines · Leo (Hao) Chen

Hi,

I've updated the mtd nand driver for bcmring machine. It is applicable to the latest kernel.org git tree.

Is it possible for this patch to be merged into the 2.6.32 git tree?

Thanks a lot for your review.

Best,

No idea about dwmw2's plans, but I've refreshed your driver in my l2-mtd-2.6.git tree.
http://git.infradead.org/users/dedekind/l2-mtd-2.6.git/commit/005e0a0356c62edcc98ced43cf83d474df92202d

Signature · 2 lines
Best Regards,
Artem Bityutskiy (Артём Битюцкий)
#2 lore raw
Quoted 19 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Artem Bityutskiy
Sent: October 11, 2009 6:55 AM
To: Leo (Hao) Chen
Cc: David Woodhouse; Linux MTD
Subject: Re: [PATCH] [MTD] bcmring: mtd nand driver (v3)

Quoted 7 lines · Leo (Hao) Chen

Hi,

I've updated the mtd nand driver for bcmring machine. It is applicable to the latest kernel.org git tree.

Is it possible for this patch to be merged into the 2.6.32 git tree?

Quoted 7 lines
Quoted 3 lines

Thanks a lot for your review.

Best,

No idea about dwmw2's plans, but I've refreshed your driver in my l2-mtd-2.6.git tree.
http://git.infradead.org/users/dedekind/l2-mtd-2.6.git/commit/

005e0a0356c62edcc98ced43cf83d474df92202d

Quoted 5 lines

--
Best Regards,
Artem Bityutskiy (Артём Битюцкий)

Hi David,

Is there anything else that needs to be done to get this
into the mainline?

Thanks,
Scott

Quoted 5 lines

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/