[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [linux-2.6.18-xen] PCI: suppress bogus warning on old hypervisors
# HG changeset patch # User Jan Beulich <jbeulich@xxxxxxxx> # Date 1348652101 -7200 # Node ID a752ff67b472662f15883f179e554cc64a87b272 # Parent 6741142f164f772e4a77d7a3a3fbfdbbb8f6e077 PCI: suppress bogus warning on old hypervisors pci_bus_remove_wrapper() warned even for the -ENOSYS case. By detecting the missing support early (in pci_bus_probe_wrapper()) we can avoid this by removing the hooks altogether in this case. Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> --- diff -r 6741142f164f -r a752ff67b472 drivers/xen/core/pci.c --- a/drivers/xen/core/pci.c Wed Sep 26 11:32:20 2012 +0200 +++ b/drivers/xen/core/pci.c Wed Sep 26 11:35:01 2012 +0200 @@ -45,8 +45,21 @@ static int pci_bus_probe_wrapper(struct r = HYPERVISOR_physdev_op(PHYSDEVOP_manage_pci_add, &manage_pci); } - if (r && r != -ENOSYS) + + switch (r) { + case 0: + break; +#if CONFIG_XEN_COMPAT < 0x030300 + case -ENOSYS: + if (!manage_pci_ext.is_virtfn && !manage_pci_ext.is_extfn) { + pci_bus_type.probe = pci_bus_probe; + pci_bus_type.remove = pci_bus_remove; + } + break; +#endif + default: return r; + } r = pci_bus_probe(dev); return r; _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |