Skip to contentSkip to conversation

MLC device check in OneNAND driver

PATCH RESEND In review Rohit Hassan Sathyanarayan 2 participants 4 messages Sep 24, 2010 – Oct 7, 2010 Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 MLC device check in OneNAND driver

---
 drivers/mtd/onenand/onenand_base.c |    2 +-
 include/mtd/mtd-abi.h              |    1 +
 2 files changed, 2 insertions(+), 1 deletions(-)
drivers/mtd/onenand/onenand_base.c +1 -1
index a2bb520..33e0dbb 100644
@@ -4027,7 +4027,7 @@ int onenand_scan(struct mtd_info *mtd, int maxchips)
 	mtd->ecclayout = this->ecclayout;
 
 	/* Fill in remaining MTD driver data */
-	mtd->type = MTD_NANDFLASH;
+	mtd->type = ONENAND_IS_MLC(this) ? MTD_MLCNANDFLASH : MTD_NANDFLASH;
 	mtd->flags = MTD_CAP_NANDFLASH;
 	mtd->erase = onenand_erase;
 	mtd->point = NULL;
include/mtd/mtd-abi.h +1 -0
index 4debb45..8d8161c 100644
@@ -52,6 +52,7 @@ struct mtd_oob_buf64 {
 #define MTD_NANDFLASH		4
 #define MTD_DATAFLASH		6
 #define MTD_UBIVOLUME		7
+#define MTD_MLCNANDFLASH	8
 
 #define MTD_WRITEABLE		0x400	/* Device is writeable */
 #define MTD_BIT_WRITEABLE	0x800	/* Single bits can be flipped */
Signature · 1 line
1.6.6.1
#1 lore raw
Quoted 2 lines · Rohit Hassan Sathyanarayan

Almost perfect. However:

1. All mtd patches should have "mtd:" prefix.
2. Add some description about what you do and why into the commit message.
3. I think combining is not good, better do it old way - first patch introduces the flag, second uses it in OneNAND

Sorry for being picky, but I really want to show you how to send patches properly once and later get good series from you.

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

Hi Artem,

Quoted 11 lines

-----Original Message-----
From: Artem Bityutskiy [mailto:[email protected]]
Sent: Friday, September 24, 2010 5:22 PM
To: Rohit Hassan Sathyanarayan
Cc: [email protected]; [email protected]; [email protected]
Subject: Re: [PATCH RESEND][MTD]MLC device check in OneNAND driver

Quoted 2 lines · Rohit Hassan Sathyanarayan
Quoted 8 lines

Almost perfect. However:

1. All mtd patches should have "mtd:" prefix.
2. Add some description about what you do and why into the commit message.
3. I think combining is not good, better do it old way - first patch introduces the flag, second uses it in OneNAND

We made changes as per your comments and have posted two patches, Links of two patches,
http://lists.infradead.org/pipermail/linux-mtd/2010-September/032333.html
http://lists.infradead.org/pipermail/linux-mtd/2010-September/032334.html

Quoted 6 lines

Sorry for being picky, but I really want to show you how to send patches properly once and later get good series from you.

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