summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems/score/mrspimpl.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2015-05-18 11:09:14 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2015-05-19 15:14:33 +0200
commitd5423295988918f45b64d50cf0b9501a56b9aa36 (patch)
treede09916f70f4f10b47cf080e7149c1cef2c47198 /cpukit/score/include/rtems/score/mrspimpl.h
parentscore: Replace _Thread_Delay_ended() (diff)
downloadrtems-d5423295988918f45b64d50cf0b9501a56b9aa36.tar.bz2
score: _Thread_Dispatch_disable_critical()
Thread dispatching is disabled in case interrupts are disabled. To get an accurate thread dispatch disabled time it is important to use the interrupt disabled instant in case a transition from an interrupt disabled section to a thread dispatch level section happens.
Diffstat (limited to 'cpukit/score/include/rtems/score/mrspimpl.h')
-rw-r--r--cpukit/score/include/rtems/score/mrspimpl.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/cpukit/score/include/rtems/score/mrspimpl.h b/cpukit/score/include/rtems/score/mrspimpl.h
index 82ecb07047..bc9ed4b511 100644
--- a/cpukit/score/include/rtems/score/mrspimpl.h
+++ b/cpukit/score/include/rtems/score/mrspimpl.h
@@ -102,7 +102,7 @@ RTEMS_INLINE_ROUTINE void _MRSP_Claim_ownership(
mrsp->initial_priority_of_owner = initial_priority;
_Scheduler_Thread_change_help_state( new_owner, SCHEDULER_HELP_ACTIVE_OWNER );
- cpu_self = _Thread_Dispatch_disable_critical();
+ cpu_self = _Thread_Dispatch_disable_critical( lock_context );
_ISR_lock_Release_and_ISR_enable( &mrsp->Lock, lock_context );
_Thread_Raise_priority( new_owner, ceiling_priority );
@@ -230,7 +230,7 @@ RTEMS_INLINE_ROUTINE MRSP_Status _MRSP_Wait_for_ownership(
_MRSP_Giant_release( &giant_lock_context );
- cpu_self = _Thread_Dispatch_disable_critical();
+ cpu_self = _Thread_Dispatch_disable_critical( lock_context );
_ISR_lock_Release_and_ISR_enable( &mrsp->Lock, lock_context );
_Thread_Raise_priority( executing, ceiling_priority );
@@ -388,7 +388,7 @@ RTEMS_INLINE_ROUTINE MRSP_Status _MRSP_Release(
_MRSP_Giant_release( &giant_lock_context );
- cpu_self = _Thread_Dispatch_disable_critical();
+ cpu_self = _Thread_Dispatch_disable_critical( lock_context );
_ISR_lock_Release_and_ISR_enable( &mrsp->Lock, lock_context );
_MRSP_Restore_priority( executing, initial_priority );