]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
mtd: mips: lantiq: reintroduce support for cmdline partitions
authorDaniel Schwierzeck <daniel.schwierzeck@googlemail.com>
Thu, 23 Feb 2012 16:59:49 +0000 (17:59 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 13 Apr 2012 15:33:46 +0000 (08:33 -0700)
commit bf011f2ed53d587fdd8148c173c4f09ed77bdf1a upstream.

Since commit ca97dec2ab5c87e9fbdf7e882e1820004a3966fa the
command line parsing of MTD partitions does not work anymore.

Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@googlemail.com>
Signed-off-by: John Crispin <blogic@openwrt.org>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Acked-by: John Crispin <blogic@openwrt.org>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/mtd/maps/lantiq-flash.c

index 4f10e27ada551d12f77cfd4d72b02f15ef9c5c8d..764d4681671c14a37f35112c9b86299155809e59 100644 (file)
@@ -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");