diff mbox

mtd: edb7312: correctly pass MTD name to parsers

Message ID 1307616881-13941-1-git-send-email-dbaryshkov@gmail.com
State Accepted
Commit d117040be074fd1c019b751515f79efe99cd7d76
Headers show

Commit Message

Dmitry Baryshkov June 9, 2011, 10:54 a.m. UTC
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@gmail.com>
---
 drivers/mtd/maps/edb7312.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

Comments

Artem Bityutskiy June 9, 2011, 12:22 p.m. UTC | #1
On Thu, 2011-06-09 at 14:54 +0400, Dmitry Eremin-Solenikov wrote:
> 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@gmail.com>

Pushed, thanks!
diff mbox

Patch

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";