ia64/xen-unstable

changeset 19505:bdbe5232b068

xend: Use AUTO_PHP_SLOT where it ought to be

Signed-off-by: Simon Horman <horms@vereg.net.au>
author Keir Fraser <keir.fraser@citrix.com>
date Mon Apr 06 13:49:59 2009 +0100 (2009-04-06)
parents 5966b71195b4
children 3fecb8f43617
files tools/python/xen/xend/XendDomainInfo.py
line diff
     1.1 --- a/tools/python/xen/xend/XendDomainInfo.py	Mon Apr 06 13:49:16 2009 +0100
     1.2 +++ b/tools/python/xen/xend/XendDomainInfo.py	Mon Apr 06 13:49:59 2009 +0100
     1.3 @@ -620,7 +620,7 @@ class XendDomainInfo:
     1.4              pci_devs = pci_conf['devs']
     1.5              for x in pci_devs:
     1.6                  if (int(x['vslt'], 16) == int(new_dev['vslt'], 16) and
     1.7 -                   int(x['vslt'], 16) != 0 ):
     1.8 +                   int(x['vslt'], 16) != AUTO_PHP_SLOT):
     1.9                      raise VmError("vslot %s already have a device." % (new_dev['vslt']))
    1.10  
    1.11                  if (int(x['domain'], 16) == int(new_dev['domain'], 16) and
    1.12 @@ -1053,7 +1053,7 @@ class XendDomainInfo:
    1.13          if devnum >= pci_len:
    1.14              raise VmError("Device @ vslot 0x%x doesn't exist." % (vslot))
    1.15  
    1.16 -        if vslot == 0:
    1.17 +        if vslot == AUTO_PHP_SLOT:
    1.18              raise VmError("Device @ vslot 0x%x do not support hotplug." % (vslot))
    1.19  
    1.20          # Check the co-assignment.