projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
68e3226
)
UBI: Fastmap: Fix leb_count unbalance
author
Richard Weinberger
<richard@nod.at>
Fri, 24 Oct 2014 13:22:05 +0000
(15:22 +0200)
committer
Richard Weinberger
<richard@nod.at>
Thu, 26 Mar 2015 21:46:00 +0000
(22:46 +0100)
If a LEB is unmapped we have to decrement leb_count as well.
Signed-off-by: Richard Weinberger <richard@nod.at>
drivers/mtd/ubi/fastmap.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/mtd/ubi/fastmap.c
b/drivers/mtd/ubi/fastmap.c
index 3d913f53fd06d016f15dd86663a5dfdd3f3f0ad3..5db41a5fdd7a8b6bbc990444b1e3fae2ad816729 100644
(file)
--- a/
drivers/mtd/ubi/fastmap.c
+++ b/
drivers/mtd/ubi/fastmap.c
@@
-362,6
+362,7
@@
static void unmap_peb(struct ubi_attach_info *ai, int pnum)
aeb = rb_entry(node2, struct ubi_ainf_peb, u.rb);
if (aeb->pnum == pnum) {
rb_erase(&aeb->u.rb, &av->root);
+ av->leb_count--;
kmem_cache_free(ai->aeb_slab_cache, aeb);
return;
}