[Pkg-libvirt-commits] [virt-manager] 04/07: Drop patches, fixed upstream:

Guido Guenther agx at moszumanska.debian.org
Tue Aug 29 18:28:46 UTC 2017


This is an automated email from the git hooks/post-receive script.

agx pushed a commit to annotated tag debian/1%1.4.1-1
in repository virt-manager.

commit 6d547b130531d65ef4d700aaa0780280ae31978a
Author: Guido Günther <agx at sigxcpu.org>
Date:   Sat Aug 5 14:09:40 2017 -0300

    Drop patches, fixed upstream:
    
      Mark-Jessie-as-having-qemu-guest-agent.patch
      domain-add-support-to-rename-domain-with-nvram-vars-file.patch
      osdict-Fix-incorrect-usage-of-virtio-input.patch
      osdict-Don-t-return-virtio1.0-net-as-a-valid-device-name.patch
      We-can-t-clone-a-VM-in-some-scenarios.patch
---
 .../Mark-Jessie-as-having-qemu-guest-agent.patch   |  21 ---
 debian/patches/Use-usr-bin-python.patch            |  10 +-
 .../We-can-t-clone-a-VM-in-some-scenarios.patch    |  42 ------
 ...ort-to-rename-domain-with-nvram-vars-file.patch | 161 ---------------------
 ...turn-virtio1.0-net-as-a-valid-device-name.patch |  27 ----
 ...sdict-Fix-incorrect-usage-of-virtio-input.patch |  81 -----------
 debian/patches/series                              |   5 -
 debian/patches/virtinst/Fix-patch-to-pygrub.patch  |   4 +-
 .../patches/virtinst/fix-path-to-hvmloader.patch   |   4 +-
 9 files changed, 9 insertions(+), 346 deletions(-)

diff --git a/debian/patches/Mark-Jessie-as-having-qemu-guest-agent.patch b/debian/patches/Mark-Jessie-as-having-qemu-guest-agent.patch
deleted file mode 100644
index f20910d..0000000
--- a/debian/patches/Mark-Jessie-as-having-qemu-guest-agent.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From: =?utf-8?q?Guido_G=C3=BCnther?= <agx at sigxcpu.org>
-Date: Mon, 14 Nov 2016 11:34:58 +0100
-Subject: Mark Jessie as having qemu-guest-agent
-
----
- virtinst/osdict.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/virtinst/osdict.py b/virtinst/osdict.py
-index e8c1487..37426fd 100644
---- a/virtinst/osdict.py
-+++ b/virtinst/osdict.py
-@@ -500,7 +500,7 @@ class _OsVariant(object):
-         return False
- 
-     def supports_qemu_ga(self):
--        return self._is_related_to(["fedora18", "rhel6.0", "sles11sp4"])
-+        return self._is_related_to(["fedora18", "rhel6.0", "sles11sp4", "debian8"])
- 
-     def default_videomodel(self, guest):
-         if guest.os.is_pseries():
diff --git a/debian/patches/Use-usr-bin-python.patch b/debian/patches/Use-usr-bin-python.patch
index 667a79c..cc90aa9 100644
--- a/debian/patches/Use-usr-bin-python.patch
+++ b/debian/patches/Use-usr-bin-python.patch
@@ -14,7 +14,7 @@ so we don't have to worry about picking up the wrong version
  7 files changed, 7 insertions(+), 7 deletions(-)
 
 diff --git a/setup.py b/setup.py
-index 89916b5..af9221d 100755
+index 65118ae..778143a 100755
 --- a/setup.py
 +++ b/setup.py
 @@ -1,4 +1,4 @@
@@ -34,7 +34,7 @@ index 370584f..f0a5040 100755
  
  import atexit
 diff --git a/virt-clone b/virt-clone
-index 00d0e30..e83cb9e 100755
+index 572977a..fac3d1f 100755
 --- a/virt-clone
 +++ b/virt-clone
 @@ -1,4 +1,4 @@
@@ -54,7 +54,7 @@ index dd964f5..e2f408d 100755
  # Copyright 2008, 2013, 2014  Red Hat, Inc.
  # Joey Boggs <jboggs at redhat.com>
 diff --git a/virt-install b/virt-install
-index 817f4b3..4c0c62e 100755
+index f1da100..e66e674 100755
 --- a/virt-install
 +++ b/virt-install
 @@ -1,4 +1,4 @@
