summaryrefslogtreecommitdiffstats
path: root/cpukit/score/src/threadstart.c
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2016-01-07 09:55:45 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2016-01-11 08:47:01 +0100
commitccd54344d904b657123e4e4ba795a32212382be2 (patch)
treed490d77b6173f586137036ed07ec5bd27d8ca65a /cpukit/score/src/threadstart.c
parentsmptests/README: Delete obsolete information (diff)
downloadrtems-ccd54344d904b657123e4e4ba795a32212382be2.tar.bz2
score: Introduce Thread_Entry_information
This avoids potential dead code in _Thread_Handler(). It gets rid of the dangerous function pointer casts. Update #2514.
Diffstat (limited to 'cpukit/score/src/threadstart.c')
-rw-r--r--cpukit/score/src/threadstart.c17
1 files changed, 4 insertions, 13 deletions
diff --git a/cpukit/score/src/threadstart.c b/cpukit/score/src/threadstart.c
index dda9495a35..97399ba524 100644
--- a/cpukit/score/src/threadstart.c
+++ b/cpukit/score/src/threadstart.c
@@ -25,22 +25,13 @@
#include <rtems/score/userextimpl.h>
bool _Thread_Start(
- Thread_Control *the_thread,
- Thread_Start_types the_prototype,
- void *entry_point,
- void *pointer_argument,
- Thread_Entry_numeric_type numeric_argument,
- Per_CPU_Control *cpu
+ Thread_Control *the_thread,
+ const Thread_Entry_information *entry,
+ Per_CPU_Control *cpu
)
{
if ( _States_Is_dormant( the_thread->current_state ) ) {
-
- the_thread->Start.entry_point = (Thread_Entry) entry_point;
-
- the_thread->Start.prototype = the_prototype;
- the_thread->Start.pointer_argument = pointer_argument;
- the_thread->Start.numeric_argument = numeric_argument;
-
+ the_thread->Start.Entry = *entry;
_Thread_Load_environment( the_thread );
if ( cpu == NULL ) {