This commit is contained in:
Joe Thornber
2013-12-11 17:28:14 +00:00
parent 927f611aad
commit 8049d369a9
12 changed files with 123 additions and 90 deletions

View File

@ -84,10 +84,9 @@ thin_provisioning::walk_device_tree(device_tree const &tree,
device_tree_detail::device_visitor &vv,
device_tree_detail::damage_visitor &dv)
{
block_counter counter;
visitor_adapter av(vv);
ll_damage_visitor ll_dv(dv);
btree_visit_values(tree, counter, av, ll_dv);
btree_visit_values(tree, av, ll_dv);
}
void

View File

@ -173,9 +173,8 @@ thin_provisioning::walk_mapping_tree(dev_tree const &tree,
mapping_tree_detail::device_visitor &dev_v,
mapping_tree_detail::damage_visitor &dv)
{
block_counter counter;
ll_damage_visitor ll_dv(dv);
btree_visit_values(tree, counter, dev_v, ll_dv);
btree_visit_values(tree, dev_v, ll_dv);
}
void
@ -191,9 +190,8 @@ thin_provisioning::walk_mapping_tree(mapping_tree const &tree,
mapping_tree_detail::mapping_visitor &mv,
mapping_tree_detail::damage_visitor &dv)
{
block_counter counter;
ll_damage_visitor ll_dv(dv);
btree_visit_values(tree, counter, mv, ll_dv);
btree_visit_values(tree, mv, ll_dv);
}
void
@ -209,9 +207,8 @@ thin_provisioning::walk_mapping_tree(single_mapping_tree const &tree,
mapping_tree_detail::mapping_visitor &mv,
mapping_tree_detail::damage_visitor &dv)
{
block_counter counter;
ll_damage_visitor ll_dv(dv);
btree_visit_values(tree, counter, mv, ll_dv);
btree_visit_values(tree, mv, ll_dv);
}
void

View File

@ -18,8 +18,6 @@
#include "thin-provisioning/thin_pool.h"
#include "persistent-data/data-structures/btree_checker.h"
#include <stdexcept>
#include <sstream>
#include <iostream>

View File

@ -63,7 +63,6 @@ namespace {
}
int rmap(string const &path, vector<region> const &regions) {
block_counter counter; // FIXME: get rid of this counter arg
damage_visitor dv;
rmap_visitor rv;
@ -79,7 +78,7 @@ namespace {
mapping_tree mtree(tm, sb.data_mapping_root_,
mapping_tree_detail::block_traits::ref_counter(tm->get_sm()));
btree_visit_values(mtree, counter, rv, dv);
btree_visit_values(mtree, rv, dv);
rv.complete();
display_rmap(cout, rv.get_rmap());