]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
include/ceph_fs: correct ceph_mds_cap_item field name
authorPatrick Donnelly <pdonnell@redhat.com>
Wed, 26 Jun 2024 13:49:17 +0000 (09:49 -0400)
committerPatrick Donnelly <pdonnell@ibm.com>
Thu, 9 Jan 2025 19:40:53 +0000 (14:40 -0500)
Originally, the last_sent sequence from the MDS was sent by the client during
bulk cap release but it was shortly after changed to the last_issue which is
the sequence number that the cap was originally "issued" by the MDS rank (which
may be updated after import of caps).

Fixes: 6208f57f487ac170df24a9018f1cc87a5ac8b4b3
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
(cherry picked from commit 655cddb7c9f32c9dd9cddf40ac17f385d539c8f9)

src/client/MetaSession.cc
src/include/ceph_fs.h
src/mds/Locker.cc

index b5160a84331b61e20c7c72ab1e425dc46bb74458..3baa833851fd98b76be55c48fce9e569f34fa997 100644 (file)
@@ -56,7 +56,7 @@ void MetaSession::enqueue_cap_release(inodeno_t ino, uint64_t cap_id, ceph_seq_t
   ceph_mds_cap_item i;
   i.ino = ino;
   i.cap_id = cap_id;
-  i.seq = iseq;
+  i.issue_seq = iseq;
   i.migrate_seq = mseq;
   release->caps.push_back(i);
 }
index 57eb18b0d3e5a720f74ba961eccf20eb9db4e63a..0ab4e46ed6815b29469e25158d21e86410bc35e5 100644 (file)
@@ -1057,7 +1057,7 @@ struct ceph_mds_cap_release {
 struct ceph_mds_cap_item {
        __le64 ino;
        __le64 cap_id;
-       __le32 migrate_seq, seq;
+       __le32 migrate_seq, issue_seq;
 } __attribute__ ((packed));
 
 #define CEPH_MDS_LEASE_REVOKE           1  /*    mds  -> client */
index b142848f164da32ff2a206e9a1df81e760a650f5..25c45b04825c45fd6452b1e86fefa4a07757e036 100644 (file)
@@ -4218,7 +4218,7 @@ void Locker::handle_client_cap_release(const cref_t<MClientCapRelease> &m)
   Session *session = mds->get_session(m);
 
   for (const auto &cap : m->caps) {
-    _do_cap_release(client, inodeno_t((uint64_t)cap.ino) , cap.cap_id, cap.migrate_seq, cap.seq);
+    _do_cap_release(client, inodeno_t((uint64_t)cap.ino) , cap.cap_id, cap.migrate_seq, cap.issue_seq);
   }
 
   if (session) {