aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/ceph/cache.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/ceph/cache.c b/fs/ceph/cache.c
index c737ae9893ef..d3b88c7518d0 100644
--- a/fs/ceph/cache.c
+++ b/fs/ceph/cache.c
@@ -374,8 +374,12 @@ out:
374 374
375void ceph_queue_revalidate(struct inode *inode) 375void ceph_queue_revalidate(struct inode *inode)
376{ 376{
377 struct ceph_fs_client *fsc = ceph_sb_to_client(inode->i_sb);
377 struct ceph_inode_info *ci = ceph_inode(inode); 378 struct ceph_inode_info *ci = ceph_inode(inode);
378 379
380 if (fsc->revalidate_wq == NULL || ci->fscache == NULL)
381 return;
382
379 ihold(inode); 383 ihold(inode);
380 384
381 if (queue_work(ceph_sb_to_client(inode->i_sb)->revalidate_wq, 385 if (queue_work(ceph_sb_to_client(inode->i_sb)->revalidate_wq,