Jaegeuk Kim cfb9a34d14 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>
2019-09-06 16:18:27 -07:00
..
2019-05-08 21:23:11 -07:00
2018-09-12 13:07:10 -07:00
2019-09-06 16:18:12 -07:00
2019-08-23 07:57:15 -07:00
2018-09-12 13:07:10 -07:00
2018-09-12 13:07:10 -07:00