Skip to contentSkip to conversation

cmx270-nand: Make CMDLINE_PARTS usable

PATCH In review Raphael Assenat 4 participants 7 messages Sep 13, 2006 – Sep 25, 2006

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

PATCH 1/1 cmx270-nand: Make CMDLINE_PARTS usable

This patch gives a name to the cmx270 nand mtd, making it possible to use command line partitioning.

eg:
mtdparts=cmx270-nand:32m(root),8m(data),-(spare)"

does not work without this patch. The default (one full device partition) hardcoded in the driver is used.

This patch gives a name to the cmx270 nand mtd, making it possible to use command line partitioning.

eg:
mtdparts=cmx270-nand:32m(root),8m(data),-(spare)"

does not work without this patch. The default (one full device partition) hardcoded in the driver is used.

drivers/mtd/nand/cmx270-nand.c +1 -0
@@ -218,6 +218,7 @@
 		goto err2;
 	}
 
+	cmx270_nand_mtd->name = "cmx270-nand";
 #ifdef CONFIG_MTD_CMDLINE_PARTS
 	mtd_parts_nb = parse_mtd_partitions(cmx270_nand_mtd, part_probes,
 					    &mtd_parts, 0);
#1 lore raw
Quoted 2 lines · Raphael Assenat

This patch gives a name to the cmx270 nand mtd, making it possible to use command line partitioning.

Er, there _is_ no cmx270 nand board driver in my tree.

Signature · 1 line
dwmw2
#2 lore raw
Quoted 8 lines · David Woodhouse
Quoted 2 lines · Raphael Assenat

This patch gives a name to the cmx270 nand mtd, making it possible to use command line partitioning.

Er, there _is_ no cmx270 nand board driver in my tree.

Oh, sorry. My patch applies over the patch Mike Rapoport sent to the list on July 18
([PATCH] [MTD] CM-x270 NAND flash support), which I thought was already accepted. Was there anything wrong with it? Maybe you just missed it...

I also sent a patch to the list on July 21 which added NAND flash support for the cm-x255 boards ([PATCH] Add support for NAND flash on cm-x255) but received no feedback. I can resend it if you wish.

