crobinso pushed to virt-manager (f21). "Fix new VM disk image names when VM name changes (bz #1169141) (..more)"
notifications at fedoraproject.org
notifications at fedoraproject.org
Fri Mar 27 21:05:44 UTC 2015
>From d8c77829e247e3c7d9b478e694bfdf7855280fe0 Mon Sep 17 00:00:00 2001
From: Cole Robinson <crobinso at redhat.com>
Date: Fri, 27 Mar 2015 17:05:35 -0400
Subject: Fix new VM disk image names when VM name changes (bz #1169141) Fix
missing virt-install dep on pygobject (bz #1195794) Fix changing VM video
type away from qxl (bz #1182710) Clear vendor field when changing CPU (bz
#1190851) Drop bogus network domain name validation (bz #1195873)
diff --git a/0004-create-Fix-default-storage-path-when-VM-name-is-chan.patch b/0004-create-Fix-default-storage-path-when-VM-name-is-chan.patch
new file mode 100644
index 0000000..fb3bea0
--- /dev/null
+++ b/0004-create-Fix-default-storage-path-when-VM-name-is-chan.patch
@@ -0,0 +1,63 @@
+From: Cole Robinson <crobinso at redhat.com>
+Date: Wed, 3 Dec 2014 13:08:18 -0500
+Subject: [PATCH virt-manager] create: Fix default storage path when VM name is
+ changed (bz 1169141)
+
+Regressed with 2e7ebd4 . Use skip_disk_page() to determine when we
+shouldn't assume default storage
+
+(cherry picked from commit 4a678f05439da9f17c8cd89f22a59df1b27eddd6)
+---
+ virtManager/addstorage.py | 6 +-----
+ virtManager/create.py | 7 ++++---
+ 2 files changed, 5 insertions(+), 8 deletions(-)
+
+diff --git a/virtManager/addstorage.py b/virtManager/addstorage.py
+index 9b2a673..91cce73 100644
+--- a/virtManager/addstorage.py
++++ b/virtManager/addstorage.py
+@@ -108,9 +108,6 @@ class vmmAddStorage(vmmGObjectUI):
+ hd_label = ("<span color='#484848'>%s</span>" % hd_label)
+ widget.set_markup(hd_label)
+
+- def _is_default_storage(self):
+- return bool(self.widget("config-storage-create").get_active())
+-
+ def _check_default_pool_active(self):
+ default_pool = self.conn.get_default_pool()
+ if default_pool and not default_pool.is_active():
+@@ -257,8 +254,7 @@ class vmmAddStorage(vmmGObjectUI):
+ return path
+
+ def is_default_storage(self):
+- return self.widget("config-storage-create").is_visible() and \
+- self.widget("config-storage-create").get_active()
++ return self.widget("config-storage-create").get_active()
+
+ def _check_ideal_path(self, path, vmname, collidelist):
+ # See if the ideal disk path (/default/pool/vmname.img)
+diff --git a/virtManager/create.py b/virtManager/create.py
+index f15763c..0f9bdaa 100644
+--- a/virtManager/create.py
++++ b/virtManager/create.py
+@@ -1062,9 +1062,8 @@ class vmmCreate(vmmGObjectUI):
+ return self.addstorage.get_default_path(name)
+
+ def is_default_storage(self):
+- usedef = self.addstorage.is_default_storage()
+- isimport = (self.get_config_install_page() == INSTALL_PAGE_IMPORT)
+- return usedef and not isimport
++ return (self.addstorage.is_default_storage() and
++ not self.skip_disk_page())
+
+ def get_config_customize(self):
+ return self.widget("summary-customize").get_active()
+@@ -1718,6 +1717,8 @@ class vmmCreate(vmmGObjectUI):
+ if name != self.guest.name:
+ self.guest.name = name
+ if self.is_default_storage():
++ logging.debug("User changed VM name and using default storage,"
++ "re-validating with new default storage path.")
+ # User changed the name and we are using default storage
+ # which depends on the VM name. Revalidate things
+ if not self.validate_storage_page():
diff --git a/0005-spec-Add-pygobject3-base-dep-for-virt-install-bz-119.patch b/0005-spec-Add-pygobject3-base-dep-for-virt-install-bz-119.patch
new file mode 100644
index 0000000..db09acd
--- /dev/null
+++ b/0005-spec-Add-pygobject3-base-dep-for-virt-install-bz-119.patch
@@ -0,0 +1,23 @@
+From: Cole Robinson <crobinso at redhat.com>
+Date: Tue, 24 Feb 2015 11:23:46 -0500
+Subject: [PATCH virt-manager] spec: Add pygobject3-base dep for virt-install
+ (bz 1195794)
+
+(cherry picked from commit 72324a857591e23c9d8998366e2eef337a9fd4e9)
+---
+ virt-manager.spec.in | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/virt-manager.spec.in b/virt-manager.spec.in
+index 607a4b6..b378749 100644
+--- a/virt-manager.spec.in
++++ b/virt-manager.spec.in
+@@ -75,6 +75,8 @@ Requires: libxml2-python
+ Requires: python-urlgrabber
+ Requires: python-ipaddr
+ Requires: libosinfo >= 0.2.10
++# Required for gobject-introspection infrastructure
++Requires: pygobject3-base
+
+ %description common
+ Common files used by the different virt-manager interfaces, as well as
diff --git a/0006-virt-manager-reset-vgamem-for-video-when-changing-de.patch b/0006-virt-manager-reset-vgamem-for-video-when-changing-de.patch
new file mode 100644
index 0000000..9767636
--- /dev/null
+++ b/0006-virt-manager-reset-vgamem-for-video-when-changing-de.patch
@@ -0,0 +1,74 @@
+From: Giuseppe Scrivano <gscrivan at redhat.com>
+Date: Mon, 1 Dec 2014 15:56:29 +0100
+Subject: [PATCH virt-manager] virt-manager: reset vgamem for video when
+ changing device type
+
+Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1169295
+
+Signed-off-by: Giuseppe Scrivano <gscrivan at redhat.com>
+(cherry picked from commit 51e5a471202a67e3c9c1dd53c0afc333d77933c9)
+---
+ tests/xmlparse-xml/change-videos-out.xml | 2 +-
+ tests/xmlparse.py | 1 +
+ virtManager/domain.py | 1 +
+ virtinst/devicevideo.py | 4 ++--
+ 4 files changed, 5 insertions(+), 3 deletions(-)
+
+diff --git a/tests/xmlparse-xml/change-videos-out.xml b/tests/xmlparse-xml/change-videos-out.xml
+index ea357ef..15cb0b0 100644
+--- a/tests/xmlparse-xml/change-videos-out.xml
++++ b/tests/xmlparse-xml/change-videos-out.xml
+@@ -30,7 +30,7 @@
+ <model type="vmvga" heads="5"/>
+ </video>
+ <video>
+- <model type="qxl" ram="100"/>
++ <model type="qxl" vgamem="8192" ram="100"/>
+ </video>
+ </devices>
+ </domain>
+diff --git a/tests/xmlparse.py b/tests/xmlparse.py
+index 870bf36..c4bcb20 100644
+--- a/tests/xmlparse.py
++++ b/tests/xmlparse.py
+@@ -624,6 +624,7 @@ class XMLParseTest(unittest.TestCase):
+ check = self._make_checker(dev3)
+ check("model", "cirrus", "cirrus", "qxl")
+ check("ram", None, 100)
++ check("vgamem", None, 8192)
+
+ self._alter_compare(guest.get_xml_config(), outfile)
+
+diff --git a/virtManager/domain.py b/virtManager/domain.py
+index 585f64b..4a98f7f 100644
+--- a/virtManager/domain.py
++++ b/virtManager/domain.py
+@@ -860,6 +860,7 @@ class vmmDomain(vmmLibvirtObject):
+ editdev.vram = None
+ editdev.heads = None
+ editdev.ram = None
++ editdev.vgamem = None
+
+ return self._redefine_device(change, devobj, use_live_device)
+
+diff --git a/virtinst/devicevideo.py b/virtinst/devicevideo.py
+index 088c9ad..1d8ee10 100644
+--- a/virtinst/devicevideo.py
++++ b/virtinst/devicevideo.py
+@@ -35,14 +35,14 @@ class VirtualVideoDevice(VirtualDevice):
+ return model.upper()
+ return model.capitalize()
+
+-
+- _XML_PROP_ORDER = ["model", "vram", "heads"]
++ _XML_PROP_ORDER = ["model", "vram", "heads", "vgamem"]
+ model = XMLProperty("./model/@type",
+ default_cb=lambda s: "cirrus",
+ default_name=MODEL_DEFAULT)
+ vram = XMLProperty("./model/@vram", is_int=True)
+ ram = XMLProperty("./model/@ram", is_int=True)
+ heads = XMLProperty("./model/@heads", is_int=True)
++ vgamem = XMLProperty("./model/@vgamem", is_int=True)
+
+
+ VirtualVideoDevice.register_type()
diff --git a/0007-cpu-Drop-vendor-and-features-if-setting-host-model-b.patch b/0007-cpu-Drop-vendor-and-features-if-setting-host-model-b.patch
new file mode 100644
index 0000000..85497fc
--- /dev/null
+++ b/0007-cpu-Drop-vendor-and-features-if-setting-host-model-b.patch
@@ -0,0 +1,63 @@
+From: Cole Robinson <crobinso at redhat.com>
+Date: Thu, 26 Mar 2015 17:08:15 -0400
+Subject: [PATCH virt-manager] cpu: Drop vendor and features if setting
+ host-model (bz 1190851)
+
+Otherwise via virt-manager we can try to set a <cpu> with a <vendor>
+but no <model>, and libvirt complains.
+
+(cherry picked from commit dc1737e623aef0f661cc28c0c5b87f847fc2526b)
+---
+ tests/xmlparse-xml/change-minimal-guest-out.xml | 2 +-
+ tests/xmlparse.py | 1 +
+ virtinst/cpu.py | 5 +++++
+ 3 files changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/tests/xmlparse-xml/change-minimal-guest-out.xml b/tests/xmlparse-xml/change-minimal-guest-out.xml
+index 5363080..f3be5c0 100644
+--- a/tests/xmlparse-xml/change-minimal-guest-out.xml
++++ b/tests/xmlparse-xml/change-minimal-guest-out.xml
+@@ -23,7 +23,7 @@
+ <label>frob</label>
+ </seclabel>
+ <cpu mode="custom" match="exact">
+- <model>foobar</model>
++ <model fallback="allow">foobar</model>
+ <topology sockets="1" cores="4" threads="1"/>
+ <feature policy="forbid" name="x2apic"/>
+ </cpu>
+diff --git a/tests/xmlparse.py b/tests/xmlparse.py
+index c4bcb20..477de22 100644
+--- a/tests/xmlparse.py
++++ b/tests/xmlparse.py
+@@ -251,6 +251,7 @@ class XMLParseTest(unittest.TestCase):
+
+ check = self._make_checker(guest.cpu)
+ check("model", None, "foobar")
++ check("model_fallback", None, "allow")
+ check("cores", None, 4)
+ guest.cpu.add_feature("x2apic", "forbid")
+ guest.cpu.set_topology_defaults(guest.vcpus)
+diff --git a/virtinst/cpu.py b/virtinst/cpu.py
+index 551364c..b12fd30 100644
+--- a/virtinst/cpu.py
++++ b/virtinst/cpu.py
+@@ -59,6 +59,10 @@ class CPU(XMLBuilder):
+ if (val == self.SPECIAL_MODE_HOST_MODEL or
+ val == self.SPECIAL_MODE_HOST_PASSTHROUGH):
+ self.model = None
++ self.vendor = None
++ self.model_fallback = None
++ for f in self.features:
++ self.remove_feature(f)
+ self.mode = val
+ elif val == self.SPECIAL_MODE_HOST_COPY:
+ self.copy_host_cpu()
+@@ -161,6 +165,7 @@ class CPU(XMLBuilder):
+ self.match = "exact"
+ return val
+ model = XMLProperty("./model", set_converter=_set_model)
++ model_fallback = XMLProperty("./model/@fallback")
+
+ match = XMLProperty("./@match")
+ vendor = XMLProperty("./vendor")
diff --git a/0008-createnet-Drop-incorrect-domain-name-validation-bz-1.patch b/0008-createnet-Drop-incorrect-domain-name-validation-bz-1.patch
new file mode 100644
index 0000000..6e28778
--- /dev/null
+++ b/0008-createnet-Drop-incorrect-domain-name-validation-bz-1.patch
@@ -0,0 +1,33 @@
+From: Cole Robinson <crobinso at redhat.com>
+Date: Thu, 26 Mar 2015 17:11:23 -0400
+Subject: [PATCH virt-manager] createnet: Drop incorrect domain name validation
+ (bz 1195873)
+
+Just let libvirt error if something is wrong
+
+(cherry picked from commit af562320a5c4f9148dd7710547386ab203dd9849)
+---
+ virtManager/createnet.py | 10 ----------
+ 1 file changed, 10 deletions(-)
+
+diff --git a/virtManager/createnet.py b/virtManager/createnet.py
+index 6c0634c..0f09732 100644
+--- a/virtManager/createnet.py
++++ b/virtManager/createnet.py
+@@ -425,16 +425,6 @@ class vmmCreateNetwork(vmmGObjectUI):
+ return True
+
+ def validate_miscellaneous(self):
+- domain_name = self.widget("net-domain-name").get_text()
+- if len(domain_name) > 0:
+- if len(domain_name) > 16:
+- return self.err.val_err(_("Invalid Domain Name"),
+- _("Domain name must be less than 17 characters"))
+- if re.match("^[a-zA-Z0-9_]*$", domain_name) is None:
+- return self.err.val_err(_("Invalid Domain Name"),
+- _("Domain name may contain alphanumeric and '_' "
+- "characters only"))
+-
+ return True
+
+ def validate(self, page_num):
diff --git a/virt-manager.spec b/virt-manager.spec
index 6d9ad0b..9c24c8e 100644
--- a/virt-manager.spec
+++ b/virt-manager.spec
@@ -28,7 +28,7 @@
Name: virt-manager
Version: 1.1.0
-Release: 4.git%{gitcommit}%{_extra_release}
+Release: 5.git%{gitcommit}%{_extra_release}
%define verrel %{version}-%{release}
Summary: Virtual Machine Manager
@@ -46,6 +46,16 @@ Patch0001: 0001-tunnels-do-not-close-unowned-fd.patch
Patch0002: 0002-spec-move-dependency-to-libosinfo-from-virt-manager-.patch
# Fix PCI/USB hotplug (bz #1146297)
Patch0003: 0003-addhardware-Fix-attaching-USB-PCI-hostdev-bz-1146297.patch
+# Fix new VM disk image names when VM name changes (bz #1169141)
+Patch0004: 0004-create-Fix-default-storage-path-when-VM-name-is-chan.patch
+# Fix missing virt-install dep on pygobject (bz #1195794)
+Patch0005: 0005-spec-Add-pygobject3-base-dep-for-virt-install-bz-119.patch
+# Fix changing VM video type away from qxl (bz #1182710)
+Patch0006: 0006-virt-manager-reset-vgamem-for-video-when-changing-de.patch
+# Clear vendor field when changing CPU (bz #1190851)
+Patch0007: 0007-cpu-Drop-vendor-and-features-if-setting-host-model-b.patch
+# Drop bogus network domain name validation (bz #1195873)
+Patch0008: 0008-createnet-Drop-incorrect-domain-name-validation-bz-1.patch
Requires: virt-manager-common = %{verrel}
@@ -85,6 +95,8 @@ Requires: libxml2-python
Requires: python-urlgrabber
Requires: python-ipaddr
Requires: libosinfo >= 0.2.10
+# Required for gobject-introspection infrastructure
+Requires: pygobject3-base
%description common
Common files used by the different virt-manager interfaces, as well as
@@ -117,6 +129,16 @@ machine).
%patch0002 -p1
# Fix PCI/USB hotplug (bz #1146297)
%patch0003 -p1
+# Fix new VM disk image names when VM name changes (bz #1169141)
+%patch0004 -p1
+# Fix missing virt-install dep on pygobject (bz #1195794)
+%patch0005 -p1
+# Fix changing VM video type away from qxl (bz #1182710)
+%patch0006 -p1
+# Clear vendor field when changing CPU (bz #1190851)
+%patch0007 -p1
+# Drop bogus network domain name validation (bz #1195873)
+%patch0008 -p1
%build
%if %{qemu_user}
@@ -222,6 +244,13 @@ fi
%changelog
+* Fri Mar 27 2015 Cole Robinson <crobinso at redhat.com> - 1.1.0-5.git310f6527
+- Fix new VM disk image names when VM name changes (bz #1169141)
+- Fix missing virt-install dep on pygobject (bz #1195794)
+- Fix changing VM video type away from qxl (bz #1182710)
+- Clear vendor field when changing CPU (bz #1190851)
+- Drop bogus network domain name validation (bz #1195873)
+
* Sun Nov 16 2014 Cole Robinson <crobinso at redhat.com> - 1.1.0-4.git310f6527
- Fix crash when rebooting VMs after install (bz #1135546)
- Fix dep on libosinfo (bz #1159370)
--
cgit v0.10.2
http://pkgs.fedoraproject.org/cgit/virt-manager.git/commit/?h=f21&id=d8c77829e247e3c7d9b478e694bfdf7855280fe0
More information about the scm-commits
mailing list