mtd: edb7312: correctly pass MTD name to parsers

Linux-MTD Mailing List linux-mtd at lists.infradead.org
Mon Nov 7 11:59:18 EST 2011


Gitweb:     http://git.infradead.org/?p=mtd-2.6.git;a=commit;h=d117040be074fd1c019b751515f79efe99cd7d76
Commit:     d117040be074fd1c019b751515f79efe99cd7d76
Parent:     3a8fb12ae9fdbb712f11f9c73e5d08dc34f82118
Author:     Dmitry Eremin-Solenikov <dbaryshkov at gmail.com>
AuthorDate: Thu Jun 9 14:54:41 2011 +0400
Committer:  Artem Bityutskiy <artem.bityutskiy at intel.com>
CommitDate: Sun Sep 11 15:02:10 2011 +0300

    mtd: edb7312: correctly pass MTD name to parsers
    
    cmdline partitions parser expects MTD name at mtd->name, instead of
    origin, while edb7312 passes MTDID as origin. Fix that.
    
    Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov at gmail.com>
    Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy at nokia.com>
---
 drivers/mtd/maps/edb7312.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/mtd/maps/edb7312.c b/drivers/mtd/maps/edb7312.c
index fe42a21..b07acd6 100644
--- a/drivers/mtd/maps/edb7312.c
+++ b/drivers/mtd/maps/edb7312.c
@@ -88,8 +88,9 @@ static int __init init_edb7312nor(void)
 	}
 	if (mymtd) {
 		mymtd->owner = THIS_MODULE;
+		mymtd->name = MTDID;
 
-		mtd_parts_nb = parse_mtd_partitions(mymtd, probes, &mtd_parts, MTDID);
+		mtd_parts_nb = parse_mtd_partitions(mymtd, probes, &mtd_parts, 0);
 		if (mtd_parts_nb > 0)
 			part_type = "detected";
 



More information about the linux-mtd-cvs mailing list