forked from Imagelibrary/rtems
2008-08-18 Sebastian Huber <sebastian.huber@embedded-brains.de>
* Makefile.am, startup/bspstart.c, startup/cpuinit.c: For the MPC8313ERDB -- The BAT entry for the eLBC was missing and add hard reset sequence in bsp_cleanup().
This commit is contained in:
@@ -1,3 +1,9 @@
|
||||
2008-08-18 Sebastian Huber <sebastian.huber@embedded-brains.de>
|
||||
|
||||
* Makefile.am, startup/bspstart.c, startup/cpuinit.c: For the
|
||||
MPC8313ERDB -- The BAT entry for the eLBC was missing and add
|
||||
hard reset sequence in bsp_cleanup().
|
||||
|
||||
2008-08-15 Joel Sherrill <joel.sherrill@OARcorp.com>
|
||||
|
||||
* README.mpc8313erdb: Some first cut notes on running with U-Boot.
|
||||
|
||||
@@ -43,8 +43,7 @@ dist_project_lib_DATA += startup/linkcmds \
|
||||
|
||||
mpc83xx_regs_SOURCES = startup/mpc83xx_regs.c
|
||||
|
||||
startup_SOURCES = ../../shared/bspclean.c \
|
||||
../../shared/bsplibc.c \
|
||||
startup_SOURCES = ../../shared/bsplibc.c \
|
||||
../../shared/bsppost.c \
|
||||
../../shared/bootcard.c \
|
||||
../../shared/bsppredriverhook.c \
|
||||
|
||||
@@ -189,3 +189,28 @@ Thread _Thread_Idle_body( uint32_t ignored)
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void bsp_cleanup( void)
|
||||
{
|
||||
#ifdef MPC8313ERDB
|
||||
|
||||
/* Set Reset Protection Register (RPR) to "RSTE" */
|
||||
mpc83xx.res.rpr = 0x52535445;
|
||||
|
||||
/*
|
||||
* Wait for Control Register Enabled in the
|
||||
* Reset Control Enable Register (RCER).
|
||||
*/
|
||||
while (mpc83xx.res.rcer != 0x00000001) {
|
||||
/* Wait */
|
||||
}
|
||||
|
||||
/* Set Software Hard Reset in the Reset Control Register (RCR) */
|
||||
mpc83xx.res.rcr = 0x00000002;
|
||||
|
||||
#else /* MPC8313ERDB */
|
||||
|
||||
/* Do nothing */
|
||||
|
||||
#endif /* MPC8313ERDB */
|
||||
}
|
||||
|
||||
@@ -220,6 +220,12 @@ void cpu_init(void)
|
||||
|
||||
SET_DBAT(2,dbat.batu,dbat.batl);
|
||||
|
||||
#ifdef MPC8313ERDB
|
||||
/* Enhanced Local Bus Controller (eLBC) */
|
||||
calc_dbat_regvals( &dbat, 0xfa000000, 128 * 1024, 0, 1, 0, 1, BPP_RW);
|
||||
SET_DBAT( 3, dbat.batu, dbat.batl);
|
||||
#endif /* MPC8313ERDB */
|
||||
|
||||
/*
|
||||
* enable data/instruction MMU in MSR
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user