Commits
Jaegeuk Kim committed cfb9a34d147
f2fs: convert inline_data in prior to i_size_write In below call path, we change i_size before inline conversion, however, if we failed to convert inline inode, the inode may have wrong i_size which is larger than max inline size, result inline inode corruption. - f2fs_setattr - truncate_setsize - f2fs_convert_inline_inode This patch reorders truncate_setsize() and f2fs_convert_inline_inode() to guarantee inline_data has valid i_size. Fixes: 0cab80ee0c9e ("f2fs: fix to convert inline inode in ->setattr") Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>