[U-Boot-Users] u-boot hangs in ./cpu/mpc8xx/cpu_init.c when changing br0

Jeff Mann MannJ at embeddedplanet.com
Tue Jun 20 23:04:36 CEST 2006

I am working on fixing a u-boot board port on a MPC866 processor. 

my problem is that U-boot hangs when initializing the CPU at line 180:
180         memctl->memc_or1 = CFG_OR1_PRELIM;
181         memctl->memc_br1 = CFG_BR1_PRELIM;

but in debugging (bdi2000, DDD), I find that the failure really occurs
at line 118:
 118         reg = memctl->memc_br0;
 119         reg &= BR_PS_MSK;       /* Clear everything except Port
Size bits */
 120         reg |= BR_V;            /* then add just the "Bank Valid"
bit     */
 121         memctl->memc_br0 = reg;

reg does not get the value of br0 at line 118, like it should. In fact,
DDD acts like the variable does not even exist. So at line 121, br0 is
being set to 0x00000001 instead of 0xXXXX0001. U-boot keeps running
after this, but only for a few more lines. It appears as though the
program is running out of cache before dying at 180 (because flash is
now located at memory location 0x00000000 instead of 0xff000000, it
cannot find the next program word). When I modify br0 to 0xff000001
after it fails, u-boot can continue on. 

I am compiling on ELDK 4.0.0.  

Any suggestions?

More information about the U-Boot mailing list