diff options
author | Jason Gunthorpe <jgunthorpe@obsidianresearch.com> | 2012-11-21 13:25:28 -0500 |
---|---|---|
committer | Jason Cooper <jason@lakedaemon.net> | 2013-01-30 15:13:38 -0500 |
commit | b73690c8f8b5d12ed32e10fb787f54e4b4ca232b (patch) | |
tree | 663c296ce01ab18b0c035c4c506b1efc575707b5 /arch/arm/mach-kirkwood | |
parent | 183cadc962a7d721c83e1922295262ea1c824ce1 (diff) |
ARM: Kirkwood: Support basic hotplug for PCI-E
Unconditionally register the PCI-E bus, even if the link is currently
down. When the link is brought up the bus can be scanned through
/sys/bus/pci/rescan or otherwise. Since the HW has no interrupt for
link up, userspace will have to take care of the timing.
An earlier version of this was contingent on CONFIG_HOTPLUG, but
that is being removed from the kernel.
This also fixes printing the link up/down message to be displayed
on one line (structured logging broke this?)
Signed-off-by: Jason Gunthorpe <jgunthorpe@obsidianresearch.com>
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
Diffstat (limited to 'arch/arm/mach-kirkwood')
-rw-r--r-- | arch/arm/mach-kirkwood/pcie.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/arch/arm/mach-kirkwood/pcie.c b/arch/arm/mach-kirkwood/pcie.c index a1c3ab6fc809..d96ad4c09972 100644 --- a/arch/arm/mach-kirkwood/pcie.c +++ b/arch/arm/mach-kirkwood/pcie.c | |||
@@ -247,13 +247,9 @@ static struct hw_pci kirkwood_pci __initdata = { | |||
247 | 247 | ||
248 | static void __init add_pcie_port(int index, void __iomem *base) | 248 | static void __init add_pcie_port(int index, void __iomem *base) |
249 | { | 249 | { |
250 | pr_info("Kirkwood PCIe port %d: ", index); | 250 | pcie_port_map[num_pcie_ports++] = index; |
251 | 251 | pr_info("Kirkwood PCIe port %d: link %s\n", index, | |
252 | if (orion_pcie_link_up(base)) { | 252 | orion_pcie_link_up(base) ? "up" : "down"); |
253 | pr_info("link up\n"); | ||
254 | pcie_port_map[num_pcie_ports++] = index; | ||
255 | } else | ||
256 | pr_info("link down, ignoring\n"); | ||
257 | } | 253 | } |
258 | 254 | ||
259 | void __init kirkwood_pcie_init(unsigned int portmask) | 255 | void __init kirkwood_pcie_init(unsigned int portmask) |