]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commitdiff
Add --migratable support to virsh cpu-baseline
authorJán Tomko <jtomko@redhat.com>
Thu, 5 Feb 2015 14:30:50 +0000 (15:30 +0100)
committerJán Tomko <jtomko@redhat.com>
Mon, 2 Mar 2015 06:59:12 +0000 (07:59 +0100)
Wire up VIR_CONNECT_BASELINE_CPU_MIGRATABLE to this
command line option.

tools/virsh-domain.c
tools/virsh.pod

index 80a96b2ae065e346d0f4c872f9c4f4cd6ca2ccfc..55c269c5188d9529f8d78d2316387d66db1930be 100644 (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;
index 343f26f2beceafd151b8c7d2224c8baa55e58ea7..85ce257f7155d5f85492c03aba8002cb83490af6 100644 (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>]