]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/os/seastore/btree: misc consolidations
authorXuehan Xu <xuxuehan@qianxin.com>
Thu, 29 Feb 2024 06:06:35 +0000 (14:06 +0800)
committerXuehan Xu <xuxuehan@qianxin.com>
Mon, 20 May 2024 03:19:54 +0000 (11:19 +0800)
Signed-off-by: Xuehan Xu <xuxuehan@qianxin.com>
src/crimson/os/seastore/btree/fixed_kv_btree.h
src/crimson/os/seastore/lba_manager/btree/lba_btree_node.h

index 7247bbb82b385bfc23e9a1ef3ee913a31922a76a..e1b81d8ac6619207d76e8162fcbe9c0d094ea229 100644 (file)
@@ -592,6 +592,15 @@ public:
                 : true);
             }
           }
+        } else if (child == get_reserved_ptr()) {
+          if constexpr(
+            !std::is_base_of_v<typename internal_node_t::base_t,
+                               child_node_t>) {
+            assert(i->get_val().pladdr.is_paddr());
+            assert(i->get_val().pladdr.get_paddr() == P_ADDR_ZERO);
+          } else {
+            ceph_abort();
+          }
         }
       } else {
         ceph_abort("impossible");
index 73aa77ab0a5573ab59a5da9f0334649cb411f7f0..c5da860e24ff8c5493474eaaa6417ff5eac17cb6 100644 (file)
@@ -171,6 +171,8 @@ struct LBALeafNode
 
     for (auto i : *this) {
       auto child = (LogicalCachedExtent*)this->children[i.get_offset()];
+      // Children may not be marked as stable yet,
+      // the specific order is undefined in the transaction prepare record phase.
       if (is_valid_child_ptr(child) && child->get_laddr() != i.get_key()) {
        SUBERROR(seastore_fixedkv_tree,
          "stable child not valid: child {}, key {}",