aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd
diff options
context:
space:
mode:
authorArtem Bityutskiy <Artem.Bityutskiy@nokia.com>2009-01-20 10:48:02 -0500
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>2009-01-20 11:13:53 -0500
commit8c4c19f1367435afdc16ac122a2a95a4d6cff9f0 (patch)
tree99cc2c9f6d2321b1ee55c339296c037ae4ec8c69 /drivers/mtd
parent3013ee31b6c5fd9a49a81816d6c13e1cdb7a1288 (diff)
UBI: remove unused variable
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/ubi/build.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c
index 9082768cc6c3..09a326ecd05b 100644
--- a/drivers/mtd/ubi/build.c
+++ b/drivers/mtd/ubi/build.c
@@ -380,7 +380,7 @@ static void free_user_volumes(struct ubi_device *ubi)
380 */ 380 */
381static int uif_init(struct ubi_device *ubi) 381static int uif_init(struct ubi_device *ubi)
382{ 382{
383 int i, err, do_free = 0; 383 int i, err;
384 dev_t dev; 384 dev_t dev;
385 385
386 sprintf(ubi->ubi_name, UBI_NAME_STR "%d", ubi->ubi_num); 386 sprintf(ubi->ubi_name, UBI_NAME_STR "%d", ubi->ubi_num);
@@ -427,13 +427,10 @@ static int uif_init(struct ubi_device *ubi)
427 427
428out_volumes: 428out_volumes:
429 kill_volumes(ubi); 429 kill_volumes(ubi);
430 do_free = 0;
431out_sysfs: 430out_sysfs:
432 ubi_sysfs_close(ubi); 431 ubi_sysfs_close(ubi);
433 cdev_del(&ubi->cdev); 432 cdev_del(&ubi->cdev);
434out_unreg: 433out_unreg:
435 if (do_free)
436 free_user_volumes(ubi);
437 unregister_chrdev_region(ubi->cdev.dev, ubi->vtbl_slots + 1); 434 unregister_chrdev_region(ubi->cdev.dev, ubi->vtbl_slots + 1);
438 ubi_err("cannot initialize UBI %s, error %d", ubi->ubi_name, err); 435 ubi_err("cannot initialize UBI %s, error %d", ubi->ubi_name, err);
439 return err; 436 return err;