ia64/xen-unstable

changeset 19641:caa8c0e2d6f6

xend: Fix xm pci-detach for inactive devices

In the case where a device is attached to an inactive domain
and then removed before the domain is activated it won't have
a vslot assigned, but it should still be valid to remove it.

I don't think that there are any other cases where vslot can
be invalid.
Signed-off-by: Simon Horman <horms@verge.net.au>
author Keir Fraser <keir.fraser@citrix.com>
date Tue May 26 10:03:09 2009 +0100 (2009-05-26)
parents cc682927d123
children dc7de36c94e3
files tools/python/xen/xend/XendDomainInfo.py
line diff
     1.1 --- a/tools/python/xen/xend/XendDomainInfo.py	Tue May 26 10:01:54 2009 +0100
     1.2 +++ b/tools/python/xen/xend/XendDomainInfo.py	Tue May 26 10:03:09 2009 +0100
     1.3 @@ -1130,9 +1130,6 @@ class XendDomainInfo:
     1.4          if devnum >= pci_len:
     1.5              raise VmError("Device @ vslot 0x%x doesn't exist." % (vslot))
     1.6  
     1.7 -        if vslot == AUTO_PHP_SLOT:
     1.8 -            raise VmError("Device @ vslot 0x%x doesn't support hotplug." % (vslot))
     1.9 -
    1.10          # Check the co-assignment.
    1.11          # To pci-detach a device D from domN, we should ensure: for each DD in the
    1.12          # list of D's co-assignment devices, DD is not assigned (to domN).