From e1598a616db1e9dadfd74abeb20b1f1ec5daaa7f Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Fri, 4 Apr 2014 10:56:36 +0200 Subject: score: Static scheduler configuration Do not allocate the scheduler control structures from the workspace. This is a preparation step for configuration of clustered/partitioned schedulers on SMP. --- .../include/rtems/score/schedulersimpleimpl.h | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'cpukit/score/include/rtems/score/schedulersimpleimpl.h') diff --git a/cpukit/score/include/rtems/score/schedulersimpleimpl.h b/cpukit/score/include/rtems/score/schedulersimpleimpl.h index 8ad142f0b4..f436134fc4 100644 --- a/cpukit/score/include/rtems/score/schedulersimpleimpl.h +++ b/cpukit/score/include/rtems/score/schedulersimpleimpl.h @@ -32,10 +32,10 @@ extern "C" { */ /**@{**/ -RTEMS_INLINE_ROUTINE Scheduler_simple_Control * - _Scheduler_simple_Self_from_base( Scheduler_Control *scheduler_base ) +RTEMS_INLINE_ROUTINE Scheduler_simple_Context * + _Scheduler_simple_Get_context( const Scheduler_Control *scheduler ) { - return (Scheduler_simple_Control *) scheduler_base->information; + return (Scheduler_simple_Context *) scheduler->context; } /** @@ -45,8 +45,8 @@ RTEMS_INLINE_ROUTINE Scheduler_simple_Control * * @param[in] the_thread is the thread to be blocked */ RTEMS_INLINE_ROUTINE void _Scheduler_simple_Ready_queue_requeue( - Scheduler_Control *scheduler, - Thread_Control *the_thread + const Scheduler_Control *scheduler, + Thread_Control *the_thread ) { /* extract */ @@ -103,14 +103,14 @@ RTEMS_INLINE_ROUTINE void _Scheduler_simple_Insert_priority_fifo( } RTEMS_INLINE_ROUTINE void _Scheduler_simple_Schedule_body( - Scheduler_Control *scheduler_base, - Thread_Control *the_thread, - bool force_dispatch + const Scheduler_Control *scheduler, + Thread_Control *the_thread, + bool force_dispatch ) { - Scheduler_simple_Control *scheduler = - _Scheduler_simple_Self_from_base( scheduler_base ); - Thread_Control *heir = (Thread_Control *) _Chain_First( &scheduler->Ready ); + Scheduler_simple_Context *context = + _Scheduler_simple_Get_context( scheduler ); + Thread_Control *heir = (Thread_Control *) _Chain_First( &context->Ready ); ( void ) the_thread; -- cgit v1.2.3