diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2005-09-12 13:32:58 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2005-09-12 13:32:58 +0000 |
commit | 848e900c5c47fc0dbc24d2e093e3a6a3fa76202c (patch) | |
tree | b2b04382402f61e38f80be1fa156de6f010c79de /c/src/lib/libbsp/powerpc/mbx8xx/startup/start.S | |
parent | 2005-09-12 Thomas Doerfler <Thomas.Doerfler@imd-systems.de> (diff) | |
download | rtems-848e900c5c47fc0dbc24d2e093e3a6a3fa76202c.tar.bz2 |
2005-09-12 Thomas Doerfler <Thomas.Doerfler@imd-systems.de>
PR 822/bsps
* console/console.c, startup/bspstart.c, startup/imbx8xx.c,
startup/mmutlbtab.c, startup/start.S, vectors/vectors_init.c:
Currently the MBX8xx BSP does not boot, because some logical errors
are in the startup code. Additionally, the mpc8xx shared clock driver
does not support the clocking scheme of some of the board variants,
which are clocked from a 32768Hz (!) external crystal.
Diffstat (limited to 'c/src/lib/libbsp/powerpc/mbx8xx/startup/start.S')
-rw-r--r-- | c/src/lib/libbsp/powerpc/mbx8xx/startup/start.S | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/powerpc/mbx8xx/startup/start.S b/c/src/lib/libbsp/powerpc/mbx8xx/startup/start.S index b254746247..bd1bbdbd7a 100644 --- a/c/src/lib/libbsp/powerpc/mbx8xx/startup/start.S +++ b/c/src/lib/libbsp/powerpc/mbx8xx/startup/start.S @@ -239,6 +239,46 @@ spin: cmpwi r3, 0x1 beq .spin /* + * test function: blink orange led once + */ +#define LEDBLINK_DELAY (5*1000*1000) +#define LEDPORT 0xFA100001 +#define LEDMASK 0xf0 +#define LEDON 0x00 +#define LEDOFF 0x08 + + PUBLIC_VAR(ledblink) +SYM(ledblink): + lis r3,LEDBLINK_DELAY>>16 +ledblink1: + subi r3,r3,1 + cmpi 0,1,r3,0 + bne ledblink1 + /* + * turn orange led off + */ + lis r3,LEDPORT@ha + lbz r0,LEDPORT@l(r3) + andi. r0,r0,LEDMASK + ori r0,r0,LEDOFF + stb r0,LEDPORT@l(r3) + + lis r3,LEDBLINK_DELAY>>16 +ledblink2: + subi r3,r3,1 + cmpi 0,1,r3,0 + bne ledblink2 + /* + * turn orange led on + */ + lis r3,LEDPORT@ha + lbz r0,LEDPORT@l(r3) + andi. r0,r0,LEDMASK + ori r0,r0,LEDON + stb r0,LEDPORT@l(r3) + + blr +/* * #define LOADED_BY_EPPCBUG */ #define LOADED_BY_EPPCBUG |