From 59e6e76190383d396582263800e915d54fb0206f Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Wed, 3 Feb 2016 11:36:23 +0100 Subject: sh: Avoid SCORE_EXTERN Update #2559. --- cpukit/score/cpu/sh/cpu.c | 6 ++++++ cpukit/score/cpu/sh/rtems/score/cpu.h | 6 +++--- 2 files changed, 9 insertions(+), 3 deletions(-) (limited to 'cpukit/score/cpu/sh') diff --git a/cpukit/score/cpu/sh/cpu.c b/cpukit/score/cpu/sh/cpu.c index 2b41e78df1..d6e2d176f5 100644 --- a/cpukit/score/cpu/sh/cpu.c +++ b/cpukit/score/cpu/sh/cpu.c @@ -43,6 +43,10 @@ proc_ptr vectab[256] ; extern proc_ptr _Hardware_isr_Table[]; +#if SH_HAS_FPU +Context_Control_fp _CPU_Null_fp_context; +#endif + /* _CPU_Initialize * * This routine performs processor dependent initialization. @@ -62,6 +66,7 @@ void _CPU_Initialize(void) */ /* FP context initialization support goes here */ +#if SH_HAS_FPU /* FIXME: When not to use SH4_FPSCR_PR ? */ #ifdef __SH4__ _CPU_Null_fp_context.fpscr = SH4_FPSCR_DN | SH4_FPSCR_RM | SH4_FPSCR_PR; @@ -69,6 +74,7 @@ void _CPU_Initialize(void) #ifdef __SH3E__ /* FIXME: Wild guess :) */ _CPU_Null_fp_context.fpscr = SH4_FPSCR_DN | SH4_FPSCR_RM; +#endif #endif /* enable interrupts */ diff --git a/cpukit/score/cpu/sh/rtems/score/cpu.h b/cpukit/score/cpu/sh/rtems/score/cpu.h index 43d1915847..2bddba7a76 100644 --- a/cpukit/score/cpu/sh/rtems/score/cpu.h +++ b/cpukit/score/cpu/sh/rtems/score/cpu.h @@ -371,7 +371,7 @@ typedef struct { */ #if SH_HAS_FPU -SCORE_EXTERN Context_Control_fp _CPU_Null_fp_context; +extern Context_Control_fp _CPU_Null_fp_context; #endif /* @@ -379,7 +379,7 @@ SCORE_EXTERN Context_Control_fp _CPU_Null_fp_context; */ /* XXX: if needed, put more variables here */ -SCORE_EXTERN void CPU_delay( uint32_t microseconds ); +void CPU_delay( uint32_t microseconds ); /* * The size of the floating point context area. On some CPUs this @@ -558,7 +558,7 @@ uint32_t _CPU_ISR_Get_level( void ); /* * FIXME: defined as a function for debugging - should be a macro */ -SCORE_EXTERN void _CPU_Context_Initialize( +void _CPU_Context_Initialize( Context_Control *_the_context, void *_stack_base, uint32_t _size, -- cgit v1.2.3