UBI: Fastmap: Do not add vol if it already exists
authorshengyong <shengyong1@huawei.com>
Tue, 26 May 2015 10:07:09 +0000 (10:07 +0000)
committerRichard Weinberger <richard@nod.at>
Tue, 2 Jun 2015 09:46:14 +0000 (11:46 +0200)
commite96a8a3bb671ca02370e85993c3f50ee90691b95
tree8ee2566efd1050a349951651fb05b95a62b94382
parente8d266cf8d24e52eac65bdab24afd6f4cfc0ad07
UBI: Fastmap: Do not add vol if it already exists

During fastmap attaching, check if a volume already exists when adding
the volume to volume tree. NOTE that the issue cannot happen, only if
the on-flash fastmap data is modified.

Signed-off-by: Sheng Yong <shengyong1@huawei.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
drivers/mtd/ubi/fastmap.c