summaryrefslogtreecommitdiffstats
path: root/cpukit/score/src/schedulersmpstartidle.c
diff options
context:
space:
mode:
Diffstat (limited to 'cpukit/score/src/schedulersmpstartidle.c')
-rw-r--r--cpukit/score/src/schedulersmpstartidle.c22
1 files changed, 8 insertions, 14 deletions
diff --git a/cpukit/score/src/schedulersmpstartidle.c b/cpukit/score/src/schedulersmpstartidle.c
index d396a159fe..bdb1b47876 100644
--- a/cpukit/score/src/schedulersmpstartidle.c
+++ b/cpukit/score/src/schedulersmpstartidle.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2016 embedded brains GmbH.
+ * Copyright (c) 2013, 2017 embedded brains GmbH.
*
* The license and distribution terms for this file may be
* found in the file LICENSE in this distribution or at
@@ -18,18 +18,12 @@ void _Scheduler_SMP_Start_idle(
Per_CPU_Control *cpu
)
{
- Scheduler_Context *context;
- Scheduler_SMP_Context *self;
- Scheduler_SMP_Node *node;
+ Scheduler_Context *context = _Scheduler_Get_context( scheduler );
- context = _Scheduler_Get_context( scheduler );
- self = _Scheduler_SMP_Get_self( context );
- node = _Scheduler_SMP_Thread_get_node( idle );
-
- _Scheduler_Thread_change_state( idle, THREAD_SCHEDULER_SCHEDULED );
- node->state = SCHEDULER_SMP_NODE_SCHEDULED;
-
- _Thread_Set_CPU( idle, cpu );
- _Chain_Append_unprotected( &self->Scheduled, &node->Base.Node.Chain );
- _Scheduler_SMP_Release_idle_thread( &self->Base, idle );
+ _Scheduler_SMP_Do_start_idle(
+ context,
+ idle,
+ cpu,
+ _Scheduler_SMP_Do_nothing_register_idle
+ );
}