All of lore.kernel.org
 help / color / mirror / Atom feed
* UBIFS: ubifs_recover_leb() always execute fix_unclean_leb() even all the nodes are valid
@ 2021-12-24  7:58 韩仁杰
  2021-12-25  2:23 ` Zhihao Cheng
  0 siblings, 1 reply; 4+ messages in thread
From: 韩仁杰 @ 2021-12-24  7:58 UTC (permalink / raw)
  To: linux-mtd

I've been working on Linux 4.4.60 recently When using UBIFS file system,

I recently encountered a problem that every time I power off and restart,

I will enter the recovery process of UBIFS.



I do understand the reason for entering recovery during startup, and the

main  purpose of ubifs_recover_leb() is to deal with an invalid node and

make ubifs mount successfully. But even if there are no invalid nodes,

ubifs_recover_leb() will call  fix_unclean_leb(), which results in flash’s erase

and write operations during startup.



I checked the modify history of kernel/fs/ubifs/recovery.c, and found a related

commit:

  http://git.infradead.org/linux.git/commitdiff/7c47bfd0dbb20e5d7fa4e37cfd76bb7

3d39b32b4?hp=617992069513c1e789c707c4d75ff03bf7dd0fb0.



In the commit, variable "need_clean" was deleted. My question is that
whether it is

necessary to execute fix_unclean_leb() if there are no invalid node ?
I am not sure if

there are some additional considerations I didn't think of ?



Thank you very much for any insight you can provide



-Han Renjie

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-01-04  4:01 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-24  7:58 UBIFS: ubifs_recover_leb() always execute fix_unclean_leb() even all the nodes are valid 韩仁杰
2021-12-25  2:23 ` Zhihao Cheng
2021-12-29 15:26   ` 韩仁杰
2022-01-04  4:00     ` Zhihao Cheng

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.