summaryrefslogtreecommitdiff
path: root/fs/f2fs/data.c
diff options
context:
space:
mode:
authorJaegeuk Kim <jaegeuk@kernel.org>2015-12-22 19:09:35 (GMT)
committerJaegeuk Kim <jaegeuk@kernel.org>2015-12-30 18:14:05 (GMT)
commitb9d777b85ff1ff79a1173190317b25bebc404ab4 (patch)
tree4dd136b8c0423360babeae2ea7eebb5ac049a4da /fs/f2fs/data.c
parent74fd8d9927ef08db30a85f131a124152aeba66c7 (diff)
downloadlinux-b9d777b85ff1ff79a1173190317b25bebc404ab4.tar.xz
f2fs: check inline_data flag at converting time
We can check inode's inline_data flag when calling to convert it. Reviewed-by: Chao Yu <chao2.yu@samsung.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/data.c')
-rw-r--r--fs/f2fs/data.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c
index e34b1bd..cf0c9dd 100644
--- a/fs/f2fs/data.c
+++ b/fs/f2fs/data.c
@@ -1573,11 +1573,9 @@ static ssize_t f2fs_direct_IO(struct kiocb *iocb, struct iov_iter *iter,
int err;
/* we don't need to use inline_data strictly */
- if (f2fs_has_inline_data(inode)) {
- err = f2fs_convert_inline_inode(inode);
- if (err)
- return err;
- }
+ err = f2fs_convert_inline_inode(inode);
+ if (err)
+ return err;
if (f2fs_encrypted_inode(inode) && S_ISREG(inode->i_mode))
return 0;