]> git.sur5r.net Git - u-boot/blobdiff - board/freescale/ls1012afrdm/ls1012afrdm.c
fsl-layerscape: Consolidate registers space defination for CCI-400 bus
[u-boot] / board / freescale / ls1012afrdm / ls1012afrdm.c
index b03bdb82c67c903856277a9ae58c80c8dd6448f2..9afd1c469e42b7aa66de98586ab09629fab943bf 100644 (file)
@@ -9,6 +9,10 @@
 #include <asm/io.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/fsl_serdes.h>
+#ifdef CONFIG_FSL_LS_PPA
+#include <asm/arch/ppa.h>
+#endif
+#include <asm/arch/mmu.h>
 #include <asm/arch/soc.h>
 #include <hwconfig.h>
 #include <environment.h>
@@ -45,6 +49,10 @@ int dram_init(void)
        mmdc_init(&mparam);
 
        gd->ram_size = CONFIG_SYS_SDRAM_SIZE;
+#if !defined(CONFIG_SPL) || defined(CONFIG_SPL_BUILD)
+       /* This will break-before-make MMU for DDR */
+       update_early_mmu_table();
+#endif
 
        return 0;
 }
@@ -63,7 +71,9 @@ int board_early_init_f(void)
 
 int board_init(void)
 {
-       struct ccsr_cci400 *cci = (struct ccsr_cci400 *)CONFIG_SYS_CCI400_ADDR;
+       struct ccsr_cci400 *cci = (struct ccsr_cci400 *)(CONFIG_SYS_IMMR +
+                                       CONFIG_SYS_CCI400_OFFSET);
+
        /*
         * Set CCI-400 control override register to enable barrier
         * transaction
@@ -74,6 +84,9 @@ int board_init(void)
        gd->env_addr = (ulong)&default_environment[0];
 #endif
 
+#ifdef CONFIG_FSL_LS_PPA
+       ppa_init();
+#endif
        return 0;
 }