summaryrefslogtreecommitdiffstats
path: root/fs/ceph/quota.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ceph/quota.c')
-rw-r--r--fs/ceph/quota.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/fs/ceph/quota.c b/fs/ceph/quota.c
index c4522212872c..d629fc857450 100644
--- a/fs/ceph/quota.c
+++ b/fs/ceph/quota.c
@@ -74,7 +74,8 @@ void ceph_handle_quota(struct ceph_mds_client *mdsc,
74 le64_to_cpu(h->max_files)); 74 le64_to_cpu(h->max_files));
75 spin_unlock(&ci->i_ceph_lock); 75 spin_unlock(&ci->i_ceph_lock);
76 76
77 iput(inode); 77 /* avoid calling iput_final() in dispatch thread */
78 ceph_async_iput(inode);
78} 79}
79 80
80static struct ceph_quotarealm_inode * 81static struct ceph_quotarealm_inode *
@@ -235,7 +236,8 @@ restart:
235 236
236 ci = ceph_inode(in); 237 ci = ceph_inode(in);
237 has_quota = __ceph_has_any_quota(ci); 238 has_quota = __ceph_has_any_quota(ci);
238 iput(in); 239 /* avoid calling iput_final() while holding mdsc->snap_rwsem */
240 ceph_async_iput(in);
239 241
240 next = realm->parent; 242 next = realm->parent;
241 if (has_quota || !next) 243 if (has_quota || !next)
@@ -372,7 +374,8 @@ restart:
372 pr_warn("Invalid quota check op (%d)\n", op); 374 pr_warn("Invalid quota check op (%d)\n", op);
373 exceeded = true; /* Just break the loop */ 375 exceeded = true; /* Just break the loop */
374 } 376 }
375 iput(in); 377 /* avoid calling iput_final() while holding mdsc->snap_rwsem */
378 ceph_async_iput(in);
376 379
377 next = realm->parent; 380 next = realm->parent;
378 if (exceeded || !next) 381 if (exceeded || !next)