diff options
author | Yan, Zheng <zyan@redhat.com> | 2017-09-08 15:23:18 +0800 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2017-11-13 12:11:11 +0100 |
commit | 89aa593010135660991d05c92528c2c9163d5900 (patch) | |
tree | ca9baae50ad10f9523a290ec2f7081eca8257772 /fs/ceph/inode.c | |
parent | bebc6082da0a9f5d47a1ea2edc099bf671058bd4 (diff) |
ceph: keep auth cap when inode has flocks or posix locks
file locks are tracked by inode's auth mds. dropping auth caps
is equivalent to releasing all file locks.
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Acked-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'fs/ceph/inode.c')
-rw-r--r-- | fs/ceph/inode.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/ceph/inode.c b/fs/ceph/inode.c index f2550a076edc..6301bf299b7c 100644 --- a/fs/ceph/inode.c +++ b/fs/ceph/inode.c @@ -493,6 +493,7 @@ struct inode *ceph_alloc_inode(struct super_block *sb) ci->i_wb_ref = 0; ci->i_wrbuffer_ref = 0; ci->i_wrbuffer_ref_head = 0; + atomic_set(&ci->i_filelock_ref, 0); ci->i_shared_gen = 0; ci->i_rdcache_gen = 0; ci->i_rdcache_revoking = 0; |