Skip to content

Commit 6948482

Browse files
committed
crimson/os/seastore: set dirty root version to 1 during replay
Dirty extent version is supposed to be non-zero. Signed-off-by: Yingxin Cheng <[email protected]>
1 parent 7d58853 commit 6948482

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/crimson/os/seastore/cache.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1954,6 +1954,7 @@ Cache::replay_delta(
19541954
root->apply_delta_and_adjust_crc(record_base, delta.bl);
19551955
root->dirty_from_or_retired_at = journal_seq;
19561956
root->state = CachedExtent::extent_state_t::DIRTY;
1957+
root->version = 1; // shouldn't be 0 as a dirty extent
19571958
DEBUG("replayed root delta at {} {}, add extent -- {}, root={}",
19581959
journal_seq, record_base, delta, *root);
19591960
root->set_modify_time(modify_time);

0 commit comments

Comments
 (0)