From c76268021e04e4313cd3a32242826f6a93388e2d Mon Sep 17 00:00:00 2001 From: Rohit Hassan Sathyanarayan Date: Mon, 27 Sep 2010 16:02:10 +0530 Subject: [PATCH] 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 Signed-off-by: Raghav Gupta Signed-off-by: Artem Bityutskiy Signed-off-by: David Woodhouse --- drivers/mtd/onenand/onenand_base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mtd/onenand/onenand_base.c b/drivers/mtd/onenand/onenand_base.c index a2bb520286f8..33e0dbb0a96d 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; -- 2.20.1