hc
2024-09-20 cf4ce59b3b70238352c7f1729f0f7223214828ad
kernel/fs/ceph/locks.c
....@@ -32,18 +32,14 @@
3232
3333 static void ceph_fl_copy_lock(struct file_lock *dst, struct file_lock *src)
3434 {
35
- struct ceph_file_info *fi = dst->fl_file->private_data;
3635 struct inode *inode = file_inode(dst->fl_file);
3736 atomic_inc(&ceph_inode(inode)->i_filelock_ref);
38
- atomic_inc(&fi->num_locks);
3937 }
4038
4139 static void ceph_fl_release_lock(struct file_lock *fl)
4240 {
43
- struct ceph_file_info *fi = fl->fl_file->private_data;
4441 struct inode *inode = file_inode(fl->fl_file);
4542 struct ceph_inode_info *ci = ceph_inode(inode);
46
- atomic_dec(&fi->num_locks);
4743 if (atomic_dec_and_test(&ci->i_filelock_ref)) {
4844 /* clear error when all locks are released */
4945 spin_lock(&ci->i_ceph_lock);