Commit Message

From: David Brownell <dbrownell@users.sourceforge.net>
Move mtd_has_partitions() and mtd_has_cmdlinepart() inlines from a
DaVinci-specific driver to the <linux/mtd/partitions.h> header.
Use those to eliminate #ifdefs in two drivers which had their own
definitions of mtd_has_partitions().
Quite a lot of other MTD drivers could benefit from using use one or both
of these to remove #ifdeffery. Maybe some Janitors would like to help.
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
drivers/mtd/devices/m25p80.c | 17 ++++++-----------
drivers/mtd/devices/mtd_dataflash.c | 16 ++++++----------
drivers/mtd/nand/davinci_nand.c | 13 -------------
include/linux/mtd/partitions.h | 12 ++++++++++++
4 files changed, 24 insertions(+), 34 deletions(-)