@@ -64,7 +64,7 @@ index 817f4b3..4c0c62e 100755
  # Copyright 2005-2014 Red Hat, Inc.
  #
 diff --git a/virt-manager b/virt-manager
-index 53b7356..fc196f0 100755
+index b3a8f69..0f457af 100755
 --- a/virt-manager
 +++ b/virt-manager
 @@ -1,4 +1,4 @@
@@ -74,7 +74,7 @@ index 53b7356..fc196f0 100755
  # Copyright (C) 2006, 2014 Red Hat, Inc.
  # Copyright (C) 2006 Daniel P. Berrange <berrange at redhat.com>
 diff --git a/virt-xml b/virt-xml
-index 39ca18e..4889a3b 100755
+index cfe3796..6ad7779 100755
 --- a/virt-xml
 +++ b/virt-xml
 @@ -1,4 +1,4 @@
diff --git a/debian/patches/We-can-t-clone-a-VM-in-some-scenarios.patch b/debian/patches/We-can-t-clone-a-VM-in-some-scenarios.patch
deleted file mode 100644
index 943048e..0000000
--- a/debian/patches/We-can-t-clone-a-VM-in-some-scenarios.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From: Chen Hanxiao <chenhanxiao at gmail.com>
-Date: Thu, 6 Oct 2016 23:12:59 +0800
-Subject: We can't clone a VM in some scenarios, such as a VM is active.
-
-This patch will disable 'Clone' label in VMActionMenu
-if we can't clone a VM,
-as same as we did for 'Clone' button in clone ui page.
-
-Signed-off-by: Chen Hanxiao <chenhanxiao at gmail.com>
----
- virtManager/domain.py | 4 ++++
- virtManager/vmmenu.py | 2 +-
- 2 files changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/virtManager/domain.py b/virtManager/domain.py
-index 3185cf8..b9abc76 100644
---- a/virtManager/domain.py
-+++ b/virtManager/domain.py
-@@ -1651,6 +1651,10 @@ class vmmDomain(vmmLibvirtObject):
-         return self.status() in [libvirt.VIR_DOMAIN_PAUSED]
-     def is_paused(self):
-         return self.status() in [libvirt.VIR_DOMAIN_PAUSED]
-+    def is_clonable(self):
-+        return self.status() in [libvirt.VIR_DOMAIN_SHUTOFF,
-+                                 libvirt.VIR_DOMAIN_PAUSED,
-+                                 libvirt.VIR_DOMAIN_PMSUSPENDED]
- 
-     def run_status(self):
-         return self.pretty_run_status(self.status(), self.has_managed_save())
-diff --git a/virtManager/vmmenu.py b/virtManager/vmmenu.py
-index a1ae375..bb23360 100644
---- a/virtManager/vmmenu.py
-+++ b/virtManager/vmmenu.py
-@@ -128,7 +128,7 @@ class VMActionMenu(_VMMenu):
-             "suspend": bool(vm and vm.is_stoppable()),
-             "resume": bool(vm and vm.is_paused()),
-             "migrate": bool(vm and vm.is_stoppable()),
--            "clone": True,
-+            "clone": bool(vm and vm.is_clonable()),
-         }
-         vismap = {
-             "suspend": bool(vm and not vm.is_paused()),
diff --git a/debian/patches/domain-add-support-to-rename-domain-with-nvram-vars-file.patch b/debian/patches/domain-add-support-to-rename-domain-with-nvram-vars-file.patch
deleted file mode 100644
index 9250184..0000000
--- a/debian/patches/domain-add-support-to-rename-domain-with-nvram-vars-file.patch
+++ /dev/null
@@ -1,161 +0,0 @@
-From: Pavel Hrdina <phrdina at redhat.com>
-Date: Mon, 6 Mar 2017 09:43:10 +0100
-Subject: domain: add support to rename domain with nvram vars file
-
-Libvirt storage API doesn't support renaming storage volumes so
-we need to copy the nvram file and remove the old one.
-
-Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1368922
-
-Signed-off-by: Pavel Hrdina <phrdina at redhat.com>
----
- virtManager/details.py |  2 +-
- virtManager/domain.py  | 76 ++++++++++++++++++++++++++++++++++++++++++++++++--
- 2 files changed, 74 insertions(+), 4 deletions(-)
-
-diff --git a/virtManager/details.py b/virtManager/details.py
-index b2f451d..9b4947c 100644
---- a/virtManager/details.py
-+++ b/virtManager/details.py
-@@ -1930,7 +1930,7 @@ class vmmDetails(vmmGObjectUI):
-         # This needs to be last
-         if self.edited(EDIT_NAME):
-             # Renaming is pretty convoluted, so do it here synchronously
--            self.vm.define_name(self.widget("overview-name").get_text())
-+            self.vm.rename_domain(self.widget("overview-name").get_text())
- 
-             if not kwargs and not hotplug_args:
-                 # Saves some useless redefine attempts
-diff --git a/virtManager/domain.py b/virtManager/domain.py
-index b9abc76..7a135d8 100644
---- a/virtManager/domain.py
-+++ b/virtManager/domain.py
-@@ -32,6 +32,7 @@ from virtinst import DomainSnapshot
- from virtinst import Guest
- from virtinst import util
- from virtinst import VirtualController
-+from virtinst import VirtualDisk
- 
- from .libvirtobject import vmmLibvirtObject
- 
-@@ -479,6 +480,10 @@ class vmmDomain(vmmLibvirtObject):
-             return "-"
-         return str(i)
- 
-+    def has_nvram(self):
-+        return bool(self.get_xmlobj().os.loader_ro is True and
-+                    self.get_xmlobj().os.loader_type == "pflash")
-+
-     ##################
-     # Support checks #
-     ##################
-@@ -552,11 +557,65 @@ class vmmDomain(vmmLibvirtObject):
-         raise RuntimeError(_("Could not find specified device in the "
-                              "inactive VM configuration: %s") % repr(origdev))
- 
-+    def _copy_nvram_file(self, new_name):
-+        """
-+        We need to do this copy magic because there is no Libvirt storage API
-+        to rename storage volume.
-+        """
-+        old_nvram = VirtualDisk(self.conn.get_backend())
-+        old_nvram.path = self.get_xmlobj().os.nvram
-+
-+        nvram_dir = os.path.dirname(old_nvram.path)
-+        new_nvram_path = os.path.join(nvram_dir, "%s_VARS.fd" % new_name)
-+
-+        new_nvram = VirtualDisk(self.conn.get_backend())
-+        new_nvram.path = new_nvram_path
-+
-+        nvram_install = VirtualDisk.build_vol_install(
-+                self.conn.get_backend(), os.path.basename(new_nvram.path),
-+                new_nvram.get_parent_pool(), new_nvram.get_size(), False)
-+        nvram_install.input_vol = old_nvram.get_vol_object()
-+        nvram_install.sync_input_vol(only_format=True)
-+
-+        new_nvram.set_vol_install(nvram_install)
-+        new_nvram.validate()
-+        new_nvram.setup()
-+
-+        return new_nvram, old_nvram
-+
- 
-     ##############################
-     # Persistent XML change APIs #
-     ##############################
- 
-+    def rename_domain(self, new_name):
-+        new_nvram = None
-+        old_nvram = None
-+        if self.has_nvram():
-+            try:
-+                new_nvram, old_nvram = self._copy_nvram_file(new_name)
-+            except Exception as error:
-+                raise RuntimeError("Cannot rename nvram VARS: '%s'" % error)
-+
-+        try:
-+            self.define_name(new_name)
-+        except Exception as error:
-+            if new_nvram:
-+                try:
-+                    new_nvram.get_vol_object().delete(0)
-+                except Exception as warn:
-+                    logging.debug("rename failed and new nvram was not "
-+                                  "removed: '%s'", warn)
-+            raise error
-+
-+        if new_nvram:
-+            try:
-+                old_nvram.get_vol_object().delete(0)
-+            except Exception as warn:
-+                logging.debug("old nvram file was not removed: '%s'", warn)
-+
-+            self.define_overview(nvram=new_nvram.path)
-+
-     # Device Add/Remove
-     def add_device(self, devobj):
-         """
-@@ -621,7 +680,8 @@ class vmmDomain(vmmLibvirtObject):
-         self._redefine_xmlobj(guest)
- 
-     def define_overview(self, machine=_SENTINEL, description=_SENTINEL,
--        title=_SENTINEL, idmap_list=_SENTINEL, loader=_SENTINEL):
-+        title=_SENTINEL, idmap_list=_SENTINEL, loader=_SENTINEL,
-+        nvram=_SENTINEL):
-         guest = self._make_xmlobj_to_define()
-         if machine != _SENTINEL:
-             guest.os.machine = machine
-@@ -644,6 +704,9 @@ class vmmDomain(vmmLibvirtObject):
-                 guest.os.loader_type = "pflash"
-                 guest.os.loader_ro = True
- 
-+        if nvram != _SENTINEL:
-+            guest.os.nvram = nvram
-+
-         if idmap_list != _SENTINEL:
-             if idmap_list is not None:
-                 # pylint: disable=unpacking-non-sequence
-@@ -1409,14 +1472,21 @@ class vmmDomain(vmmLibvirtObject):
- 
-     @vmmLibvirtObject.lifecycle_action
-     def delete(self, force=True):
-+        """
-+        @force: True if we are deleting domain, False if we are renaming domain
-+
-+        If the domain is renamed we need to keep the nvram file.
-+        """
-         flags = 0
-         if force:
-             flags |= getattr(libvirt,
-                              "VIR_DOMAIN_UNDEFINE_SNAPSHOTS_METADATA", 0)
-             flags |= getattr(libvirt, "VIR_DOMAIN_UNDEFINE_MANAGED_SAVE", 0)
--            if (self.get_xmlobj().os.loader_ro is True and
--                self.get_xmlobj().os.loader_type == "pflash"):
-+            if self.has_nvram():
-                 flags |= getattr(libvirt, "VIR_DOMAIN_UNDEFINE_NVRAM", 0)
-+        else:
-+            if self.has_nvram():
-+                flags |= getattr(libvirt, "VIR_DOMAIN_UNDEFINE_KEEP_NVRAM", 0)
-         try:
-             self._backend.undefineFlags(flags)
-         except libvirt.libvirtError:
diff --git a/debian/patches/osdict-Don-t-return-virtio1.0-net-as-a-valid-device-name.patch b/debian/patches/osdict-Don-t-return-virtio1.0-net-as-a-valid-device-name.patch
deleted file mode 100644
index a74865f..0000000
--- a/debian/patches/osdict-Don-t-return-virtio1.0-net-as-a-valid-device-name.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From: Cole Robinson <crobinso at redhat.com>
-Date: Tue, 13 Dec 2016 12:58:14 -0500
-Subject: osdict: Don't return virtio1.0-net as a valid device name
-
-We can't depend on libosinfo device names being valid libvirt network
-model names, so use a whitelist
-
-https://bugzilla.redhat.com/show_bug.cgi?id=1399083
-
-Closes: #846356
----
- virtinst/osdict.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/virtinst/osdict.py b/virtinst/osdict.py
-index 37426fd..38d626d 100644
---- a/virtinst/osdict.py
-+++ b/virtinst/osdict.py
-@@ -453,7 +453,7 @@ class _OsVariant(object):
-         devs = self._os.get_all_devices(fltr)
-         for idx in range(devs.get_length()):
-             devname = devs.get_nth(idx).get_name()
--            if devname != "virtio-net":
-+            if devname in ["pcnet", "ne2k_pci", "rtl8139", "e1000"]:
-                 return devname
-         return None
- 
diff --git a/debian/patches/osdict-Fix-incorrect-usage-of-virtio-input.patch b/debian/patches/osdict-Fix-incorrect-usage-of-virtio-input.patch
deleted file mode 100644
index 765f375..0000000
--- a/debian/patches/osdict-Fix-incorrect-usage-of-virtio-input.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-From: Cole Robinson <crobinso at redhat.com>
-Date: Fri, 29 Jul 2016 13:17:36 -0400
-Subject: osdict: Fix incorrect usage of virtio input
-
-Regression reported with latest libosinfo, when the OS reports
-virtio-input support:
-
-http://www.redhat.com/archives/virt-tools-list/2016-July/msg00109.html
-
-Really our code presently only cares about the USB tablet, so adjust
-our libosinfo lookup to explicitly check for it
----
- virtinst/guest.py  | 11 +++++------
- virtinst/osdict.py | 28 ++++++++++++----------------
- 2 files changed, 17 insertions(+), 22 deletions(-)
-
-diff --git a/virtinst/guest.py b/virtinst/guest.py
-index 957e818..e24e233 100644
---- a/virtinst/guest.py
-+++ b/virtinst/guest.py
-@@ -1031,15 +1031,14 @@ class Guest(XMLBuilder):
-                 return False
-             return all([c.model == "none" for c in controllers])
- 
--        input_type = self._os_object.default_inputtype()
--        input_bus = self._os_object.default_inputbus()
-+        input_type = "mouse"
-+        input_bus = "ps2"
-         if self.os.is_xenpv():
-             input_type = VirtualInputDevice.TYPE_MOUSE
-             input_bus = VirtualInputDevice.BUS_XEN
--        elif _usb_disabled() and input_bus == "usb":
--            input_bus = "ps2"
--            if input_type == "tablet":
--                input_type = "mouse"
-+        elif self._os_object.supports_usbtablet() and not _usb_disabled():
-+            input_type = "tablet"
-+            input_bus = "usb"
- 
-         for inp in self.get_devices("input"):
-             if (inp.type == inp.TYPE_DEFAULT and
-diff --git a/virtinst/osdict.py b/virtinst/osdict.py
-index 38d626d..8b0ef7b 100644
---- a/virtinst/osdict.py
-+++ b/virtinst/osdict.py
-@@ -457,23 +457,19 @@ class _OsVariant(object):
-                 return devname
-         return None
- 
--    def default_inputtype(self):
--        if self._os:
--            fltr = libosinfo.Filter()
--            fltr.add_constraint("class", "input")
--            devs = self._os.get_all_devices(fltr)
--            if devs.get_length():
--                return devs.get_nth(0).get_name()
--        return "mouse"
-+    def supports_usbtablet(self):
-+        if not self._os:
-+            return False
- 
--    def default_inputbus(self):
--        if self._os:
--            fltr = libosinfo.Filter()
--            fltr.add_constraint("class", "input")
--            devs = self._os.get_all_devices(fltr)
--            if devs.get_length():
--                return devs.get_nth(0).get_bus_type()
--        return "ps2"
-+        fltr = libosinfo.Filter()
-+        fltr.add_constraint("class", "input")
-+        fltr.add_constraint("name", "tablet")
-+        devs = self._os.get_all_devices(fltr)
-+        for idx in range(devs.get_length()):
-+            dev = devs.get_nth(idx)
-+            if devs.get_nth(idx).get_bus_type() == "usb":
-+                return True
-+        return False
- 
-     def supports_virtiodisk(self):
-         if self._os:
diff --git a/debian/patches/series b/debian/patches/series
index 69fedaf..71f0093 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,8 +1,3 @@
 virtinst/fix-path-to-hvmloader.patch
 virtinst/Fix-patch-to-pygrub.patch
-Mark-Jessie-as-having-qemu-guest-agent.patch
-osdict-Don-t-return-virtio1.0-net-as-a-valid-device-name.patch
-We-can-t-clone-a-VM-in-some-scenarios.patch
 Use-usr-bin-python.patch
-osdict-Fix-incorrect-usage-of-virtio-input.patch
-domain-add-support-to-rename-domain-with-nvram-vars-file.patch
diff --git a/debian/patches/virtinst/Fix-patch-to-pygrub.patch b/debian/patches/virtinst/Fix-patch-to-pygrub.patch
index 963b0c4..658f7f3 100644
--- a/debian/patches/virtinst/Fix-patch-to-pygrub.patch
+++ b/debian/patches/virtinst/Fix-patch-to-pygrub.patch
@@ -8,10 +8,10 @@ Closes: #685749
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/virtinst/guest.py b/virtinst/guest.py
-index 14be763..957e818 100644
+index 8fad018..fa0aec7 100644
 --- a/virtinst/guest.py
 +++ b/virtinst/guest.py
-@@ -362,7 +362,7 @@ class Guest(XMLBuilder):
+@@ -363,7 +363,7 @@ class Guest(XMLBuilder):
          if (not install and
              self.os.is_xenpv() and
              not self.os.kernel):
diff --git a/debian/patches/virtinst/fix-path-to-hvmloader.patch b/debian/patches/virtinst/fix-path-to-hvmloader.patch
index dd55aa4..ecb6408 100644
--- a/debian/patches/virtinst/fix-path-to-hvmloader.patch
+++ b/debian/patches/virtinst/fix-path-to-hvmloader.patch
@@ -8,10 +8,10 @@ Closes: #685749
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/virtinst/guest.py b/virtinst/guest.py
-index 6a42536..14be763 100644
+index f3e3b09..8fad018 100644
 --- a/virtinst/guest.py
 +++ b/virtinst/guest.py
-@@ -694,7 +694,7 @@ class Guest(XMLBuilder):
+@@ -730,7 +730,7 @@ class Guest(XMLBuilder):
              self.os.init = self.os.init or "/bin/sh"
  
          if not self.os.loader and self.os.is_hvm() and self.type == "xen":

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-libvirt/virt-manager.git



More information about the Pkg-libvirt-commits mailing list