diff packages/hal/common/current/include/hal_stub.h @ 3236:f415c0531921

NUMREGS replaced by HAL_STUB_REGISTERS_SIZE in thread-packets.c
author vae
date Wed, 25 Apr 2012 19:47:39 +0000
parents 74dbf4c3f2e1
children
line wrap: on
line diff
--- a/packages/hal/common/current/include/hal_stub.h
+++ b/packages/hal/common/current/include/hal_stub.h
@@ -82,6 +82,15 @@ typedef cyg_int32  int32;
 #endif
 #include <cyg/hal/generic-stub.h>
 
+// Some architectures use registers of different sizes, so NUMREGS
+// alone is not sufficient to size the register save area. For those
+// architectures, HAL_STUB_REGISTERS_SIZE is defined as the number
+// of target_register_t sized elements in the register save area.
+#ifndef HAL_STUB_REGISTERS_SIZE
+#define HAL_STUB_REGISTERS_SIZE NUMREGS
+#endif
+
+
 #ifdef __cplusplus
 extern "C" {
 #endif