summaryrefslogtreecommitdiffstats
path: root/cpukit/posix/src/sched_yield.c
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2014-04-03 15:03:35 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2014-04-04 11:01:18 +0200
commit24934e36e2513f972510d7c746103be1f766dc6a (patch)
tree66e3c8840cec6c1262f142e25ec545926140dbf9 /cpukit/posix/src/sched_yield.c
parentscore: Add and use Scheduler_simple_Control (diff)
downloadrtems-24934e36e2513f972510d7c746103be1f766dc6a.tar.bz2
score: Add scheduler control to scheduler ops
Scheduler operations must be free of a global scheduler context to enable partitioned/clustered scheduling.
Diffstat (limited to '')
-rw-r--r--cpukit/posix/src/sched_yield.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/cpukit/posix/src/sched_yield.c b/cpukit/posix/src/sched_yield.c
index 906d102a37..5293b199dc 100644
--- a/cpukit/posix/src/sched_yield.c
+++ b/cpukit/posix/src/sched_yield.c
@@ -26,8 +26,11 @@
int sched_yield( void )
{
+ Thread_Control *executing;
+
_Thread_Disable_dispatch();
- _Scheduler_Yield( _Thread_Executing );
+ executing = _Thread_Executing;
+ _Scheduler_Yield( _Scheduler_Get( executing ), executing );
_Thread_Enable_dispatch();
return 0;
}