mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
vdo: correct vdo header size
Previous patch that introduced support for thinpool with vdo not correctly handled header size - as this part is not fully usable yet. We are going to try to use the 0, but current state of code is not yet compliant to this logic so keep vdo_header_size during conversion and alos correctly pass through virtual_extents to vdo formating.
This commit is contained in:
parent
c81e204fd0
commit
9d9e43b87f
@ -980,6 +980,7 @@ struct vdo_convert_params {
|
||||
struct dm_vdo_target_params vdo_params; /* VDO parameters for vdoformat */
|
||||
const char *lv_name;
|
||||
uint32_t virtual_extents;
|
||||
uint64_t header_size;
|
||||
activation_change_t activate;
|
||||
int do_zero;
|
||||
int do_wipe_signatures; /* Used for wiping VDO backend volume */
|
||||
|
@ -521,7 +521,7 @@ struct logical_volume *convert_vdo_lv(struct logical_volume *lv,
|
||||
}
|
||||
}
|
||||
|
||||
if (!convert_vdo_pool_lv(lv, &vcp->vdo_params, &lv->le_count, 1, 0))
|
||||
if (!convert_vdo_pool_lv(lv, &vcp->vdo_params, &lvc.virtual_extents, vcp->do_zero, vcp->header_size))
|
||||
return_NULL;
|
||||
|
||||
/* Create VDO LV with the name, we just release above */
|
||||
|
@ -5479,7 +5479,6 @@ static int _lvconvert_to_vdopool_single(struct cmd_context *cmd,
|
||||
struct volume_group *vg = lv->vg;
|
||||
struct logical_volume *vdo_lv;
|
||||
const char *vg_name = NULL;
|
||||
uint64_t vdo_pool_header_size;
|
||||
struct vdo_convert_params vcp = {
|
||||
.activate = CHANGE_AEY,
|
||||
.lv_name = arg_str_value(cmd, name_ARG, NULL),
|
||||
@ -5498,7 +5497,7 @@ static int _lvconvert_to_vdopool_single(struct cmd_context *cmd,
|
||||
} else
|
||||
vcp.lv_name = "lvol%d";
|
||||
|
||||
if (!fill_vdo_target_params(cmd, &vcp.vdo_params, &vdo_pool_header_size, vg->profile))
|
||||
if (!fill_vdo_target_params(cmd, &vcp.vdo_params, &vcp.header_size, vg->profile))
|
||||
goto_out;
|
||||
|
||||
if (!get_vdo_settings(cmd, &vcp.vdo_params, NULL))
|
||||
|
Loading…
Reference in New Issue
Block a user