summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems/score/threaddispatch.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2016-05-17 15:57:48 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2016-05-20 07:49:41 +0200
commitd2bacb6c38c2bc0e47524b943200e16ad3c26bd8 (patch)
tree42df8963185fc3be111b39ba2160f31d8a17bf8a /cpukit/score/include/rtems/score/threaddispatch.h
parenttestsuites: Avoid Giant lock (diff)
downloadrtems-d2bacb6c38c2bc0e47524b943200e16ad3c26bd8.tar.bz2
score: _Thread_Dispatch_increment_disable_level()
Avoid _Thread_Dispatch_increment_disable_level() and _Thread_Dispatch_decrement_disable_level() and thus the Giant lock. This is a preparation to remove the Giant lock. Update #2555.
Diffstat (limited to 'cpukit/score/include/rtems/score/threaddispatch.h')
-rw-r--r--cpukit/score/include/rtems/score/threaddispatch.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/cpukit/score/include/rtems/score/threaddispatch.h b/cpukit/score/include/rtems/score/threaddispatch.h
index bf846e3497..b0dd64cf18 100644
--- a/cpukit/score/include/rtems/score/threaddispatch.h
+++ b/cpukit/score/include/rtems/score/threaddispatch.h
@@ -341,6 +341,18 @@ RTEMS_INLINE_ROUTINE void _Thread_Dispatch_enable( Per_CPU_Control *cpu_self )
}
/**
+ * @brief Unnests thread dispatching.
+ *
+ * This function does not release the Giant lock.
+ *
+ * @param[in] cpu_self The current processor.
+ */
+RTEMS_INLINE_ROUTINE void _Thread_Dispatch_unnest( Per_CPU_Control *cpu_self )
+{
+ --cpu_self->thread_dispatch_disable_level;
+}
+
+/**
* @brief Disables thread dispatching and acquires the Giant lock.
*/
#if defined ( __THREAD_DO_NOT_INLINE_DISABLE_DISPATCH__ )