Merge branch 'master' of github.com:jthornber/thin-provisioning-tools
Conflicts: thin-provisioning/metadata.cc thin-provisioning/thin_trim.cc
This commit is contained in:
@@ -105,7 +105,7 @@ metadata::metadata(block_manager<>::ptr bm, open_type ot,
|
||||
sb_.data_mapping_root_ = mappings_->get_root();
|
||||
sb_.device_details_root_ = details_->get_root();
|
||||
sb_.data_block_size_ = data_block_size;
|
||||
sb_.metadata_block_size_ = MD_BLOCK_SIZE;
|
||||
sb_.metadata_block_size_ = MD_BLOCK_SIZE >> SECTOR_SHIFT;
|
||||
sb_.metadata_nr_blocks_ = tm_->get_bm()->get_nr_blocks();
|
||||
|
||||
break;
|
||||
|
@@ -50,7 +50,8 @@ namespace {
|
||||
in_superblock_ = true;
|
||||
nr_data_blocks_ = nr_data_blocks;
|
||||
superblock &sb = md_->sb_;
|
||||
memcpy(&sb.uuid_, &uuid, sizeof(sb.uuid_));
|
||||
memset(&sb.uuid_, 0, sizeof(sb.uuid_));
|
||||
memcpy(&sb.uuid_, uuid.c_str(), std::min(sizeof(sb.uuid_), uuid.length()));
|
||||
sb.time_ = time;
|
||||
sb.trans_id_ = trans_id;
|
||||
sb.data_block_size_ = data_block_size;
|
||||
|
@@ -6,6 +6,10 @@
|
||||
|
||||
#undef BLOCK_SIZE
|
||||
|
||||
#ifndef BLKDISCARD
|
||||
#define BLKDISCARD _IO(0x12,119)
|
||||
#endif
|
||||
|
||||
#include "persistent-data/file_utils.h"
|
||||
#include "thin-provisioning/commands.h"
|
||||
#include "metadata.h"
|
||||
|
Reference in New Issue
Block a user