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/
Home Products Support Community News


[Xen-devel] [patch] xm: Add missing AUTO_PHP_SLOT

To: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] [patch] xm: Add missing AUTO_PHP_SLOT
From: Simon Horman <horms@xxxxxxxxxxxx>
Date: Mon, 6 Apr 2009 08:50:10 +1000
Cc: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>, Keir Fraser <Keir.Fraser@xxxxxxxxxxxxx>, "Cui, Dexuan" <dexuan.cui@xxxxxxxxx>
Delivery-date: Sun, 05 Apr 2009 15:50:39 -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>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.18 (2008-05-17)
This patch changes over a few sections of code that
I missed when adding AUTO_PHP_SLOT to signify that
qemu-xen should pick a slot - previously 0 was used.

I have not experienced any breakage as a result of these
changes being missing, nor am I even sure that is possible.
But it seems worthwhile to clean things up in this way for 3.4.
And possibly remove the (spurious?) checks afterwards.

Signed-off-by: Simon Horman <horms@xxxxxxxxxxxx>

Index: xen-unstable.hg/tools/python/xen/xend/XendDomainInfo.py
--- xen-unstable.hg.orig/tools/python/xen/xend/XendDomainInfo.py        
2009-04-06 08:20:31.000000000 +1000
+++ xen-unstable.hg/tools/python/xen/xend/XendDomainInfo.py     2009-04-06 
08:42:01.000000000 +1000
@@ -619,7 +619,7 @@ class XendDomainInfo:
             pci_devs = pci_conf['devs']
             for x in pci_devs:
                 if (int(x['vslt'], 16) == int(new_dev['vslt'], 16) and
-                   int(x['vslt'], 16) != 0 ):
+                   int(x['vslt'], 16) != AUTO_PHP_SLOT):
                     raise VmError("vslot %s already have a device." % 
                 if (int(x['domain'], 16) == int(new_dev['domain'], 16) and
@@ -1045,7 +1045,7 @@ class XendDomainInfo:
         if devnum >= pci_len:
             raise VmError("Device @ vslot 0x%x doesn't exist." % (vslot))
-        if vslot == 0:
+        if vslot == AUTO_PHP_SLOT:
             raise VmError("Device @ vslot 0x%x do not support hotplug." % 
         # Check the co-assignment.

Xen-devel mailing list

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [patch] xm: Add missing AUTO_PHP_SLOT, Simon Horman <=