summaryrefslogtreecommitdiffstats
path: root/cpukit/score/inline/rtems/score/userext.inl
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>1998-04-15 00:02:10 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>1998-04-15 00:02:10 +0000
commit0451b44f3600f2e05859b931324b823b62a8251d (patch)
tree5a518a8684ff8a03493306def19baa477aa2846e /cpukit/score/inline/rtems/score/userext.inl
parent77809780587eb85df6d6aa331fa8b1ccb751cb8d (diff)
downloadrtems-0451b44f3600f2e05859b931324b823b62a8251d.tar.bz2
Per suggestion from Eric Norum, went from one initial extension set
to multiple. This lets the stack check extension be installed at system initialization time and avoids the BSP having to even know about its existence.
Diffstat (limited to 'cpukit/score/inline/rtems/score/userext.inl')
-rw-r--r--cpukit/score/inline/rtems/score/userext.inl15
1 files changed, 13 insertions, 2 deletions
diff --git a/cpukit/score/inline/rtems/score/userext.inl b/cpukit/score/inline/rtems/score/userext.inl
index 3ddb8459b8..29f7975aaa 100644
--- a/cpukit/score/inline/rtems/score/userext.inl
+++ b/cpukit/score/inline/rtems/score/userext.inl
@@ -17,6 +17,8 @@
#ifndef __USER_EXTENSIONS_inl
#define __USER_EXTENSIONS_inl
+#include <rtems/score/wkspace.h>
+
/*PAGE
*
* _User_extensions_Handler_initialization
@@ -27,14 +29,23 @@
*/
RTEMS_INLINE_ROUTINE void _User_extensions_Handler_initialization (
+ unsigned32 number_of_extensions,
User_extensions_Table *initial_extensions
)
{
+ User_extensions_Control *extension;
+ unsigned32 i;
+
_Chain_Initialize_empty( &_User_extensions_List );
if ( initial_extensions ) {
- _User_extensions_Initial.Callouts = *initial_extensions;
- _Chain_Append( &_User_extensions_List, &_User_extensions_Initial.Node );
+ for (i=0 ; i<number_of_extensions ; i++ ) {
+ extension =
+ _Workspace_Allocate_or_fatal_error( sizeof(User_extensions_Control) );
+
+ extension->Callouts = initial_extensions[i];
+ _Chain_Append( &_User_extensions_List, &extension->Node );
+ }
}
}