diff options
author | Thomas Doerfler <Thomas.Doerfler@embedded-brains.de> | 2008-07-14 08:46:06 +0000 |
---|---|---|
committer | Thomas Doerfler <Thomas.Doerfler@embedded-brains.de> | 2008-07-14 08:46:06 +0000 |
commit | 3c6fe2e7f95f6bff53123df9377b114cadeac874 (patch) | |
tree | fef9ad7a4cd45497a1a84c1b7f9cd103eb258c43 /c/src/lib/libcpu/powerpc/new-exceptions | |
parent | corrections in display driver (diff) | |
download | rtems-3c6fe2e7f95f6bff53123df9377b114cadeac874.tar.bz2 |
added haleakala BSP contributed by Michael Hamel
Diffstat (limited to '')
-rw-r--r-- | c/src/lib/libcpu/powerpc/new-exceptions/bspsupport/irq.c | 7 | ||||
-rw-r--r-- | c/src/lib/libcpu/powerpc/new-exceptions/raw_exception.c | 5 |
2 files changed, 10 insertions, 2 deletions
diff --git a/c/src/lib/libcpu/powerpc/new-exceptions/bspsupport/irq.c b/c/src/lib/libcpu/powerpc/new-exceptions/bspsupport/irq.c index 1b9dcafefe..6b3d218e60 100644 --- a/c/src/lib/libcpu/powerpc/new-exceptions/bspsupport/irq.c +++ b/c/src/lib/libcpu/powerpc/new-exceptions/bspsupport/irq.c @@ -38,6 +38,7 @@ static rtems_irq_connect_data* rtems_hdl_tbl; SPR_RW(BOOKE_TSR) +SPR_RW(PPC405_TSR) /* legacy mode for bookE DEC exception; * to avoid the double layer of function calls @@ -52,8 +53,12 @@ int C_dispatch_dec_handler_bookE (BSP_Exception_frame *frame, unsigned int excNu /* clear interrupt; we must do this * before C_dispatch_irq_handler() * re-enables MSR_EE. + * Note that PPC405 uses a different SPR# for TSR */ - _write_BOOKE_TSR( BOOKE_TSR_DIS ); + if ( ppc_cpu_is_bookE()==PPC_BOOKE_405) + _write_PPC405_TSR( BOOKE_TSR_DIS ); + else + _write_BOOKE_TSR( BOOKE_TSR_DIS ); return C_dispatch_irq_handler(frame, ASM_DEC_VECTOR); } diff --git a/c/src/lib/libcpu/powerpc/new-exceptions/raw_exception.c b/c/src/lib/libcpu/powerpc/new-exceptions/raw_exception.c index e330d80921..06ed62423d 100644 --- a/c/src/lib/libcpu/powerpc/new-exceptions/raw_exception.c +++ b/c/src/lib/libcpu/powerpc/new-exceptions/raw_exception.c @@ -162,7 +162,8 @@ static const cat_ini_t mpc_5xx_vector_categories[LAST_VALID_EXC + 1] = { static const cat_ini_t ppc_405_vector_categories[LAST_VALID_EXC + 1] = { [ ASM_EXT_VECTOR ] = PPC_EXC_CLASSIC | PPC_EXC_ASYNC, - [ ASM_BOOKE_DEC_VECTOR ] = PPC_EXC_CLASSIC | PPC_EXC_ASYNC, + [ ASM_BOOKE_DEC_VECTOR ] = PPC_EXC_CLASSIC | PPC_EXC_ASYNC, /* PIT */ + [ ASM_BOOKE_FIT_VECTOR ] = PPC_EXC_CLASSIC | PPC_EXC_ASYNC, /* FIT */ [ ASM_PROT_VECTOR ] = PPC_EXC_CLASSIC, [ ASM_ISI_VECTOR ] = PPC_EXC_CLASSIC, @@ -371,6 +372,8 @@ ppc_raw_exception_category rval = PPC_EXC_INVALID; rval = mpc_860_vector_categories[vector]; break; case PPC_405: + case PPC_405GP: + case PPC_405EX: rval = ppc_405_vector_categories[vector]; break; default: |