Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3a3a5ead authored by Jaegeuk Kim's avatar Jaegeuk Kim
Browse files

f2fs: do not recover i_size if it's valid



If i_size is already valid during roll_forward recovery, we should not update
it according to the block alignment.

Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
parent 281518c6
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -425,7 +425,7 @@ static int do_recover_data(struct f2fs_sb_info *sbi, struct inode *inode,
			continue;
		}

		if ((start + 1) << PAGE_SHIFT > i_size_read(inode))
		if (i_size_read(inode) <= (start << PAGE_SHIFT))
			f2fs_i_size_write(inode, (start + 1) << PAGE_SHIFT);

		/*