diff options
author | Jaegeuk Kim <jaegeuk@kernel.org> | 2014-09-03 02:43:52 +0400 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2014-09-10 00:14:25 +0400 |
commit | 2ae4c673e3cbd69bc2decf6d7f5961f3c7b9b38b (patch) | |
tree | 188caa86c0c0d885ffae218580f9bf6f489dbc3f /fs/f2fs/checkpoint.c | |
parent | 4081363fbe84a7ebac6d3339dd2775df45d856d0 (diff) | |
download | linux-2ae4c673e3cbd69bc2decf6d7f5961f3c7b9b38b.tar.xz |
f2fs: retain inconsistency information to initiate fsck.f2fs
This patch adds sbi->need_fsck to conduct fsck.f2fs later.
This flag can only be removed by fsck.f2fs.
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/checkpoint.c')
-rw-r--r-- | fs/f2fs/checkpoint.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/f2fs/checkpoint.c b/fs/f2fs/checkpoint.c index cb5cb4ca1814..5af97d99106e 100644 --- a/fs/f2fs/checkpoint.c +++ b/fs/f2fs/checkpoint.c @@ -882,6 +882,9 @@ static void do_checkpoint(struct f2fs_sb_info *sbi, bool is_umount) else clear_ckpt_flags(ckpt, CP_ORPHAN_PRESENT_FLAG); + if (sbi->need_fsck) + set_ckpt_flags(ckpt, CP_FSCK_FLAG); + /* update SIT/NAT bitmap */ get_sit_bitmap(sbi, __bitmap_ptr(sbi, SIT_BITMAP)); get_nat_bitmap(sbi, __bitmap_ptr(sbi, NAT_BITMAP)); |