]> git.baikalelectronics.ru Git - kernel.git/commit
ubi: fastmap: Check wl_pool for free peb before wear leveling
authorZhihao Cheng <chengzhihao1@huawei.com>
Tue, 10 May 2022 12:31:25 +0000 (20:31 +0800)
committerRichard Weinberger <richard@nod.at>
Fri, 27 May 2022 14:49:07 +0000 (16:49 +0200)
commitb2be21ccf55d01ba455413f31c771899ce519709
tree029651d653978cf6f28c767f4f43a2b4a29b25f6
parentcdbb1c9c5cc35f0d7e0a0788dfe71d0e5f8792a9
ubi: fastmap: Check wl_pool for free peb before wear leveling

UBI fetches free peb from wl_pool during wear leveling, so UBI should
check wl_pool's empty status before wear leveling. Otherwise, UBI will
miss wear leveling chances when free pebs are run out.

Signed-off-by: Zhihao Cheng <chengzhihao1@huawei.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
drivers/mtd/ubi/fastmap-wl.c
drivers/mtd/ubi/wl.c
drivers/mtd/ubi/wl.h