summaryrefslogtreecommitdiffstats
path: root/cpukit/rtems/src/taskinitusers.c
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2015-12-22 09:40:48 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2016-01-08 09:03:33 +0100
commit44e987192e47910b8551a8f9409e9cd6133695d1 (patch)
tree358f37aee1e92ae5a67ee17742b91cf334167f50 /cpukit/rtems/src/taskinitusers.c
parentscore: Add fatal errors for NULL entry init tasks (diff)
downloadrtems-44e987192e47910b8551a8f9409e9cd6133695d1.tar.bz2
score: Avoid dead code in global construction
Update #2514.
Diffstat (limited to 'cpukit/rtems/src/taskinitusers.c')
-rw-r--r--cpukit/rtems/src/taskinitusers.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/cpukit/rtems/src/taskinitusers.c b/cpukit/rtems/src/taskinitusers.c
index 46d0af3f70..f5c2f82995 100644
--- a/cpukit/rtems/src/taskinitusers.c
+++ b/cpukit/rtems/src/taskinitusers.c
@@ -31,6 +31,15 @@
#include <rtems/score/wkspace.h>
#include <rtems/score/apiext.h>
+static void _RTEMS_Global_construction( rtems_task_argument arg )
+{
+ Thread_Entry entry_point = (Thread_Entry)
+ Configuration_RTEMS_API.User_initialization_tasks_table[ 0 ].entry_point;
+
+ (void) arg;
+ _Thread_Global_construction( entry_point );
+}
+
/*
* _RTEMS_tasks_Initialize_user_tasks_body
*
@@ -92,7 +101,7 @@ void _RTEMS_tasks_Initialize_user_tasks_body( void )
if ( register_global_construction ) {
register_global_construction = false;
- entry_point = (rtems_task_entry) _Thread_Global_construction;
+ entry_point = _RTEMS_Global_construction;
}
return_value = rtems_task_start(