[PATCH 1/2] conf: List only online cpus for virsh vcpupin

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: nitesh konkar <niteshkonkar.libvirt@xxxxxxxxx>

Signed-off-by: Nitesh Konkar <nitkon12@xxxxxxxxxxxxxxxxxx>
---
 src/conf/domain_conf.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index a233c0c..227b695 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -55,6 +55,7 @@
 #include "virtpm.h"
 #include "virstring.h"
 #include "virnetdev.h"
+#include "virhostcpu.h"
 
 #define VIR_FROM_THIS VIR_FROM_DOMAIN
 
@@ -1562,6 +1563,8 @@ virDomainDefGetVcpuPinInfoHelper(virDomainDefPtr def,
         else if (def->placement_mode == VIR_DOMAIN_CPU_PLACEMENT_MODE_AUTO &&
                  autoCpuset)
             bitmap = autoCpuset;
+        else if (def->placement_mode == VIR_DOMAIN_CPU_PLACEMENT_MODE_STATIC)
+            bitmap = virHostCPUGetOnlineBitmap();
         else if (def->cpumask)
             bitmap = def->cpumask;
         else
-- 
2.1.0

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]