1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-10-27 18:55:19 +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:
Dave Wysochanski 2010-04-13 17:26:20 +00:00
parent 0adfbfd5ea
commit 11647ad01c
2 changed files with 2 additions and 4 deletions

View File

@ -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;

View File

@ -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);