]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/os/seastore: misc adjustments 62633/head
authorYingxin Cheng <yingxin.cheng@intel.com>
Wed, 2 Apr 2025 06:32:19 +0000 (14:32 +0800)
committerYingxin Cheng <yingxin.cheng@intel.com>
Thu, 3 Apr 2025 02:20:35 +0000 (10:20 +0800)
Signed-off-by: Yingxin Cheng <yingxin.cheng@intel.com>
src/crimson/os/seastore/lba_manager/btree/btree_lba_manager.cc
src/crimson/os/seastore/transaction_manager.h

index 0062d8efc8dccaa3e17cc83b2e2c4e8f46e1d1a4..a14e18a56c214f4e2f20d5e033982b3c2461d4e1 100644 (file)
@@ -435,13 +435,16 @@ BtreeLBAManager::_alloc_extents(
              ceph_assert(alloc_info.val.is_paddr());
              assert(alloc_info.val == iter.get_val().pladdr);
              assert(alloc_info.len == iter.get_val().len);
+             assert(alloc_info.extent->is_logical());
              if (alloc_info.extent->has_laddr()) {
+               // see TM::remap_pin()
                assert(alloc_info.key == alloc_info.extent->get_laddr());
                assert(alloc_info.key == iter.get_key());
              } else {
+               // see TM::alloc_non_data_extent()
+               //     TM::alloc_data_extents()
                alloc_info.extent->set_laddr(iter.get_key());
              }
-             alloc_info.extent->set_laddr(iter.get_key());
            }
            ceph_assert(inserted);
            rets.emplace_back(iter.get_pin(c));
index 978e28d99c403cab0d490b9d5fd11f2fa3836eaa..62880df08383b294294ad93e92771ffe5b0483a5 100644 (file)
@@ -210,9 +210,9 @@ public:
     ).si_then([this, FNAME, &t, offset, length] (auto pin)
       -> read_extent_ret<T> {
       if (length != pin->get_length() || !pin->get_val().is_real()) {
-        SUBERRORT(seastore_tm, "{}~0x{:x} {} got wrong {}",
+        SUBERRORT(seastore_tm, "{}~0x{:x} {} got wrong pin {}",
                   t, offset, length, T::TYPE, *pin);
-        ceph_assert(0 == "Should be impossible");
+        ceph_abort("Impossible");
       }
       return this->read_pin<T>(t, std::move(pin));
     });
@@ -235,9 +235,9 @@ public:
     ).si_then([this, FNAME, &t, offset] (auto pin)
       -> read_extent_ret<T> {
       if (!pin->get_val().is_real()) {
-        SUBERRORT(seastore_tm, "{} {} got wrong {}",
+        SUBERRORT(seastore_tm, "{} {} got wrong pin {}",
                   t, offset, T::TYPE, *pin);
-        ceph_assert(0 == "Should be impossible");
+        ceph_abort("Impossible");
       }
       return this->read_pin<T>(t, std::move(pin));
     });