summaryrefslogtreecommitdiffstats
path: root/fs/f2fs
diff options
context:
space:
mode:
authorYunlei He <heyunlei@huawei.com>2018-04-24 11:40:19 +0800
committerJaegeuk Kim <jaegeuk@kernel.org>2018-05-31 11:31:48 -0700
commitcba41be08cb182476fec4d318a8a8f2f8361a901 (patch)
tree659f2c241483d4f6a05005c1cf6ea4a689a24bbc /fs/f2fs
parentade990f95eed818d24d6b6d48f4b4af0aaf55d97 (diff)
downloadlinux-cba41be08cb182476fec4d318a8a8f2f8361a901.tar.bz2
f2fs: fix missing clear FI_NO_PREALLOC in some error case
This patch fix missing clear FI_NO_PREALLOC in some error case Signed-off-by: Yunlei He <heyunlei@huawei.com> Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs')
-rw-r--r--fs/f2fs/file.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c
index ac6452261926..a68b2cc067bc 100644
--- a/fs/f2fs/file.c
+++ b/fs/f2fs/file.c
@@ -2925,6 +2925,8 @@ static ssize_t f2fs_file_write_iter(struct kiocb *iocb, struct iov_iter *from)
iov_iter_count(from)) ||
f2fs_has_inline_data(inode) ||
f2fs_force_buffered_io(inode, WRITE)) {
+ clear_inode_flag(inode,
+ FI_NO_PREALLOC);
inode_unlock(inode);
return -EAGAIN;
}