projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
054afda
)
f2fs: fix return value in f2fs_ioc_commit_atomic_write
author
Chao Yu
<yuchao0@huawei.com>
Wed, 18 Apr 2018 09:45:02 +0000
(17:45 +0800)
committer
Jaegeuk Kim
<jaegeuk@kernel.org>
Thu, 31 May 2018 18:31:46 +0000
(11:31 -0700)
In f2fs_ioc_commit_atomic_write, if file is volatile, return -EINVAL to
indicate that commit failure.
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/file.c
patch
|
blob
|
history
diff --git
a/fs/f2fs/file.c
b/fs/f2fs/file.c
index 58f692b568b247ea8ff7e7e9db9bc2cd8064af50..d2b4145cb34e0a2394b6731008eb37ad3712c2f4 100644
(file)
--- a/
fs/f2fs/file.c
+++ b/
fs/f2fs/file.c
@@
-1726,8
+1726,10
@@
static int f2fs_ioc_commit_atomic_write(struct file *filp)
down_write(&F2FS_I(inode)->dio_rwsem[WRITE]);
- if (f2fs_is_volatile_file(inode))
+ if (f2fs_is_volatile_file(inode)) {
+ ret = -EINVAL;
goto err_out;
+ }
if (f2fs_is_atomic_file(inode)) {
ret = commit_inmem_pages(inode);