UBI: remove unused variable
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
This commit is contained in:
@@ -380,7 +380,7 @@ static void free_user_volumes(struct ubi_device *ubi)
|
|||||||
*/
|
*/
|
||||||
static int uif_init(struct ubi_device *ubi)
|
static int uif_init(struct ubi_device *ubi)
|
||||||
{
|
{
|
||||||
int i, err, do_free = 0;
|
int i, err;
|
||||||
dev_t dev;
|
dev_t dev;
|
||||||
|
|
||||||
sprintf(ubi->ubi_name, UBI_NAME_STR "%d", ubi->ubi_num);
|
sprintf(ubi->ubi_name, UBI_NAME_STR "%d", ubi->ubi_num);
|
||||||
@@ -427,13 +427,10 @@ static int uif_init(struct ubi_device *ubi)
|
|||||||
|
|
||||||
out_volumes:
|
out_volumes:
|
||||||
kill_volumes(ubi);
|
kill_volumes(ubi);
|
||||||
do_free = 0;
|
|
||||||
out_sysfs:
|
out_sysfs:
|
||||||
ubi_sysfs_close(ubi);
|
ubi_sysfs_close(ubi);
|
||||||
cdev_del(&ubi->cdev);
|
cdev_del(&ubi->cdev);
|
||||||
out_unreg:
|
out_unreg:
|
||||||
if (do_free)
|
|
||||||
free_user_volumes(ubi);
|
|
||||||
unregister_chrdev_region(ubi->cdev.dev, ubi->vtbl_slots + 1);
|
unregister_chrdev_region(ubi->cdev.dev, ubi->vtbl_slots + 1);
|
||||||
ubi_err("cannot initialize UBI %s, error %d", ubi->ubi_name, err);
|
ubi_err("cannot initialize UBI %s, error %d", ubi->ubi_name, err);
|
||||||
return err;
|
return err;
|
||||||
|
Reference in New Issue
Block a user