]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
mds: fix code review comments
authorIgor Golikov <igolikov@redhat.com>
Wed, 18 Feb 2026 14:00:04 +0000 (14:00 +0000)
committerIgor Golikov <igolikov@redhat.com>
Wed, 18 Feb 2026 14:00:04 +0000 (14:00 +0000)
Signed-off-by: Igor Golikov <igolikov@redhat.com>
Fixes: https://tracker.ceph.com/issues/74135
Fixes: https://tracker.ceph.com/issues/73700
src/mds/MDCache.cc

index 3b267cb967c913307061d88ff0ffb5932232bfd2..38ac9ce979adcb1ec58e27281819833b574fb7fa 100644 (file)
@@ -2128,13 +2128,7 @@ void MDCache::broadcast_quota_to_client(CInode *in, client_t exclude_ct, bool qu
     return;
 
   const auto& pi = in->get_projected_inode();
-
-  // create snaprealm for quota inode (quota was set before mimic)
-  if (!in->get_projected_srnode())
-    mds->server->create_quota_realm(in);
-
   inodeno_t subvolume_id = in->get_subvolume_id();
-
   dout(10) << __func__ << " ino " << in->ino()
            << " subvol " << subvolume_id
            << " quota_enabled=" << pi->quota.is_enabled()
@@ -2161,6 +2155,10 @@ void MDCache::broadcast_quota_to_client(CInode *in, client_t exclude_ct, bool qu
   if (!pi->quota.is_enabled() && !quota_change)
     return;
 
+  // create snaprealm for quota inode (quota was set before mimic)
+  if (!in->get_projected_srnode())
+    mds->server->create_quota_realm(in);
+
   for (auto &p : in->client_caps) {
     Capability *cap = &p.second;
     if (cap->is_noquota())