WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [patch 02/17] xend: pass-through: Only call setupOneDevice()

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [patch 02/17] xend: pass-through: Only call setupOneDevice() once per device
From: Simon Horman <horms@xxxxxxxxxxxx>
Date: Wed, 17 Jun 2009 12:56:14 +1000
Cc: Zhigang Wang <zhigang.x.wang@xxxxxxxxxx>, Akio Takebe <takebe_akio@xxxxxxxxxxxxxx>, Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx>, Dexuan Cui <dexuan.cui@xxxxxxxxx>
Delivery-date: Tue, 16 Jun 2009 20:27:45 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20090617025612.786241401@xxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: quilt/0.46-1
As observed by Dexuan Cui, when PCI devices are passed through at
domain-creation-time setupOneDevice() will be called twice.

Once via setupDevice() and once via econfigureDevice() which
is called in pci_device_configure().

This patch removes the first of these.

Cc: Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx>
Acked-by: Dexuan Cui <dexuan.cui@xxxxxxxxx>
Signed-off-by: Simon Horman <horms@xxxxxxxxxxxx>

Index: xen-unstable.hg/tools/python/xen/xend/server/pciif.py
===================================================================
--- xen-unstable.hg.orig/tools/python/xen/xend/server/pciif.py  2009-06-15 
11:24:00.000000000 +1000
+++ xen-unstable.hg/tools/python/xen/xend/server/pciif.py       2009-06-15 
11:24:02.000000000 +1000
@@ -436,8 +436,6 @@ class PciController(DevController):
                                     ' same guest with %s'
                                 raise VmError(err_msg % (s, dev.name))
 
-        for (domain, bus, slot, func) in pci_dev_list:
-            self.setupOneDevice(domain, bus, slot, func)
         wPath = '/local/domain/0/backend/pci/%u/0/aerState' % (self.getDomid())
         self.aerStateWatch = xswatch(wPath, self._handleAerStateWatch)
         log.debug('pci: register aer watch %s', wPath)

-- 

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel