mirror of
git://sourceware.org/git/lvm2.git
synced 2025-04-01 18:50:41 +03:00
Use del_pvl_from_vgs() in vgreduce paths.
Somehow these got missed in earlier patches. Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>
This commit is contained in:
parent
85f56aef97
commit
efe3e72ed0
@ -667,12 +667,11 @@ int vg_reduce(struct volume_group *vg, char *pv_name)
|
||||
goto bad;
|
||||
}
|
||||
|
||||
vg->pv_count--;
|
||||
vg->free_count -= pv_pe_count(pv) - pv_pe_alloc_count(pv);
|
||||
vg->extent_count -= pv_pe_count(pv);
|
||||
del_pvl_from_vgs(vg, pvl);
|
||||
|
||||
/* add pv to the remove_pvs list */
|
||||
dm_list_del(&pvl->list);
|
||||
dm_list_add(&vg->removed_pvs, &pvl->list);
|
||||
|
||||
return 1;
|
||||
|
@ -407,7 +407,7 @@ static int _vgreduce_single(struct cmd_context *cmd, struct volume_group *vg,
|
||||
log_verbose("Removing \"%s\" from volume group \"%s\"", name, vg->name);
|
||||
|
||||
if (pvl)
|
||||
dm_list_del(&pvl->list);
|
||||
del_pvl_from_vgs(vg, pvl);
|
||||
|
||||
pv->vg_name = vg->fid->fmt->orphan_vg_name;
|
||||
pv->status = ALLOCATABLE_PV;
|
||||
@ -417,7 +417,6 @@ static int _vgreduce_single(struct cmd_context *cmd, struct volume_group *vg,
|
||||
goto bad;
|
||||
}
|
||||
|
||||
vg->pv_count--;
|
||||
vg->free_count -= pv_pe_count(pv) - pv_pe_alloc_count(pv);
|
||||
vg->extent_count -= pv_pe_count(pv);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user