Add --migratable support to virsh cpu-baseline

Wire up VIR_CONNECT_BASELINE_CPU_MIGRATABLE to this
command line option.
This commit is contained in:
Ján Tomko 2015-02-05 15:30:50 +01:00
parent 000b21da83
commit c7b9f20666
2 changed files with 9 additions and 2 deletions

View File

@ -6913,6 +6913,10 @@ static const vshCmdOptDef opts_cpu_baseline[] = {
.type = VSH_OT_BOOL,
.help = N_("Show features that are part of the CPU model type")
},
{.name = "migratable",
.type = VSH_OT_BOOL,
.help = N_("Do not include features that block migration")
},
{.name = NULL}
};
@ -6935,6 +6939,8 @@ cmdCPUBaseline(vshControl *ctl, const vshCmd *cmd)
if (vshCommandOptBool(cmd, "features"))
flags |= VIR_CONNECT_BASELINE_CPU_EXPAND_FEATURES;
if (vshCommandOptBool(cmd, "migratable"))
flags |= VIR_CONNECT_BASELINE_CPU_MIGRATABLE;
if (vshCommandOptStringReq(ctl, cmd, "file", &from) < 0)
return false;

View File

@ -569,7 +569,7 @@ I<cellno> modifier can be used to narrow the modification down to
a single host NUMA cell. On the other end of spectrum lies
I<--all> which executes the modification on all NUMA cells.
=item B<cpu-baseline> I<FILE> [I<--features>]
=item B<cpu-baseline> I<FILE> [I<--features>] [I<--migratable>]
Compute baseline CPU which will be supported by all host CPUs given in <file>.
The list of host CPUs is built by extracting all <cpu> elements from the
@ -578,7 +578,8 @@ by new lines or even a set of complete <capabilities> elements printed by
B<capabilities> command. If I<--features> is specified then the
resulting XML description will explicitly include all features that make
up the CPU, without this option features that are part of the CPU model
will not be listed in the XML description.
will not be listed in the XML description. If I<--migratable> is specified,
features that block migration will not be included in the resulting CPU.
=item B<cpu-compare> I<FILE> [I<--error>]