From 51ba60cd47c318cca4476de9bfb12073f1c49a20 Mon Sep 17 00:00:00 2001 From: Samuel Just Date: Wed, 15 Jul 2020 16:22:56 -0700 Subject: [PATCH] crimson/os/seastore/transaction: drop retired extents from write_set and invalidate Signed-off-by: Samuel Just --- src/crimson/os/seastore/transaction.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/crimson/os/seastore/transaction.h b/src/crimson/os/seastore/transaction.h index 659d2b6b53c8e..8a01c99b7dee1 100644 --- a/src/crimson/os/seastore/transaction.h +++ b/src/crimson/os/seastore/transaction.h @@ -52,6 +52,10 @@ public: // which is what we want. retired_set.insert(ref); } + if (ref->is_pending()) { + write_set.erase(*ref); + ref->state = CachedExtent::extent_state_t::INVALID; + } } void add_to_read_set(CachedExtentRef ref) { -- 2.39.5