(BTW, every time I send to the linux-mtd list my message is held for moderator approval for reason 'Message has a suspicious header'. Who should I contact for more information? I'd like to know exactly what header(s) is/are 'suspicious' and fix them if possible).

Best regards,

Signature · 2 lines
Raphael Assenat
8D Technologies Inc.
#3 lore raw
Quoted 7 lines · Raphael Assenat

Oh, sorry. My patch applies over the patch Mike Rapoport sent to the list on July 18 ([PATCH] [MTD] CM-x270 NAND flash support), which I thought was already accepted. Was there anything wrong with it? Maybe you just missed it...

I also sent a patch to the list on July 21 which added NAND flash support for the cm-x255 boards ([PATCH] Add support for NAND flash on cm-x255) but received no feedback. I can resend it if you wish.

July and August weren't really a good time for sending stuff that you expect me to pay attention to; sorry. Yes -- please retest and resend.

Can you explain how these two boards differ, and why they need two separate drivers?

Quoted 3 lines

(BTW, every time I send to the linux-mtd list my message is held for moderator approval for reason 'Message has a suspicious header'. Who should I contact for more information? I'd like to know exactly what header(s) is/are 'suspicious' and fix them if possible).

It just doesn't like attachments. Send patches inline and they shouldn't get trapped.

Signature · 1 line
dwmw2
#4 lore raw
Quoted 5 lines · David Woodhouse
Quoted 3 lines · Raphael Assenat

Oh, sorry. My patch applies over the patch Mike Rapoport sent to the list on July 18
([PATCH] [MTD] CM-x270 NAND flash support), which I thought was already accepted. Was there anything wrong with it? Maybe you just missed it...

Quoted 8 lines
Quoted 1 line

I also sent a patch to the list on July 21 which added NAND flash support for the cm-x255 boards ([PATCH] Add support for NAND flash on cm-x255) but received no feedback. I can resend it if you wish.

July and August weren't really a good time for sending stuff that you expect me to pay attention to; sorry. Yes -- please retest and resend.

Can you explain how these two boards differ, and why they need two separate drivers?

Yes.

NAND on cm-x255:
- Uses physical address 0x04000000
- CS, ALE, CLE and RB mapped to pxa GPIOs 5,4,3,10 respectively.

NAND on cm-x270:
- CS and RB mapped to pxa GPIOs 11 and 89
- Read/Write with ALE/CLE inactive: 0x04000000
- Read/Write with ALE active: 0x04000008
- Read/Write with CLE active: 0x04000004

The base address is the same, but GPIOs used differ and the control signals are controlled differently.

Quoted 5 lines
Quoted 1 line

(BTW, every time I send to the linux-mtd list my message is held for moderator approval for reason 'Message has a suspicious header'. Who should I contact for more information? I'd like to know exactly what header(s) is/are 'suspicious' and fix them if possible).

It just doesn't like attachments. Send patches inline and they shouldn't get trapped.

Best regards,

Signature · 2 lines
Raphael Assenat
8D Technologies Inc.
#6 lore raw

PATCH RESEND 1/1 CM-x270 NAND flash support (Was [PATCH] cmx270-nand: Make CMDLINE_PARTS usable)

In reply to David Woodhouse
Quoted 6 lines · David Woodhouse
Quoted 3 lines · Raphael Assenat

Oh, sorry. My patch applies over the patch Mike Rapoport sent to the list on July 18
([PATCH] [MTD] CM-x270 NAND flash support), which I thought was already accepted. Was there anything wrong with it? Maybe you just missed it...

Quoted 8 lines
Quoted 3 lines

I also sent a patch to the list on July 21 which added NAND flash support for the cm-x255 boards ([PATCH] Add support for NAND flash on cm-x255) but received no feedback. I can resend it if you wish.

July and August weren't really a good time for sending stuff that you expect me to pay attention to; sorry. Yes -- please retest and resend.

This patch provides MTD support for NAND flash device on CM-x270 modules. This is the same patch I've sent earlier.
Unfortunately I'm currently overloaded to update it for the recent kernels and retest.

Quoted 14 lines

Can you explain how these two boards differ, and why they need two separate drivers?

Quoted 3 lines

(BTW, every time I send to the linux-mtd list my message is held for moderator approval for reason 'Message has a suspicious header'. Who should I contact for more information? I'd like to know exactly what header(s) is/are 'suspicious' and fix them if possible).

It just doesn't like attachments. Send patches inline and they shouldn't get trapped.

Signature · 15 lines
Sincerely yours,
Mike Rapoport


=========================================================
This patch provides MTD support for NAND flash device on CM-x270 modules.


Signed-off-by: Mike Rapoport <[email protected]>

=========================================================

drivers/mtd/nand/Kconfig       |    4 +
drivers/mtd/nand/Makefile      |    1 drivers/mtd/nand/cmx270-nand.c |  271 ++++++++++++++++++++++++++++++++++++++++
3 files changed, 276 insertions(+), 0 deletions(-)
drivers/mtd/nand/Kconfig +0 -0
index 3db77ee..4c212fd 100644
@@ -232,6 +232,10 @@ config MTD_NAND_CS553X
 

If you say "m", the module will be called "cs553x_nand.ko".

+config MTD_NAND_CM_X270
+ tristate "Support for NAND Flash on CM-X270 modules"
+ depends on MTD_NAND && MACH_CM_X270
+
config MTD_NAND_NANDSIM

	tristate "Support for NAND Flash Simulator"
	depends on MTD_NAND && MTD_PARTITIONS
drivers/mtd/nand/Makefile +0 -0
index f747593..f2718aa 100644
@@ -22,5 +22,6 @@ obj-$(CONFIG_MTD_NAND_TS7250)		+= ts7250

obj-$(CONFIG_MTD_NAND_NANDSIM) += nandsim.o
obj-$(CONFIG_MTD_NAND_CS553X) += cs553x_nand.o
obj-$(CONFIG_MTD_NAND_NDFC) += ndfc.o
+obj-$(CONFIG_MTD_NAND_CM_X270) += cmx270-nand.o

nand-objs = nand_base.o nand_bbt.o

drivers/mtd/nand/cmx270-nand.c new file +271 -0

271 lines not on this page · raw message

#5 lore raw
In reply to Raphael Assenat
Quoted 7 lines · Raphael Assenat
Quoted 6 lines · David Woodhouse
Quoted 4 lines · Raphael Assenat

Oh, sorry. My patch applies over the patch Mike Rapoport sent to the list on July 18 ([PATCH] [MTD] CM-x270 NAND flash support), which I thought was already accepted. Was there anything wrong with it? Maybe you just missed it...

Quoted 7 lines
Quoted 7 lines
Quoted 3 lines

I also sent a patch to the list on July 21 which added NAND flash support for the cm-x255 boards ([PATCH] Add support for NAND flash on cm-x255) but received no feedback. I can resend it if you wish.

July and August weren't really a good time for sending stuff that you expect me to pay attention to; sorry. Yes -- please retest and resend.

Here comes the resend.

This patch adds support for the NAND flash present on Compulab's cm-x255 boards. Since Compulab chose to discontinue cm-x255 support, I decided to submit and support this driver myself.

Note: This is the driver I wrote as part of my Compulab kernel fork project (see http://raph.people.8d.com/armcore_kernel.php). It is not based on the driver Mike posted to the list.

Applies to 2.6.18

drivers/mtd/nand/Kconfig +7 -0
diff -Nru linux-2.6.18-rc2/drivers/mtd/nand/Kconfig linux-2.6.18-rc2-mtd/drivers/mtd/nand/Kconfig
@@ -239,4 +239,11 @@
 	  The simulator may simulate various NAND flash chips for the
 	  MTD nand layer.
 
+config MTD_NAND_CM_X255
+	tristate "Support for NAND Flash on Compulab cm-x255"
+	depends on MTD_NAND && MACH_CM_X255
+	help
+	  This enables the driver for the NAND flash present
+	  on the cm-x255 board from Compulab.
+
 endmenu
drivers/mtd/nand/Makefile +1 -0
diff -Nru linux-2.6.18-rc2/drivers/mtd/nand/Makefile linux-2.6.18-rc2-mtd/drivers/mtd/nand/Makefile
@@ -22,5 +22,6 @@
 obj-$(CONFIG_MTD_NAND_NANDSIM)		+= nandsim.o
 obj-$(CONFIG_MTD_NAND_CS553X)		+= cs553x_nand.o
 obj-$(CONFIG_MTD_NAND_NDFC)		+= ndfc.o
+obj-$(CONFIG_MTD_NAND_CM_X255)		+= cm-x255.o
 
 nand-objs = nand_base.o nand_bbt.o
drivers/mtd/nand/cm-x255.c +183 -0

183 lines not on this page · raw message