Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

PCI: Make pci_setup_bridge() non-static for use by arch code

The "powernv" platform of the powerpc architecture needs to assign PCI
resources using a specific algorithm to fit some HW constraints of
the IBM "IODA" architecture (related to the ability to create error
handling domains that encompass specific segments of MMIO space).

For doing so, it wants to call pci_setup_bridge() from architecture
specific resource management in order to configure bridges after all
resources have been assigned. So make it non-static.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>

authored by

Benjamin Herrenschmidt and committed by
Jesse Barnes
e2444273 72da0b07

+2 -1
+1 -1
drivers/pci/setup-bus.c
··· 426 426 pci_write_config_word(bridge, PCI_BRIDGE_CONTROL, bus->bridge_ctl); 427 427 } 428 428 429 - static void pci_setup_bridge(struct pci_bus *bus) 429 + void pci_setup_bridge(struct pci_bus *bus) 430 430 { 431 431 unsigned long type = IORESOURCE_IO | IORESOURCE_MEM | 432 432 IORESOURCE_PREFETCH;
+1
include/linux/pci.h
··· 955 955 int pci_cfg_space_size_ext(struct pci_dev *dev); 956 956 int pci_cfg_space_size(struct pci_dev *dev); 957 957 unsigned char pci_bus_max_busnr(struct pci_bus *bus); 958 + void pci_setup_bridge(struct pci_bus *bus); 958 959 959 960 #define PCI_VGA_STATE_CHANGE_BRIDGE (1 << 0) 960 961 #define PCI_VGA_STATE_CHANGE_DECODES (1 << 1)