]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/os/seastore/cached_extent: adjust
authorXuehan Xu <xuxuehan@qianxin.com>
Thu, 29 Feb 2024 06:16:37 +0000 (14:16 +0800)
committerMatan Breizman <mbreizma@redhat.com>
Mon, 17 Jun 2024 15:34:08 +0000 (18:34 +0300)
CachedExtent::on_replace_prior()

Signed-off-by: Xuehan Xu <xuxuehan@qianxin.com>
(cherry picked from commit d4c78f1524bebfa3f370f5a4a019800dfeaf04f1)

src/crimson/os/seastore/btree/fixed_kv_node.h
src/crimson/os/seastore/cache.cc
src/crimson/os/seastore/cached_extent.cc
src/crimson/os/seastore/cached_extent.h
src/crimson/os/seastore/root_block.cc
src/crimson/os/seastore/root_block.h

index 31b9067a7443934d1577578de56c54f19e678e55..a3a9569a669515f46206ce976cf7568de915af2d 100644 (file)
@@ -727,7 +727,7 @@ struct FixedKVInternalNode
     return CachedExtentRef(new node_type_t(*this));
   };
 
-  void on_replace_prior(Transaction&) final {
+  void on_replace_prior() final {
     ceph_assert(!this->is_rewrite());
     this->set_children_from_prior_instance();
     auto &prior = (this_type_t&)(*this->get_prior_instance());
@@ -1119,7 +1119,7 @@ struct FixedKVLeafNode
       true);
   }
 
-  void on_replace_prior(Transaction&) final {
+  void on_replace_prior() final {
     ceph_assert(!this->is_rewrite());
     if constexpr (has_children) {
       this->set_children_from_prior_instance();
index 75715f322681b9d8dcb9ac24c0cb72239c6baa51..f85bafb4c7433b175bc8d8243cb39e68138db581 100644 (file)
@@ -829,7 +829,7 @@ void Cache::commit_replace_extent(
     add_to_dirty(next);
   }
 
-  next->on_replace_prior(t);
+  next->on_replace_prior();
   invalidate_extent(t, *prev);
 }
 
index 37884227186f399f8405609ee5dc23dd52a9ed40..cdad6dfb1b03d80bc9dcb29f0c845b2be0615317 100644 (file)
@@ -137,7 +137,7 @@ LogicalCachedExtent::~LogicalCachedExtent() {
   }
 }
 
-void LogicalCachedExtent::on_replace_prior(Transaction &t) {
+void LogicalCachedExtent::on_replace_prior() {
   assert(is_mutation_pending());
   take_prior_parent_tracker();
   assert(get_parent_node());
index e259a24a79f6fdee657afec3e70e03f89e4fca0e..f00686c6f9aad60deb1032275cb17e6e82a09dc5 100644 (file)
@@ -281,7 +281,7 @@ public:
    * with the states of Cache and can't wait till transaction
    * completes.
    */
-  virtual void on_replace_prior(Transaction &t) {}
+  virtual void on_replace_prior() {}
 
   /**
    * on_invalidated
@@ -1309,7 +1309,7 @@ public:
   virtual ~LogicalCachedExtent();
 
 protected:
-  void on_replace_prior(Transaction &t) final;
+  void on_replace_prior() final;
 
   virtual void apply_delta(const ceph::bufferlist &bl) = 0;
 
index 5b8e0ca5d1f8809a8e39cb8f0d2c421d02fe1c47..dec6e12ea4e5489c819af428df5f2cf12b920c40 100644 (file)
@@ -7,7 +7,7 @@
 
 namespace crimson::os::seastore {
 
-void RootBlock::on_replace_prior(Transaction &t) {
+void RootBlock::on_replace_prior() {
   if (!lba_root_node) {
     auto &prior = static_cast<RootBlock&>(*get_prior_instance());
     if (prior.lba_root_node) {
index 6d4da5756b8a17c56ee518eece749fa3310ad5ba..a9a7cd1982210734d95bdfa311912f8854c260ff 100644 (file)
@@ -61,7 +61,7 @@ struct RootBlock : CachedExtent {
     return extent_types_t::ROOT;
   }
 
-  void on_replace_prior(Transaction &t) final;
+  void on_replace_prior() final;
 
   /// dumps root as delta
   ceph::bufferlist get_delta() final {