]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/os/seastore/lba_manager: extents pass to LBALeafNode::update()
authorXuehan Xu <xuxuehan@qianxin.com>
Wed, 28 Feb 2024 08:00:23 +0000 (16:00 +0800)
committerXuehan Xu <xuxuehan@qianxin.com>
Mon, 20 May 2024 03:12:44 +0000 (11:12 +0800)
must either has a null parent tracker or point to the current leaf node

Signed-off-by: Xuehan Xu <xuxuehan@qianxin.com>
src/crimson/os/seastore/lba_manager/btree/lba_btree_node.h

index 3b760ff06a24e95843d46aeb5f773b25c37fa35c..73aa77ab0a5573ab59a5da9f0334649cb411f7f0 100644 (file)
@@ -194,7 +194,11 @@ struct LBALeafNode
        iter.get_offset(),
        *nextent);
       // child-ptr may already be correct, see LBAManager::update_mappings()
-      this->update_child_ptr(iter, nextent);
+      if (!nextent->has_parent_tracker()) {
+       this->update_child_ptr(iter, nextent);
+      }
+      assert(nextent->has_parent_tracker()
+       && nextent->get_parent_node<LBALeafNode>().get() == this);
     }
     if (val.pladdr.is_paddr()) {
       val.pladdr = maybe_generate_relative(val.pladdr.get_paddr());