summaryrefslogtreecommitdiff
path: root/cpu/mpc8220/cpu_init.c
diff options
context:
space:
mode:
Diffstat (limited to 'cpu/mpc8220/cpu_init.c')
-rw-r--r--cpu/mpc8220/cpu_init.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/cpu/mpc8220/cpu_init.c b/cpu/mpc8220/cpu_init.c
index 09b23ee..a1e2f65 100644
--- a/cpu/mpc8220/cpu_init.c
+++ b/cpu/mpc8220/cpu_init.c
@@ -55,7 +55,11 @@ void cpu_init_f (void)
*/
#if defined (CFG_CS0_BASE)
flexbus->csar0 = CFG_CS0_BASE;
+
+/* Sorcery-C can hang-up after CTRL reg initialization */
+#if defined (CFG_CS0_CTRL)
flexbus->cscr0 = CFG_CS0_CTRL;
+#endif
flexbus->csmr0 = ((CFG_CS0_MASK - 1) & 0xffff0000) | 1;
__asm__ volatile ("sync");
#endif
@@ -97,15 +101,15 @@ void cpu_init_f (void)
/* This section of the code cannot place in cpu_init_r(),
it will cause the system to hang */
/* enable timebase */
- xlbarb->config = 0x00002000;
-
xlbarb->addrTenTimeOut = 0x1000;
xlbarb->dataTenTimeOut = 0x1000;
xlbarb->busActTimeOut = 0x2000;
+ xlbarb->config = 0x00002000;
+
/* Master Priority Enable */
- xlbarb->mastPriEn = 0x1f;
xlbarb->mastPriority = 0;
+ xlbarb->mastPriEn = 0x1f;
}
/*