mtd: MLC device check in OneNAND driver

Linux-MTD Mailing List linux-mtd at lists.infradead.org
Sun Oct 24 20:59:08 EDT 2010


Gitweb:     http://git.infradead.org/?p=mtd-2.6.git;a=commit;h=c76268021e04e4313cd3a32242826f6a93388e2d
Commit:     c76268021e04e4313cd3a32242826f6a93388e2d
Parent:     17a22826bbfeed27b10c0d8274fc19d5fc3951c3
Author:     Rohit Hassan Sathyanarayan <rohit.hs at samsung.com>
AuthorDate: Mon Sep 27 16:02:10 2010 +0530
Committer:  David Woodhouse <David.Woodhouse at intel.com>
CommitDate: Mon Oct 25 00:50:28 2010 +0100

    mtd: MLC device check in OneNAND driver
    
    The MLC NAND Flash differs from the SLC NAND flash in functioning
    and the cell structure. Therefore we are considering it as a
    different Flash type.
    
    Signed-off-by: Rohit H.S <rohit.hs at samsung.com>
    Signed-off-by: Raghav Gupta <gupta.raghav at samsung.com>
    Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy at nokia.com>
    Signed-off-by: David Woodhouse <David.Woodhouse at intel.com>
---
 drivers/mtd/onenand/onenand_base.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/mtd/onenand/onenand_base.c b/drivers/mtd/onenand/onenand_base.c
index a2bb520..33e0dbb 100644
--- a/drivers/mtd/onenand/onenand_base.c
+++ b/drivers/mtd/onenand/onenand_base.c
@@ -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;



More information about the linux-mtd-cvs mailing list