UBI: fix nameless volumes handling
commit028bb43eac25b7423198b7e22cfea9bd3e870e24
authorRichard Weinberger <richard@nod.at>
Fri, 13 Jan 2012 14:07:40 +0000 (13 15:07 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 26 Jan 2012 01:24:44 +0000 (25 17:24 -0800)
tree9c0bf7a7ca2e60deeb0e77855b009500827746bb
parent59c43b2c3ef410e585646825ea552507cd51ccb1
UBI: fix nameless volumes handling

commit 4a59c797a18917a5cf3ff7ade296b46134d91e6a upstream.

Currently it's possible to create a volume without a name. E.g:
ubimkvol -n 32 -s 2MiB -t static /dev/ubi0 -N ""

After that vtbl_check() will always fail because it does not permit
empty strings.

Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/mtd/ubi/cdev.c