Commit 11b73c8b authored by Jamie Iles's avatar Jamie Iles Committed by David Woodhouse

mtd: provide of_mtd_parse_partitions for !CONFIG_MTD_OF_PARTS

If we don't have OpenFirmware enabled then provide a stub
of_mtd_parse_partitions that returns no partitions so drivers don't need
ifdeffery inside.
Signed-off-by: default avatarJamie Iles <jamie@jamieiles.com>
Signed-off-by: default avatarArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Signed-off-by: default avatarDavid Woodhouse <David.Woodhouse@intel.com>
parent f5671ab3
...@@ -73,9 +73,18 @@ extern int parse_mtd_partitions(struct mtd_info *master, const char **types, ...@@ -73,9 +73,18 @@ extern int parse_mtd_partitions(struct mtd_info *master, const char **types,
struct device; struct device;
struct device_node; struct device_node;
#ifdef CONFIG_MTD_OF_PARTS
int __devinit of_mtd_parse_partitions(struct device *dev, int __devinit of_mtd_parse_partitions(struct device *dev,
struct device_node *node, struct device_node *node,
struct mtd_partition **pparts); struct mtd_partition **pparts);
#else
static inline int of_mtd_parse_partitions(struct device *dev,
struct device_node *node,
struct mtd_partition **pparts)
{
return 0;
}
#endif
#ifdef CONFIG_MTD_PARTITIONS #ifdef CONFIG_MTD_PARTITIONS
static inline int mtd_has_partitions(void) { return 1; } static inline int mtd_has_partitions(void) { return 1; }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment