virt-manager/virtman-init-vm-processor-topology.patch
Charles Arnold 4f22f7f4d5 - Upstream bug fixes
5332ee4d-enable-media-detection-for-ISO-images.patch
  53341e7e-hide-hardware-removal-for-non-devices.patch
  53342f31-set-right-ip-address-for-ipv6.patch

- bnc#870098 - virt-manager+x show wrong number of assigned cpu's 
  virtman-init-vm-processor-topology.patch

OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=157
2014-03-27 22:27:37 +00:00

34 lines
1.3 KiB
Diff

Index: virt-manager-1.0.1/virtManager/details.py
===================================================================
--- virt-manager-1.0.1.orig/virtManager/details.py
+++ virt-manager-1.0.1/virtManager/details.py
@@ -2564,13 +2564,6 @@ class vmmDetails(vmmGObjectUI):
def refresh_config_cpu(self):
conn = self.vm.conn
host_active_count = conn.host_active_processor_count()
- maxvcpus = self.vm.vcpu_max_count()
- curvcpus = self.vm.vcpu_count()
-
- curadj = self.widget("config-vcpus")
- maxadj = self.widget("config-maxvcpus")
- curadj.set_value(int(curvcpus))
- maxadj.set_value(int(maxvcpus))
self.widget("state-host-cpus").set_text(str(host_active_count))
@@ -2592,6 +2585,14 @@ class vmmDetails(vmmGObjectUI):
if show_top:
self.widget("cpu-topology-expander").set_expanded(True)
+ maxvcpus = self.vm.vcpu_max_count()
+ curvcpus = self.vm.vcpu_count()
+
+ curadj = self.widget("config-vcpus")
+ maxadj = self.widget("config-maxvcpus")
+ curadj.set_value(int(curvcpus))
+ maxadj.set_value(int(maxvcpus))
+
model = cpu.model or None
if not model:
if cpu.mode == "host-model" or cpu.mode == "host-passthrough":