Merge branch 'old_next' into next
[pandora-kernel.git] / arch / arm / mach-kirkwood / ts41x-setup.c
index 9a44029..d5d0099 100644 (file)
@@ -154,6 +154,8 @@ static void __init qnap_ts41x_init(void)
 static int __init ts41x_pci_init(void)
 {
        if (machine_is_ts41x()) {
+               u32 dev, rev;
+
                /*
                 * Without this explicit reset, the PCIe SATA controller
                 * (Marvell 88sx7042/sata_mv) is known to stop working
@@ -161,7 +163,11 @@ static int __init ts41x_pci_init(void)
                 */
                orion_pcie_reset((void __iomem *)PCIE_VIRT_BASE);
 
-               kirkwood_pcie_init(KW_PCIE0);
+               kirkwood_pcie_id(&dev, &rev);
+               if (dev == MV88F6282_DEV_ID)
+                       kirkwood_pcie_init(KW_PCIE1 | KW_PCIE0);
+               else
+                       kirkwood_pcie_init(KW_PCIE0);
        }
 
    return 0;
@@ -173,6 +179,7 @@ MACHINE_START(TS41X, "QNAP TS-41x")
        .boot_params    = 0x00000100,
        .init_machine   = qnap_ts41x_init,
        .map_io         = kirkwood_map_io,
+       .init_early     = kirkwood_init_early,
        .init_irq       = kirkwood_init_irq,
        .timer          = &kirkwood_timer,
 MACHINE_END