aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/ubi/eba.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mtd/ubi/eba.c')
-rw-r--r--drivers/mtd/ubi/eba.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/mtd/ubi/eba.c b/drivers/mtd/ubi/eba.c
index e14208152c36..e04bcf1dff87 100644
--- a/drivers/mtd/ubi/eba.c
+++ b/drivers/mtd/ubi/eba.c
@@ -189,9 +189,7 @@ static struct ubi_ltree_entry *ltree_add_entry(struct ubi_device *ubi,
189 le->users += 1; 189 le->users += 1;
190 spin_unlock(&ubi->ltree_lock); 190 spin_unlock(&ubi->ltree_lock);
191 191
192 if (le_free) 192 kfree(le_free);
193 kfree(le_free);
194
195 return le; 193 return le;
196} 194}
197 195
@@ -503,9 +501,8 @@ static int recover_peb(struct ubi_device *ubi, int pnum, int vol_id, int lnum,
503 struct ubi_vid_hdr *vid_hdr; 501 struct ubi_vid_hdr *vid_hdr;
504 502
505 vid_hdr = ubi_zalloc_vid_hdr(ubi, GFP_NOFS); 503 vid_hdr = ubi_zalloc_vid_hdr(ubi, GFP_NOFS);
506 if (!vid_hdr) { 504 if (!vid_hdr)
507 return -ENOMEM; 505 return -ENOMEM;
508 }
509 506
510 mutex_lock(&ubi->buf_mutex); 507 mutex_lock(&ubi->buf_mutex);
511 508