diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2008-08-19 19:10:46 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2008-08-19 19:10:46 +0000 |
commit | af063f6c0113ee7502acad115223791c52a986af (patch) | |
tree | 42474891f11b2fff6bea3f8dcd842882537dc3b2 /cpukit/score/cpu/i386/rtems/score/cpu.h | |
parent | 2008-08-19 Joel Sherrill <joel.sherrill@OARcorp.com> (diff) | |
download | rtems-af063f6c0113ee7502acad115223791c52a986af.tar.bz2 |
2008-08-19 Joel Sherrill <joel.sherrill@OARcorp.com>
* cpu.c: Fix prototypes.
* rtems/score/cpu.h: Use memcpy() initialize FP structure and avoid
many casts and potential warnings.
Diffstat (limited to '')
-rw-r--r-- | cpukit/score/cpu/i386/rtems/score/cpu.h | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/cpukit/score/cpu/i386/rtems/score/cpu.h b/cpukit/score/cpu/i386/rtems/score/cpu.h index c1da7ec609..d95056064f 100644 --- a/cpukit/score/cpu/i386/rtems/score/cpu.h +++ b/cpukit/score/cpu/i386/rtems/score/cpu.h @@ -19,6 +19,8 @@ #ifndef _RTEMS_SCORE_CPU_H #define _RTEMS_SCORE_CPU_H +#include <string.h> /* for memcpy */ + #ifdef __cplusplus extern "C" { #endif @@ -313,12 +315,7 @@ uint32_t _CPU_ISR_Get_level( void ); #define _CPU_Context_Initialize_fp( _fp_area ) \ { \ - uint32_t *_source = (uint32_t *) &_CPU_Null_fp_context; \ - uint32_t *_destination = *(_fp_area); \ - uint32_t _index; \ - \ - for ( _index=0 ; _index < CPU_CONTEXT_FP_SIZE/4 ; _index++ ) \ - *_destination++ = *_source++; \ + memcpy( *_fp_area, &_CPU_Null_fp_context, CPU_CONTEXT_FP_SIZE ); \ } /* end of Context handler macros */ |