crimson/seastore: fix segment_cleaner blocked_io_wake crash
Reviewed-by: Xuehan Xu <xxhdx1985126@gmail.com>
std::for_each(inline_block_list.begin(), inline_block_list.end(), f);
}
- auto get_num_fresh_blocks() const {
- return inline_block_list.size() + ool_block_list.size();
+ struct io_stat_t {
+ uint64_t num = 0;
+ uint64_t bytes = 0;
+ };
+ const io_stat_t& get_fresh_block_stats() const {
+ return fresh_block_stats;
}
+ size_t get_allocation_size() const {
+ size_t ret = 0;
+ for_each_fresh_block([&ret](auto &e) { ret += e->get_length(); });
+ return ret;
+ }
+
enum class src_t : uint8_t {
MUTATE = 0,
READ, // including weak and non-weak read transactions