mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-22 17:35:59 +03:00
Make vg_extend() format_instance * parameter internal to vg_extend()
This commit is contained in:
parent
bb6d3b6cfd
commit
a10afb1b98
@ -245,14 +245,13 @@ int vg_rename(struct cmd_context *cmd, struct volume_group *vg,
|
||||
return 1;
|
||||
}
|
||||
|
||||
int vg_extend(struct format_instance *fid,
|
||||
struct volume_group *vg, int pv_count, char **pv_names)
|
||||
int vg_extend(struct volume_group *vg, int pv_count, char **pv_names)
|
||||
{
|
||||
int i;
|
||||
|
||||
/* attach each pv */
|
||||
for (i = 0; i < pv_count; i++)
|
||||
if (!_add_pv_to_vg(fid, vg, pv_names[i])) {
|
||||
if (!_add_pv_to_vg(vg->fid, vg, pv_names[i])) {
|
||||
log_error("Unable to add physical volume '%s' to "
|
||||
"volume group '%s'.", pv_names[i], vg->name);
|
||||
return 0;
|
||||
@ -352,7 +351,7 @@ struct volume_group *vg_create(struct cmd_context *cmd, const char *vg_name,
|
||||
}
|
||||
|
||||
/* attach the pv's */
|
||||
if (!vg_extend(vg->fid, vg, pv_count, pv_names))
|
||||
if (!vg_extend(vg, pv_count, pv_names))
|
||||
goto_bad;
|
||||
|
||||
return vg;
|
||||
|
@ -461,8 +461,7 @@ struct volume_group *vg_create(struct cmd_context *cmd, const char *name,
|
||||
int vg_remove(struct volume_group *vg);
|
||||
int vg_rename(struct cmd_context *cmd, struct volume_group *vg,
|
||||
const char *new_name);
|
||||
int vg_extend(struct format_instance *fi, struct volume_group *vg,
|
||||
int pv_count, char **pv_names);
|
||||
int vg_extend(struct volume_group *vg, int pv_count, char **pv_names);
|
||||
int vg_change_pesize(struct cmd_context *cmd, struct volume_group *vg,
|
||||
uint32_t new_extent_size);
|
||||
int vg_split_mdas(struct cmd_context *cmd, struct volume_group *vg_from,
|
||||
|
@ -74,7 +74,7 @@ int vgextend(struct cmd_context *cmd, int argc, char **argv)
|
||||
goto error;
|
||||
|
||||
/* extend vg */
|
||||
if (!vg_extend(vg->fid, vg, argc, argv))
|
||||
if (!vg_extend(vg, argc, argv))
|
||||
goto error;
|
||||
|
||||
/* ret > 0 */
|
||||
|
Loading…
Reference in New Issue
Block a user