rpms/libvirt/devel libvirt-0.6.3-hostdev-managed.patch, NONE, 1.1 Makefile, 1.2, 1.3 libvirt.spec, 1.128, 1.129

Mark McLoughlin markmc at fedoraproject.org
Wed May 6 15:46:28 UTC 2009


Author: markmc

Update of /cvs/pkgs/rpms/libvirt/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv2354

Modified Files:
	Makefile libvirt.spec 
Added Files:
	libvirt-0.6.3-hostdev-managed.patch 
Log Message:
* Wed May  6 2009 Mark McLoughlin <markmc at redhat.com> - 0.6.3-5.fc12
- Fix handling of <hostdev managed='yes'> (bug #499386)


libvirt-0.6.3-hostdev-managed.patch:

--- NEW FILE libvirt-0.6.3-hostdev-managed.patch ---
>From 3d7771e0570e09096ad9391a857dad48b150bc0c Mon Sep 17 00:00:00 2001
From: Mark McLoughlin <markmc at redhat.com>
Date: Wed, 6 May 2009 16:33:28 +0100
Subject: [PATCH] Fix qemu driver's interpretation of <hostdev managed='yes'/>

This change:

  Tue Mar  3 08:55:13 GMT 2009 Daniel P. Berrange <berrange at redhat.com>

       Don't try to detach & reset PCI devices while running test
       suite for XML-> ARGV conversion.
       * src/qemu_driver.c: Add qemuPrepareHostDevices() helper to
       detach and reset PCI devices.
       * src/qemu_conf.c: Don't detach & reset PCI devices while
       building the command line argv

accidentally did this:

-            if (hostdev->managed) {
+        if (!hostdev->managed) {

Which results in managed='yes' not causing the device to be
detached when the guest is starting.

Signed-off-by: Mark McLoughlin <markmc at redhat.com>
---
 src/qemu_driver.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/qemu_driver.c b/src/qemu_driver.c
index 5898026..59312c0 100644
--- a/src/qemu_driver.c
+++ b/src/qemu_driver.c
@@ -1215,7 +1215,7 @@ static int qemuPrepareHostDevices(virConnectPtr conn,
         if (hostdev->source.subsys.type != VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_PCI)
             continue;
 
-        if (!hostdev->managed) {
+        if (hostdev->managed) {
             pciDevice *dev = pciGetDevice(conn,
                                           hostdev->source.subsys.u.pci.domain,
                                           hostdev->source.subsys.u.pci.bus,
-- 
1.6.0.6



Index: Makefile
===================================================================
RCS file: /cvs/pkgs/rpms/libvirt/devel/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -p -r1.2 -r1.3
--- Makefile	15 Oct 2007 19:05:00 -0000	1.2
+++ Makefile	6 May 2009 15:45:57 -0000	1.3
@@ -19,3 +19,7 @@ MAKEFILE_COMMON := $(shell $(checkout-ma
 endif
 
 include $(MAKEFILE_COMMON)
+
+ifeq ($(BRANCH),devel)
+include Makefile.preview
+endif


Index: libvirt.spec
===================================================================
RCS file: /cvs/pkgs/rpms/libvirt/devel/libvirt.spec,v
retrieving revision 1.128
retrieving revision 1.129
diff -u -p -r1.128 -r1.129
--- libvirt.spec	5 May 2009 13:38:26 -0000	1.128
+++ libvirt.spec	6 May 2009 15:45:57 -0000	1.129
@@ -55,14 +55,14 @@
 Summary: Library providing a simple API virtualization
 Name: libvirt
 Version: 0.6.3
-Release: 4%{?dist}%{?extra_release}
+Release: 5%{?dist}%{?extra_release}
 License: LGPLv2+
 Group: Development/Libraries
 Source: libvirt-%{version}.tar.gz
 
 # Patches cherry-picked from upstream
-# N/A
 Patch1: libvirt-0.6.3-shared-readonly-label.patch
+Patch2: libvirt-0.6.3-hostdev-managed.patch
 
 # Not for upstream. Temporary hack till PulseAudio autostart
 # problems are sorted out when SELinux enforcing
@@ -217,6 +217,7 @@ of recent versions of Linux (and other O
 %prep
 %setup -q
 %patch1 -p1
+%patch2 -p1
 
 %patch200 -p0
 
@@ -547,6 +548,9 @@ fi
 %endif
 
 %changelog
+* Wed May  6 2009 Mark McLoughlin <markmc at redhat.com> - 0.6.3-5.fc12
+- Fix handling of <hostdev managed='yes'> (bug #499386)
+
 * Tue May  5 2009 Daniel Berrange <berrange at redhat.com> - 0.6.3-4.fc12
 - Fix readonly/shared disk image labelling (rhbz #493692)
 




More information about the scm-commits mailing list