]> git.karo-electronics.de Git - karo-tx-linux.git/commit
PCI: add pci_create_root_bus() that accepts resource list
authorBjorn Helgaas <bhelgaas@google.com>
Fri, 28 Oct 2011 22:25:45 +0000 (16:25 -0600)
committerJesse Barnes <jbarnes@virtuousgeek.org>
Tue, 6 Dec 2011 17:26:26 +0000 (09:26 -0800)
commita2f77b016ef6e6c06058bd506bbb8d903f26751d
tree734fd15d3b4113f02c7ce1246863c3414b2f9bb9
parent59ef3ad963acdc01b83f77c79fa8123d345b92de
PCI: add pci_create_root_bus() that accepts resource list

pci_create_bus() assigns ioport_resource and iomem_resource as the default
bus resources, i.e., the entire address space.  Architectures fix these
later, typically in pcibios_fixup_bus() or after pci_scan_bus_parented()
returns, but code that runs in the interim sees incorrect resource
information.

This patch adds a new pci_create_root_bus() that sets the bus resources
correctly from a supplied list of resources.

I intend to remove pci_create_bus() after changing all callers.

Based on original patch by Deng-Cheng Zhu.

Reference: http://www.spinics.net/lists/mips/msg41654.html
Reference: https://lkml.org/lkml/2011/8/26/88
Signed-off-by: Deng-Cheng Zhu <dczhu@mips.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
drivers/pci/probe.c
include/linux/pci.h