[metadata_dumper] Support dump a bottom-level data mapping tree
This commit is contained in:
parent
7ec47158b5
commit
ced9929ca6
@ -244,3 +244,14 @@ thin_provisioning::metadata_dump(metadata::ptr md, emitter::ptr e, bool repair)
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------
|
||||
|
||||
void
|
||||
thin_provisioning::metadata_dump_subtree(metadata::ptr md, emitter::ptr e, bool repair, uint64_t subtree_root) {
|
||||
mapping_emitter me(e);
|
||||
single_mapping_tree tree(*md->tm_, subtree_root,
|
||||
mapping_tree_detail::block_time_ref_counter(md->data_sm_));
|
||||
walk_mapping_tree(tree, static_cast<mapping_tree_detail::mapping_visitor &>(me),
|
||||
*mapping_damage_policy(repair));
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------
|
||||
|
@ -29,6 +29,7 @@ namespace thin_provisioning {
|
||||
// the dumper to do it's best to recover info. If not set, any
|
||||
// corruption encountered will cause an exception to be thrown.
|
||||
void metadata_dump(metadata::ptr md, emitter::ptr e, bool repair);
|
||||
void metadata_dump_subtree(metadata::ptr md, emitter::ptr e, bool repair, uint64_t subtree_root);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user