mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-11 15:49:56 +00:00
f2fs: recover fallocated space
If a fallocated file is fsynced, we should recover the i_size after sudden power cut. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
parent
b6fe5873cb
commit
6fa1df533a
@ -682,6 +682,7 @@ static int expand_inode_data(struct inode *inode, loff_t offset,
|
||||
i_size_read(inode) < new_size) {
|
||||
i_size_write(inode, new_size);
|
||||
mark_inode_dirty(inode);
|
||||
f2fs_write_inode(inode, NULL);
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
Loading…
x
Reference in New Issue
Block a user