[rtems commit] powerpc: Fix PPC_CONTEXT_VOLATILE_SIZE
Sebastian Huber
sebh at rtems.org
Tue Jun 20 11:05:32 UTC 2017
Module: rtems
Branch: master
Commit: d30c2cc2881108f1622f29547f986e3f5c15f436
Changeset: http://git.rtems.org/rtems/commit/?id=d30c2cc2881108f1622f29547f986e3f5c15f436
Author: Sebastian Huber <sebastian.huber at embedded-brains.de>
Date: Tue Jun 20 13:01:02 2017 +0200
powerpc: Fix PPC_CONTEXT_VOLATILE_SIZE
Account for legacy AltiVec context.
---
cpukit/score/cpu/powerpc/rtems/score/cpu.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/cpukit/score/cpu/powerpc/rtems/score/cpu.h b/cpukit/score/cpu/powerpc/rtems/score/cpu.h
index 53b4bd2..28f9a25 100644
--- a/cpukit/score/cpu/powerpc/rtems/score/cpu.h
+++ b/cpukit/score/cpu/powerpc/rtems/score/cpu.h
@@ -398,6 +398,10 @@ static inline ppc_context *ppc_get_context( const Context_Control *context )
#define PPC_CONTEXT_VOLATILE_SIZE PPC_CONTEXT_OFFSET_F( 32 )
#elif defined(PPC_MULTILIB_ALTIVEC)
#define PPC_CONTEXT_VOLATILE_SIZE (PPC_CONTEXT_OFFSET_VRSAVE + 4)
+#elif defined(__ALTIVEC__)
+ #define PPC_CONTEXT_VOLATILE_SIZE \
+ (PPC_CONTEXT_GPR_OFFSET( 32 ) + 8 \
+ + 16 * 12 + 32 + PPC_DEFAULT_CACHE_LINE_SIZE)
#else
#define PPC_CONTEXT_VOLATILE_SIZE (PPC_CONTEXT_GPR_OFFSET( 32 ) + 8)
#endif
More information about the vc
mailing list