From: Greg Farnum Date: Wed, 25 Nov 2015 22:21:38 +0000 (-0800) Subject: Merge branch 'wip-13800' of git://github.com/ukernel/ceph X-Git-Tag: v10.0.2~186 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=5090744560931a16322a73d302fb30dda30d90a8;p=ceph.git Merge branch 'wip-13800' of git://github.com/ukernel/ceph client: fix deadlock related to async pagecache invalidation Conflicts: src/client/Client.cc Fixed a conflict with the earlier page cache invalidate changes in 73beb7f9378182cc3901fe86c4f1f5d5d98169a6. Reviewed-by: Greg Farnum --- 5090744560931a16322a73d302fb30dda30d90a8 diff --cc src/client/Client.cc index e6c48bbeaa3,e19e2d693f8..c39ff6438b7 --- a/src/client/Client.cc +++ b/src/client/Client.cc @@@ -2863,9 -2857,15 +2863,9 @@@ void Client::put_cap_ref(Inode *in, in if (last & CEPH_CAP_FILE_CACHE) { ldout(cct, 5) << "put_cap_ref dropped last FILE_CACHE ref on " << *in << dendl; ++put_nref; - // release clean pages too, if we dont want RDCACHE - if (!(in->caps_wanted() & CEPH_CAP_FILE_CACHE)) - drop |= CEPH_CAP_FILE_CACHE; } - if (drop) { - if (drop & CEPH_CAP_FILE_CACHE) - _invalidate_inode_cache(in); + if (drop) - check_caps(in, false); + check_caps(in, false); - } if (put_nref) put_inode(in, put_nref); }