Skip to content

Commit b73690c

Browse files
jgunthorpeJason Cooper
authored andcommitted
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 <[email protected]> Signed-off-by: Jason Cooper <[email protected]>
1 parent 183cadc commit b73690c

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

arch/arm/mach-kirkwood/pcie.c

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -247,13 +247,9 @@ static struct hw_pci kirkwood_pci __initdata = {
247247

248248
static void __init add_pcie_port(int index, void __iomem *base)
249249
{
250-
pr_info("Kirkwood PCIe port %d: ", index);
251-
252-
if (orion_pcie_link_up(base)) {
253-
pr_info("link up\n");
254-
pcie_port_map[num_pcie_ports++] = index;
255-
} else
256-
pr_info("link down, ignoring\n");
250+
pcie_port_map[num_pcie_ports++] = index;
251+
pr_info("Kirkwood PCIe port %d: link %s\n", index,
252+
orion_pcie_link_up(base) ? "up" : "down");
257253
}
258254

259255
void __init kirkwood_pcie_init(unsigned int portmask)

0 commit comments

Comments
 (0)