]> git.karo-electronics.de Git - karo-tx-uboot.git/commitdiff
x86: quark: Fix boot breakage
authorBin Meng <bmeng.cn@gmail.com>
Mon, 18 Jan 2016 15:29:32 +0000 (07:29 -0800)
committerTom Rini <trini@konsulko.com>
Tue, 19 Jan 2016 13:32:23 +0000 (08:32 -0500)
With driver model timer conversion, quark based board does not boot
any more as mdelay() is called during quark_pcie_early_init() which
is before driver model gets initialized. Fix this breakage.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
arch/x86/cpu/quark/quark.c

index 37ce3940b085e4685864f1dd52d6e13efb2145dc..72c681dceabaece9c81d1983199d31cdcf9fca1d 100644 (file)
@@ -252,17 +252,6 @@ int arch_cpu_init(void)
         */
        quark_setup_bars();
 
-       /*
-        * Initialize PCIe controller
-        *
-        * Quark SoC holds the PCIe controller in reset following a power on.
-        * U-Boot needs to release the PCIe controller from reset. The PCIe
-        * controller (D23:F0/F1) will not be visible in PCI configuration
-        * space and any access to its PCI configuration registers will cause
-        * system hang while it is held in reset.
-        */
-       quark_pcie_early_init();
-
        /* Initialize USB2 PHY */
        quark_usb_early_init();
 
@@ -277,6 +266,22 @@ int arch_cpu_init(void)
        return 0;
 }
 
+int arch_cpu_init_dm(void)
+{
+       /*
+        * Initialize PCIe controller
+        *
+        * Quark SoC holds the PCIe controller in reset following a power on.
+        * U-Boot needs to release the PCIe controller from reset. The PCIe
+        * controller (D23:F0/F1) will not be visible in PCI configuration
+        * space and any access to its PCI configuration registers will cause
+        * system hang while it is held in reset.
+        */
+       quark_pcie_early_init();
+
+       return 0;
+}
+
 int print_cpuinfo(void)
 {
        post_code(POST_CPU_INFO);