mirror of
https://src.fedoraproject.org/rpms/virt-manager.git
synced 2025-07-16 09:04:55 +00:00
Fix typo in vcpu hotplug Allow memory hotplug for KVM (bz 524297)
This commit is contained in:
19
virt-manager-0.7.0-fix-vcpu-hotplug.patch
Normal file
19
virt-manager-0.7.0-fix-vcpu-hotplug.patch
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
# HG changeset patch
|
||||||
|
# User Cole Robinson <crobinso@redhat.com>
|
||||||
|
# Date 1253823268 14400
|
||||||
|
# Node ID d78b7e7131439dc9f22c8e7391e82c5f29888fe8
|
||||||
|
# Parent cfcd19d057ddc973a129e7816cd4ea39f0d4365a
|
||||||
|
Fix vcpu hotplug.
|
||||||
|
|
||||||
|
diff -r cfcd19d057dd -r d78b7e713143 src/virtManager/domain.py
|
||||||
|
--- a/src/virtManager/domain.py Thu Sep 24 11:41:49 2009 -0400
|
||||||
|
+++ b/src/virtManager/domain.py Thu Sep 24 16:14:28 2009 -0400
|
||||||
|
@@ -1355,7 +1355,7 @@
|
||||||
|
self._change_cdrom(result, dev_id_info)
|
||||||
|
|
||||||
|
def hotplug_vcpu(self, vcpus):
|
||||||
|
- self.vm.setVcpus()
|
||||||
|
+ self.vm.setVcpus(int(vcpus))
|
||||||
|
|
||||||
|
def hotplug_vcpus(self, vcpus):
|
||||||
|
vcpus = int(vcpus)
|
81
virt-manager-0.7.0-remove-hotplug-checks.patch
Normal file
81
virt-manager-0.7.0-remove-hotplug-checks.patch
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
# HG changeset patch
|
||||||
|
# User Cole Robinson <crobinso@redhat.com>
|
||||||
|
# Date 1236966695 14400
|
||||||
|
# Node ID 9530fb06ad66cd517ab305c3a4bf426ef69439ed
|
||||||
|
# Parent 7ab8a12b3527d97bc92acca7e6e6ff3fbdd9746b
|
||||||
|
Remove mem/cpu hotplug checks.
|
||||||
|
|
||||||
|
We can't reliably determine whether it's supported or not, so just leave
|
||||||
|
the error reporting up to libvirt.
|
||||||
|
|
||||||
|
diff -r 7ab8a12b3527 -r 9530fb06ad66 src/virtManager/details.py
|
||||||
|
--- a/src/virtManager/details.py Fri Mar 13 13:13:24 2009 -0400
|
||||||
|
+++ b/src/virtManager/details.py Fri Mar 13 13:51:35 2009 -0400
|
||||||
|
@@ -749,15 +749,9 @@
|
||||||
|
if status in [ libvirt.VIR_DOMAIN_SHUTOFF, libvirt.VIR_DOMAIN_CRASHED ] and not self.vm.is_read_only():
|
||||||
|
self.window.get_widget("control-run").set_sensitive(True)
|
||||||
|
self.window.get_widget("details-menu-run").set_sensitive(True)
|
||||||
|
- self.window.get_widget("config-vcpus").set_sensitive(True)
|
||||||
|
- self.window.get_widget("config-memory").set_sensitive(True)
|
||||||
|
- self.window.get_widget("config-maxmem").set_sensitive(True)
|
||||||
|
else:
|
||||||
|
self.window.get_widget("control-run").set_sensitive(False)
|
||||||
|
self.window.get_widget("details-menu-run").set_sensitive(False)
|
||||||
|
- self.window.get_widget("config-vcpus").set_sensitive(self.vm.is_vcpu_hotplug_capable())
|
||||||
|
- self.window.get_widget("config-memory").set_sensitive(self.vm.is_memory_hotplug_capable())
|
||||||
|
- self.window.get_widget("config-maxmem").set_sensitive(True)
|
||||||
|
|
||||||
|
if status in [libvirt.VIR_DOMAIN_SHUTDOWN, libvirt.VIR_DOMAIN_SHUTOFF,
|
||||||
|
libvirt.VIR_DOMAIN_CRASHED ] or vm.is_read_only():
|
||||||
|
@@ -775,11 +769,12 @@
|
||||||
|
self.window.get_widget("details-menu-shutdown").set_sensitive(True)
|
||||||
|
self.window.get_widget("details-menu-save").set_sensitive(True)
|
||||||
|
|
||||||
|
- # Currently, the condition that "Migrate" become insensitive is only "readonly".
|
||||||
|
- if vm.is_read_only():
|
||||||
|
- self.window.get_widget("details-menu-migrate").set_sensitive(False)
|
||||||
|
- else:
|
||||||
|
- self.window.get_widget("details-menu-migrate").set_sensitive(True)
|
||||||
|
+ ro = vm.is_read_only()
|
||||||
|
+ self.window.get_widget("config-vcpus").set_sensitive(not ro)
|
||||||
|
+ self.window.get_widget("config-memory").set_sensitive(not ro)
|
||||||
|
+ self.window.get_widget("config-maxmem").set_sensitive(not ro)
|
||||||
|
+ self.window.get_widget("details-menu-migrate").set_sensitive(not ro)
|
||||||
|
+ if not ro:
|
||||||
|
self.set_migrate_menu()
|
||||||
|
|
||||||
|
if status in [ libvirt.VIR_DOMAIN_SHUTOFF ,libvirt.VIR_DOMAIN_CRASHED ]:
|
||||||
|
diff -r 7ab8a12b3527 -r 9530fb06ad66 src/virtManager/domain.py
|
||||||
|
--- a/src/virtManager/domain.py Fri Mar 13 13:13:24 2009 -0400
|
||||||
|
+++ b/src/virtManager/domain.py Fri Mar 13 13:51:35 2009 -0400
|
||||||
|
@@ -181,30 +181,6 @@
|
||||||
|
# FIXME: This should be static, not parse xml everytime
|
||||||
|
return vutil.get_xml_path(self.get_xml(), "/domain/@type")
|
||||||
|
|
||||||
|
- def is_vcpu_hotplug_capable(self):
|
||||||
|
- # Read only connections aren't allowed to change it
|
||||||
|
- if self.connection.is_read_only():
|
||||||
|
- return False
|
||||||
|
- # Running paravirt guests can change it, or any inactive guest
|
||||||
|
- if self.vm.OSType() == "linux" \
|
||||||
|
- or self.status() not in [libvirt.VIR_DOMAIN_RUNNING,\
|
||||||
|
- libvirt.VIR_DOMAIN_PAUSED]:
|
||||||
|
- return True
|
||||||
|
- # Everyone else is out of luck
|
||||||
|
- return False
|
||||||
|
-
|
||||||
|
- def is_memory_hotplug_capable(self):
|
||||||
|
- # Read only connections aren't allowed to change it
|
||||||
|
- if self.connection.is_read_only():
|
||||||
|
- return False
|
||||||
|
- # Running paravirt guests can change it, or any inactive guest
|
||||||
|
- if self.vm.OSType() == "linux" \
|
||||||
|
- or self.status() not in [libvirt.VIR_DOMAIN_RUNNING,\
|
||||||
|
- libvirt.VIR_DOMAIN_PAUSED]:
|
||||||
|
- return True
|
||||||
|
- # Everyone else is out of luck
|
||||||
|
- return False
|
||||||
|
-
|
||||||
|
def _normalize_status(self, status):
|
||||||
|
if status == libvirt.VIR_DOMAIN_NOSTATE:
|
||||||
|
return libvirt.VIR_DOMAIN_RUNNING
|
@@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
Name: virt-manager
|
Name: virt-manager
|
||||||
Version: 0.7.0
|
Version: 0.7.0
|
||||||
Release: 6%{_extra_release}
|
Release: 7%{_extra_release}
|
||||||
Summary: Virtual Machine Manager
|
Summary: Virtual Machine Manager
|
||||||
|
|
||||||
Group: Applications/Emulators
|
Group: Applications/Emulators
|
||||||
@@ -41,6 +41,10 @@ Patch17: %{name}-%{version}-fix-memory-interaction.patch
|
|||||||
Patch18: %{name}-%{version}-vcpu-mem-persistent.patch
|
Patch18: %{name}-%{version}-vcpu-mem-persistent.patch
|
||||||
# Add pylint script
|
# Add pylint script
|
||||||
Patch19: %{name}-%{version}-pylint-script.patch
|
Patch19: %{name}-%{version}-pylint-script.patch
|
||||||
|
# Fix typo in vcpu hotplug
|
||||||
|
Patch20: %{name}-%{version}-fix-vcpu-hotplug.patch
|
||||||
|
# Allow memory hotplug for KVM (bz 524297)
|
||||||
|
Patch21: %{name}-%{version}-remove-hotplug-checks.patch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
|
|
||||||
# These two are just the oldest version tested
|
# These two are just the oldest version tested
|
||||||
@@ -132,6 +136,8 @@ management API.
|
|||||||
%patch17 -p1
|
%patch17 -p1
|
||||||
%patch18 -p1
|
%patch18 -p1
|
||||||
%patch19 -p1
|
%patch19 -p1
|
||||||
|
%patch20 -p1
|
||||||
|
%patch21 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%configure
|
%configure
|
||||||
@@ -209,6 +215,10 @@ fi
|
|||||||
%{_datadir}/dbus-1/services/%{name}.service
|
%{_datadir}/dbus-1/services/%{name}.service
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Oct 05 2009 Cole Robinson <crobinso@redhat.com> - 0.7.0-7.fc11
|
||||||
|
- Fix typo in vcpu hotplug
|
||||||
|
- Allow memory hotplug for KVM (bz 524297)
|
||||||
|
|
||||||
* Fri Sep 18 2009 Cole Robinson <crobinso@redhat.com> - 0.7.0-6.fc11
|
* Fri Sep 18 2009 Cole Robinson <crobinso@redhat.com> - 0.7.0-6.fc11
|
||||||
- Fix migration for qemu/kvm guests (bz 517548)
|
- Fix migration for qemu/kvm guests (bz 517548)
|
||||||
- Fix sparse allocation confusion (bz 504605)
|
- Fix sparse allocation confusion (bz 504605)
|
||||||
|
Reference in New Issue
Block a user