Commit b0d06afb authored by Peter Korsgaard's avatar Peter Korsgaard Committed by David Woodhouse

[MTD] cmdlinepart: Missing partition info is not an error

Return 0 partitions instead of -EINVAL on no mtdpart= argument in kernel
cmdline or missing partition info for device.
Signed-off-by: default avatarPeter Korsgaard <jacmet@sunsite.dk>
Acked-by: default avatarStefan Roese <sr@denx.de>
Signed-off-by: default avatarDavid Woodhouse <dwmw2@infradead.org>
parent c3f08b35
...@@ -310,9 +310,6 @@ static int parse_cmdline_partitions(struct mtd_info *master, ...@@ -310,9 +310,6 @@ static int parse_cmdline_partitions(struct mtd_info *master,
struct cmdline_mtd_partition *part; struct cmdline_mtd_partition *part;
char *mtd_id = master->name; char *mtd_id = master->name;
if(!cmdline)
return -EINVAL;
/* parse command line */ /* parse command line */
if (!cmdline_parsed) if (!cmdline_parsed)
mtdpart_setup_real(cmdline); mtdpart_setup_real(cmdline);
...@@ -343,7 +340,7 @@ static int parse_cmdline_partitions(struct mtd_info *master, ...@@ -343,7 +340,7 @@ static int parse_cmdline_partitions(struct mtd_info *master,
return part->num_parts; return part->num_parts;
} }
} }
return -EINVAL; return 0;
} }
......
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