mtd: h1910: convert to mtd_device_register()
authorJamie Iles <jamie@jamieiles.com>
Mon, 23 May 2011 09:23:24 +0000 (10:23 +0100)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Wed, 25 May 2011 01:23:29 +0000 (02:23 +0100)
Convert to mtd_device_register() and remove the CONFIG_MTD_PARTITIONS
preprocessor conditionals as partitioning is always available.

Signed-off-by: Jamie Iles <jamie@jamieiles.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/mtd/nand/Kconfig
drivers/mtd/nand/h1910.c

index edec457d361d4b12a8f2a419d2330c54b2f6ddd8..333d231222264abd3bbb4318f99a4e030e401236 100644 (file)
@@ -92,7 +92,7 @@ config MTD_NAND_EDB7312
 
 config MTD_NAND_H1900
        tristate "iPAQ H1900 flash"
-       depends on ARCH_PXA && MTD_PARTITIONS
+       depends on ARCH_PXA
        help
          This enables the driver for the iPAQ h1900 flash.
 
index f8ce79b446ed8278a20bab97ec1160eca2f2b52d..02a03e67109c90ce2534757b4053ada8e8469956 100644 (file)
@@ -38,7 +38,6 @@ static struct mtd_info *h1910_nand_mtd = NULL;
  * Module stuff
  */
 
-#ifdef CONFIG_MTD_PARTITIONS
 /*
  * Define static partitions for flash device
  */
@@ -50,8 +49,6 @@ static struct mtd_partition partition_info[] = {
 
 #define NUM_PARTITIONS 1
 
-#endif
-
 /*
  *     hardware specific access to control-lines
  *
@@ -154,7 +151,7 @@ static int __init h1910_init(void)
 
        /* Register the partitions */
        printk(KERN_NOTICE "Using %s partition definition\n", part_type);
-       add_mtd_partitions(h1910_nand_mtd, mtd_parts, mtd_parts_nb);
+       mtd_device_register(h1910_nand_mtd, mtd_parts, mtd_parts_nb);
 
        /* Return happy */
        return 0;