Doing trap_init immediately once we're running from RAM
means we're no longer dependent on the physical location of
the flash on non-BookE platforms. Before trap_init, those
platforms switch to real mode and go to 0xfff00100 on exception.
After the switch, they go to 0x00000100 This makes it easier to
move the flash location.
Signed-off-by: Becky Bruce <becky.bruce@freescale.com>
WATCHDOG_RESET ();
+ /*
+ * Setup trap handlers
+ */
+ trap_init (dest_addr);
+
#if defined(CONFIG_BOARD_EARLY_INIT_R)
board_early_init_r ();
#endif
asm ("sync ; isync");
- /*
- * Setup trap handlers
- */
- trap_init (dest_addr);
-
#if !defined(CONFIG_SYS_NO_FLASH)
puts ("FLASH: ");