Skip to contentSkip to conversation

tools/xl: fix output of xl vcpu-pin dry run with smt=0

PATCH In review Juergen Gross 2 participants 2 messages Sep 3, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tools/xl: fix output of xl vcpu-pin dry run with smt=0

Fix another smt=0 fallout: xl -N vcpu-pin prints only parts of the affinities as it is using the number of online cpus instead of the maximum cpu number.

---
 tools/xl/xl_vcpu.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
tools/xl/xl_vcpu.c +2 -2
index c877f2595f..aef486864c 100644
@@ -255,9 +255,9 @@ int main_vcpupin(int argc, char **argv)
         goto out;
 
     if (dryrun_only) {
-        nb_cpu = libxl_get_online_cpus(ctx);
+        nb_cpu = libxl_get_max_cpus(ctx);
         if (nb_cpu < 0) {
-            fprintf(stderr, "libxl_get_online_cpus failed.\n");
+            fprintf(stderr, "libxl_get_max_cpus failed.\n");
             goto out;
         }
 
Signature · 7 lines
2.16.4


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel