From fe7acdcf8b56a38212a7212493b4e07a70914d0f Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Wed, 3 Jan 2001 16:36:23 +0000 Subject: 2001-01-03 Joel Sherrill * rtems/score/cpu.h: Added _CPU_Initialize_vectors(). * cpu_asm.S: Modify to properly dereference _ISR_Vector_table now that it is dynamically allocated. --- c/src/exec/score/cpu/sparc/ChangeLog | 6 ++++++ c/src/exec/score/cpu/sparc/cpu_asm.S | 2 +- c/src/exec/score/cpu/sparc/rtems/score/cpu.h | 10 +++++++++- 3 files changed, 16 insertions(+), 2 deletions(-) (limited to 'c/src/exec/score/cpu/sparc') diff --git a/c/src/exec/score/cpu/sparc/ChangeLog b/c/src/exec/score/cpu/sparc/ChangeLog index 1cc5e1d422..ad958a08a9 100644 --- a/c/src/exec/score/cpu/sparc/ChangeLog +++ b/c/src/exec/score/cpu/sparc/ChangeLog @@ -1,3 +1,9 @@ +2001-01-03 Joel Sherrill + + * rtems/score/cpu.h: Added _CPU_Initialize_vectors(). + * cpu_asm.S: Modify to properly dereference _ISR_Vector_table + now that it is dynamically allocated. + 2000-12-06 Joel Sherrill * cpu.c: Added include of to eliminate warning. diff --git a/c/src/exec/score/cpu/sparc/cpu_asm.S b/c/src/exec/score/cpu/sparc/cpu_asm.S index e7c2cf68db..9e186a0bb9 100644 --- a/c/src/exec/score/cpu/sparc/cpu_asm.S +++ b/c/src/exec/score/cpu/sparc/cpu_asm.S @@ -585,7 +585,7 @@ dont_fix_pil2: */ sethi %hi(SYM(_ISR_Vector_table)), %g4 - or %g4, %lo(SYM(_ISR_Vector_table)), %g4 + ld [%g4+%lo(SYM(_ISR_Vector_table))], %g4 and %l3, 0xFF, %g5 ! remove synchronous trap indicator sll %g5, 2, %g5 ! g5 = offset into table ld [%g4 + %g5], %g4 ! g4 = _ISR_Vector_table[ vector ] diff --git a/c/src/exec/score/cpu/sparc/rtems/score/cpu.h b/c/src/exec/score/cpu/sparc/rtems/score/cpu.h index f7fbf121f9..7f6383a0e1 100644 --- a/c/src/exec/score/cpu/sparc/rtems/score/cpu.h +++ b/c/src/exec/score/cpu/sparc/rtems/score/cpu.h @@ -718,7 +718,15 @@ SCORE_EXTERN unsigned8 _CPU_Trap_Table_area[ 8192 ] extern unsigned int sparc_disable_interrupts(); extern void sparc_enable_interrupts(); -/* ISR handler macros */ +/* + * ISR handler macros + */ + +/* + * Support routine to initialize the RTEMS vector table after it is allocated. + */ + +#define _CPU_Initialize_vectors() /* * Disable all interrupts for a critical section. The previous -- cgit v1.2.3