diff options
-rw-r--r-- | drivers/mtd/ubi/build.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c index 9b94427be145..b85ca186afc6 100644 --- a/drivers/mtd/ubi/build.c +++ b/drivers/mtd/ubi/build.c | |||
@@ -845,6 +845,9 @@ static int __init ubi_mtd_param_parse(const char *val, struct kernel_param *kp) | |||
845 | char *pbuf = &buf[0]; | 845 | char *pbuf = &buf[0]; |
846 | char *tokens[3] = {NULL, NULL, NULL}; | 846 | char *tokens[3] = {NULL, NULL, NULL}; |
847 | 847 | ||
848 | if (!val) | ||
849 | return -EINVAL; | ||
850 | |||
848 | if (mtd_devs == UBI_MAX_DEVICES) { | 851 | if (mtd_devs == UBI_MAX_DEVICES) { |
849 | printk("UBI error: too many parameters, max. is %d\n", | 852 | printk("UBI error: too many parameters, max. is %d\n", |
850 | UBI_MAX_DEVICES); | 853 | UBI_MAX_DEVICES); |