summaryrefslogtreecommitdiff
path: root/fs/ceph/file.c
diff options
context:
space:
mode:
authorSage Weil <sage@inktank.com>2013-02-05 13:52:29 -0800
committerYan, Zheng <zheng.z.yan@intel.com>2014-04-03 10:33:52 +0800
commit752c8bdcfe88f27a17c5c9264df928fd145a4b30 (patch)
tree755eb2453b772e826113fe30d9184870efb012c0 /fs/ceph/file.c
parent180061a58c17681dd236e5059ba57fe092dbe368 (diff)
ceph: do not chain inode updates to parent fsync
The fsync(dirfd) only covers namespace operations, not inode updates. We do not need to cover setattr variants or O_TRUNC. Reported-by: Al Viro <viro@xeniv.linux.org.uk> Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Yan, Zheng <zheng.z.yan@intel.com>
Diffstat (limited to 'fs/ceph/file.c')
-rw-r--r--fs/ceph/file.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ceph/file.c b/fs/ceph/file.c
index 09c7afe32e49..c298a7b8a1ce 100644
--- a/fs/ceph/file.c
+++ b/fs/ceph/file.c
@@ -210,7 +210,7 @@ int ceph_open(struct inode *inode, struct file *file)
ihold(inode);
req->r_num_caps = 1;
- if (flags & (O_CREAT|O_TRUNC))
+ if (flags & O_CREAT)
parent_inode = ceph_get_dentry_parent_inode(file->f_dentry);
err = ceph_mdsc_do_request(mdsc, parent_inode, req);
iput(parent_inode);