diff options
Diffstat (limited to 'cpukit/score/include')
-rw-r--r-- | cpukit/score/include/rtems/score/coremutex.h | 2 | ||||
-rw-r--r-- | cpukit/score/include/rtems/score/thread.h | 12 |
2 files changed, 13 insertions, 1 deletions
diff --git a/cpukit/score/include/rtems/score/coremutex.h b/cpukit/score/include/rtems/score/coremutex.h index 084532f36d..e7174e3164 100644 --- a/cpukit/score/include/rtems/score/coremutex.h +++ b/cpukit/score/include/rtems/score/coremutex.h @@ -368,7 +368,7 @@ void _CORE_mutex_Seize_interrupt_blocking( #define _CORE_mutex_Seize_body( \ _the_mutex, _id, _wait, _timeout, _level ) \ do { \ - if ( _Thread_Dispatch_disable_level \ + if ( _Thread_Dispatch_in_critical_section() \ && (_wait) \ && (_System_state_Get() >= SYSTEM_STATE_BEGIN_MULTITASKING ) \ ) { \ diff --git a/cpukit/score/include/rtems/score/thread.h b/cpukit/score/include/rtems/score/thread.h index 8754ee931d..237fbde59c 100644 --- a/cpukit/score/include/rtems/score/thread.h +++ b/cpukit/score/include/rtems/score/thread.h @@ -46,6 +46,18 @@ #define RTEMS_SCORE_THREAD_ENABLE_USER_PROVIDED_STACK_VIA_API #endif +#if defined(RTEMS_SMP) || \ + defined(RTEMS_HEAVY_STACK_DEBUG) || \ + defined(RTEMS_HEAVY_MALLOC_DEBUG) + #define __THREAD_DO_NOT_INLINE_DISABLE_DISPATCH__ +#endif + +#if defined(RTEMS_SMP) || \ + (CPU_INLINE_ENABLE_DISPATCH == FALSE) || \ + (__RTEMS_DO_NOT_INLINE_THREAD_ENABLE_DISPATCH__ == 1) + #define __THREAD_DO_NOT_INLINE_ENABLE_DISPATCH__ +#endif + #ifdef __cplusplus extern "C" { #endif |