From: chentao.2022 Date: Mon, 5 Aug 2024 15:38:50 +0000 (+0800) Subject: cephfs: Fixed a bug that read operation hung in Client::get_caps when the... X-Git-Tag: v19.2.3~456^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=b333c18f8ea779047142ef8cb55d05303d942166;p=ceph.git cephfs: Fixed a bug that read operation hung in Client::get_caps when the Fc caps is wanted but revoked by the mds, and the Fc cap refs is no-zero Fixes: https://tracker.ceph.com/issues/65971 Signed-off-by: Tod Chen (cherry picked from commit 7f723017454957f3e4e1dbb4613bcf94afa4151e) --- diff --git a/src/client/Client.cc b/src/client/Client.cc index 67a1f65b4f8a..f97bff9b9ad3 100644 --- a/src/client/Client.cc +++ b/src/client/Client.cc @@ -3620,6 +3620,9 @@ void Client::put_cap_ref(Inode *in, int cap) if (last & CEPH_CAP_FILE_CACHE) { ldout(cct, 5) << __func__ << " dropped last FILE_CACHE ref on " << *in << dendl; ++put_nref; + + ldout(cct, 10) << __func__ << " calling signal_caps_inode" << dendl; + signal_caps_inode(in); } if (drop) check_caps(in, 0);