]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson: fix remove_from_lru assert 44740/head
authorchunmei-liu <chunmei.liu@intel.com>
Mon, 24 Jan 2022 17:12:00 +0000 (09:12 -0800)
committerchunmei-liu <chunmei.liu@intel.com>
Mon, 24 Jan 2022 17:12:00 +0000 (09:12 -0800)
RETIRED_PLACEHOLDER extent also put into retired set, when do
commit_retire_extent need check if it is RETIRED_PLACEHOLDER,
otherwise will cause remove_from_lru assert.

Signed-off-by: chunmei-liu <chunmei.liu@intel.com>
src/crimson/os/seastore/cache.cc

index 39ac510b96b9ad484021b3f0de8a1613ed02414b..692cb0e585982274f88992b06695a0ec92a1881b 100644 (file)
@@ -673,7 +673,7 @@ void Cache::remove_extent(CachedExtentRef ref)
   assert(ref->is_valid());
   if (ref->is_dirty()) {
     remove_from_dirty(ref);
-  } else {
+  } else if (!ref->is_placeholder()) {
     lru.remove_from_lru(*ref);
   }
   extents.erase(*ref);