ia64/linux-2.6.18-xen.hg

changeset 634:87413eba04ab

Don't WARN_ON -ENOSYS from PHYSDEVOP_manage_pci_remove

We let -ENOSYS slip through on the add side to support old
hypervisors, let's do the same on the remove end so we don't get stack
dumps during bootup.

Signed-off-by: Alex Williamson <alex.williamson@hp.com>
author Keir Fraser <keir.fraser@citrix.com>
date Fri Aug 08 10:54:59 2008 +0100 (2008-08-08)
parents 2866e6af503e
children ff6ba016eed2
files drivers/xen/core/pci.c
line diff
     1.1 --- a/drivers/xen/core/pci.c	Thu Jul 31 15:33:54 2008 +0100
     1.2 +++ b/drivers/xen/core/pci.c	Fri Aug 08 10:54:59 2008 +0100
     1.3 @@ -23,9 +23,13 @@ static int pci_bus_probe_wrapper(struct 
     1.4  		return r;
     1.5  
     1.6  	r = pci_bus_probe(dev);
     1.7 -	if (r)
     1.8 -		WARN_ON(HYPERVISOR_physdev_op(PHYSDEVOP_manage_pci_remove,
     1.9 -					      &manage_pci));
    1.10 +	if (r) {
    1.11 +		int ret;
    1.12 +
    1.13 +		ret = HYPERVISOR_physdev_op(PHYSDEVOP_manage_pci_remove,
    1.14 +					    &manage_pci);
    1.15 +		WARN_ON(ret && ret != -ENOSYS);
    1.16 +	}
    1.17  
    1.18  	return r;
    1.19  }