diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-08-08 08:45:33 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-08-20 10:14:02 +0200 |
commit | 0c551f76e5432941d535bf8cf4ed5b6809e5f13e (patch) | |
tree | ef1d5662a8d93911492c021a320995417daf183f /cpukit/score/src/schedulerpriorityallocate.c | |
parent | score: PR2136: Fix _Thread_Change_priority() (diff) | |
download | rtems-0c551f76e5432941d535bf8cf4ed5b6809e5f13e.tar.bz2 |
score: Add _Scheduler_priority_Get_scheduler_info
Add and use _Scheduler_priority_Get_scheduler_info().
Diffstat (limited to 'cpukit/score/src/schedulerpriorityallocate.c')
-rw-r--r-- | cpukit/score/src/schedulerpriorityallocate.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/cpukit/score/src/schedulerpriorityallocate.c b/cpukit/score/src/schedulerpriorityallocate.c index 8c2291fa7a..ec0f21042d 100644 --- a/cpukit/score/src/schedulerpriorityallocate.c +++ b/cpukit/score/src/schedulerpriorityallocate.c @@ -18,21 +18,17 @@ #include "config.h" #endif -#include <rtems/system.h> -#include <rtems/config.h> -#include <rtems/score/scheduler.h> #include <rtems/score/schedulerpriority.h> #include <rtems/score/wkspace.h> -void* _Scheduler_priority_Allocate ( +void *_Scheduler_priority_Allocate ( Thread_Control *the_thread ) { - void *sched; + Scheduler_priority_Per_thread *sched_info_of_thread = + _Workspace_Allocate( sizeof( *sched_info_of_thread ) ); - sched = _Workspace_Allocate( sizeof(Scheduler_priority_Per_thread) ); + the_thread->scheduler_info = sched_info_of_thread; - the_thread->scheduler_info = (Scheduler_priority_Per_thread*) sched; - - return sched; + return sched_info_of_thread; } |