mtd: mips: lantiq: reintroduce support for cmdline partitions

Linux-MTD Mailing List linux-mtd at lists.infradead.org
Mon Mar 26 20:59:12 EDT 2012


Gitweb:     http://git.infradead.org/?p=mtd-2.6.git;a=commit;h=bf011f2ed53d587fdd8148c173c4f09ed77bdf1a
Commit:     bf011f2ed53d587fdd8148c173c4f09ed77bdf1a
Parent:     d42b5de35fb058513367d1a9ee146be5aaab7c6a
Author:     Daniel Schwierzeck <daniel.schwierzeck at googlemail.com>
AuthorDate: Thu Feb 23 17:59:49 2012 +0100
Committer:  David Woodhouse <David.Woodhouse at intel.com>
CommitDate: Tue Mar 27 00:38:51 2012 +0100

    mtd: mips: lantiq: reintroduce support for cmdline partitions
    
    Since commit ca97dec2ab5c87e9fbdf7e882e1820004a3966fa the
    command line parsing of MTD partitions does not work anymore.
    
    Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck at googlemail.com>
    Signed-off-by: John Crispin <blogic at openwrt.org>
    Signed-off-by: Artem Bityutskiy <artem.bityutskiy at linux.intel.com>
    Cc: stable at kernel.org [3.2+]
    Acked-by: John Crispin <blogic at openwrt.org>
    Signed-off-by: David Woodhouse <David.Woodhouse at intel.com>
---
 drivers/mtd/maps/lantiq-flash.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/mtd/maps/lantiq-flash.c b/drivers/mtd/maps/lantiq-flash.c
index 7b889de..cf7a3cd 100644
--- a/drivers/mtd/maps/lantiq-flash.c
+++ b/drivers/mtd/maps/lantiq-flash.c
@@ -45,6 +45,7 @@ struct ltq_mtd {
 };
 
 static char ltq_map_name[] = "ltq_nor";
+static const char *ltq_probe_types[] __devinitconst = { "cmdlinepart", NULL };
 
 static map_word
 ltq_read16(struct map_info *map, unsigned long adr)
@@ -168,7 +169,7 @@ ltq_mtd_probe(struct platform_device *pdev)
 	cfi->addr_unlock1 ^= 1;
 	cfi->addr_unlock2 ^= 1;
 
-	err = mtd_device_parse_register(ltq_mtd->mtd, NULL, 0,
+	err = mtd_device_parse_register(ltq_mtd->mtd, ltq_probe_types, 0,
 			ltq_mtd_data->parts, ltq_mtd_data->nr_parts);
 	if (err) {
 		dev_err(&pdev->dev, "failed to add partitions\n");



More information about the linux-mtd-cvs mailing list