Skip to content
Snippets Groups Projects
Commit d025aa4b authored by Becky Bruce's avatar Becky Bruce Committed by Jon Loeliger
Browse files

lib_ppc: Move trap_init to occur earlier


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: default avatarBecky Bruce <becky.bruce@freescale.com>
parent d52082b1
No related branches found
No related tags found
No related merge requests found
......@@ -689,6 +689,11 @@ void board_init_r (gd_t *id, ulong dest_addr)
WATCHDOG_RESET ();
/*
* Setup trap handlers
*/
trap_init (dest_addr);
#if defined(CONFIG_BOARD_EARLY_INIT_R)
board_early_init_r ();
#endif
......@@ -765,11 +770,6 @@ void board_init_r (gd_t *id, ulong dest_addr)
asm ("sync ; isync");
/*
* Setup trap handlers
*/
trap_init (dest_addr);
#if !defined(CONFIG_SYS_NO_FLASH)
puts ("FLASH: ");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment