diff options
author | Becky Bruce <becky.bruce@freescale.com> | 2008-11-01 01:14:39 +0300 |
---|---|---|
committer | Jon Loeliger <jdl@freescale.com> | 2008-11-10 19:10:06 +0300 |
commit | d025aa4b20a0618a2bada0132a9a0a4afb717f1a (patch) | |
tree | 0fb3e41846fecc628673a848ce638eef7eb70fa1 /lib_ppc/board.c | |
parent | d52082b12c6e545705a19433a2f4142526536189 (diff) | |
download | u-boot-d025aa4b20a0618a2bada0132a9a0a4afb717f1a.tar.xz |
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: Becky Bruce <becky.bruce@freescale.com>
Diffstat (limited to 'lib_ppc/board.c')
-rw-r--r-- | lib_ppc/board.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib_ppc/board.c b/lib_ppc/board.c index ce07c4ed86..289a32a644 100644 --- a/lib_ppc/board.c +++ b/lib_ppc/board.c @@ -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: "); |