diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2013-06-14 17:47:46 -0600 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2013-06-14 17:47:46 -0600 |
commit | df58f46c0f2a1d69268b734ac25c87ffb7aeb32a (patch) | |
tree | 46540d251f4f1c1e44af8d5ce339b37e0045ffe0 /arch | |
parent | 726246d2e6d0ed53ac22b6fec50d1345f25e6730 (diff) | |
parent | 050134864c1c76f49eb86c134a0e02fb3c196382 (diff) | |
download | op-kernel-dev-df58f46c0f2a1d69268b734ac25c87ffb7aeb32a.zip op-kernel-dev-df58f46c0f2a1d69268b734ac25c87ffb7aeb32a.tar.gz |
Merge branch 'pci/jiang-bus-lock-v3' into next
* pci/jiang-bus-lock-v3:
PCI: Return early on allocation failures to unindent mainline code
PCI: Simplify IOV implementation and fix reference count races
PCI: Drop redundant setting of bus->is_added in virtfn_add_bus()
unicore32/PCI: Remove redundant call of pci_bus_add_devices()
m68k/PCI: Remove redundant call of pci_bus_add_devices()
PCI: Rename pci_release_bus_bridge_dev() to pci_release_host_bridge_dev()
PCI: Fix refcount issue in pci_create_root_bus() error recovery path
ia64/PCI: Clean up pci_scan_root_bus() usage
PCI: Convert alloc_pci_dev(void) to pci_alloc_dev(bus)
PCI: Introduce pci_alloc_dev(struct pci_bus*) to replace alloc_pci_dev()
PCI: Introduce pci_bus_{get|put}() to manage PCI bus reference count
Conflicts:
drivers/pci/probe.c
Diffstat (limited to 'arch')
-rw-r--r-- | arch/ia64/sn/kernel/io_init.c | 11 | ||||
-rw-r--r-- | arch/m68k/platform/coldfire/pci.c | 1 | ||||
-rw-r--r-- | arch/powerpc/kernel/pci_of_scan.c | 3 | ||||
-rw-r--r-- | arch/sparc/kernel/pci.c | 3 | ||||
-rw-r--r-- | arch/unicore32/kernel/pci.c | 5 |
5 files changed, 3 insertions, 20 deletions
diff --git a/arch/ia64/sn/kernel/io_init.c b/arch/ia64/sn/kernel/io_init.c index 238e2c5..e2c7733 100644 --- a/arch/ia64/sn/kernel/io_init.c +++ b/arch/ia64/sn/kernel/io_init.c @@ -326,16 +326,7 @@ sn_pci_controller_fixup(int segment, int busnum, struct pci_bus *bus) bus = pci_scan_root_bus(NULL, busnum, &pci_root_ops, controller, &resources); if (bus == NULL) - goto error_return; /* error, or bus already scanned */ - - bus->sysdata = controller; - - return; - -error_return: - - kfree(controller); - return; + kfree(controller); } /* diff --git a/arch/m68k/platform/coldfire/pci.c b/arch/m68k/platform/coldfire/pci.c index 8572246..b33f97a 100644 --- a/arch/m68k/platform/coldfire/pci.c +++ b/arch/m68k/platform/coldfire/pci.c @@ -320,7 +320,6 @@ static int __init mcf_pci_init(void) pci_bus_size_bridges(rootbus); pci_bus_assign_resources(rootbus); pci_enable_bridges(rootbus); - pci_bus_add_devices(rootbus); return 0; } diff --git a/arch/powerpc/kernel/pci_of_scan.c b/arch/powerpc/kernel/pci_of_scan.c index d2d407d..6b0ba58 100644 --- a/arch/powerpc/kernel/pci_of_scan.c +++ b/arch/powerpc/kernel/pci_of_scan.c @@ -128,7 +128,7 @@ struct pci_dev *of_create_pci_dev(struct device_node *node, const char *type; struct pci_slot *slot; - dev = alloc_pci_dev(); + dev = pci_alloc_dev(bus); if (!dev) return NULL; type = of_get_property(node, "device_type", NULL); @@ -137,7 +137,6 @@ struct pci_dev *of_create_pci_dev(struct device_node *node, pr_debug(" create device, devfn: %x, type: %s\n", devfn, type); - dev->bus = bus; dev->dev.of_node = of_node_get(node); dev->dev.parent = bus->bridge; dev->dev.bus = &pci_bus_type; diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c index 972892a..b16f624 100644 --- a/arch/sparc/kernel/pci.c +++ b/arch/sparc/kernel/pci.c @@ -254,7 +254,7 @@ static struct pci_dev *of_create_pci_dev(struct pci_pbm_info *pbm, const char *type; u32 class; - dev = alloc_pci_dev(); + dev = pci_alloc_dev(bus); if (!dev) return NULL; @@ -281,7 +281,6 @@ static struct pci_dev *of_create_pci_dev(struct pci_pbm_info *pbm, printk(" create device, devfn: %x, type: %s\n", devfn, type); - dev->bus = bus; dev->sysdata = node; dev->dev.parent = bus->bridge; dev->dev.bus = &pci_bus_type; diff --git a/arch/unicore32/kernel/pci.c b/arch/unicore32/kernel/pci.c index ef69c0c..374a055 100644 --- a/arch/unicore32/kernel/pci.c +++ b/arch/unicore32/kernel/pci.c @@ -277,11 +277,6 @@ static int __init pci_common_init(void) pci_bus_assign_resources(puv3_bus); } - /* - * Tell drivers about devices found. - */ - pci_bus_add_devices(puv3_bus); - return 0; } subsys_initcall(pci_common_init); |