mirror of
https://github.com/edk2-porting/linux-next.git
synced 2025-01-17 18:14:34 +08:00
UBI: Fastmap: Enhance fastmap checking
Don't update the fastmap upon detach if fastmap checking is enabled. This is poor men's power cut testing feature. :-) Signed-off-by: Richard Weinberger <richard@nod.at>
This commit is contained in:
parent
5fa7fa5dad
commit
24b7a347c3
@ -1114,7 +1114,10 @@ int ubi_detach_mtd_dev(int ubi_num, int anyway)
|
|||||||
ubi_msg(ubi, "detaching mtd%d", ubi->mtd->index);
|
ubi_msg(ubi, "detaching mtd%d", ubi->mtd->index);
|
||||||
#ifdef CONFIG_MTD_UBI_FASTMAP
|
#ifdef CONFIG_MTD_UBI_FASTMAP
|
||||||
/* If we don't write a new fastmap at detach time we lose all
|
/* If we don't write a new fastmap at detach time we lose all
|
||||||
* EC updates that have been made since the last written fastmap. */
|
* EC updates that have been made since the last written fastmap.
|
||||||
|
* In case of fastmap debugging we omit the update to simulate an
|
||||||
|
* unclean shutdown. */
|
||||||
|
if (!ubi_dbg_chk_fastmap(ubi))
|
||||||
ubi_update_fastmap(ubi);
|
ubi_update_fastmap(ubi);
|
||||||
#endif
|
#endif
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user