diff options
Diffstat (limited to 'cpukit/score/src')
-rw-r--r-- | cpukit/score/src/threadqenqueue.c | 4 | ||||
-rw-r--r-- | cpukit/score/src/threadtimeout.c | 8 |
2 files changed, 3 insertions, 9 deletions
diff --git a/cpukit/score/src/threadqenqueue.c b/cpukit/score/src/threadqenqueue.c index f014fc5781..3be7d58f16 100644 --- a/cpukit/score/src/threadqenqueue.c +++ b/cpukit/score/src/threadqenqueue.c @@ -101,7 +101,7 @@ void _Thread_queue_Enqueue_critical( * as long as we are in the THREAD_QUEUE_INTEND_TO_BLOCK thread wait state, * thus we have to cancel the blocking operation ourself if necessary. */ - success = _Thread_Wait_flags_try_change( + success = _Thread_Wait_flags_try_change_acquire( the_thread, THREAD_QUEUE_INTEND_TO_BLOCK, THREAD_QUEUE_BLOCKED @@ -144,7 +144,7 @@ bool _Thread_queue_Do_extract_locked( * We must update the wait flags under protection of the current thread lock, * otherwise a _Thread_Timeout() running on another processor may interfere. */ - success = _Thread_Wait_flags_try_change_critical( + success = _Thread_Wait_flags_try_change_release( the_thread, THREAD_QUEUE_INTEND_TO_BLOCK, THREAD_QUEUE_READY_AGAIN diff --git a/cpukit/score/src/threadtimeout.c b/cpukit/score/src/threadtimeout.c index 9b5cfa637d..a2ba61f9e7 100644 --- a/cpukit/score/src/threadtimeout.c +++ b/cpukit/score/src/threadtimeout.c @@ -54,15 +54,9 @@ void _Thread_Timeout( Watchdog_Control *watchdog ) _Thread_Do_timeout( the_thread ); - /* - * This fence is only necessary for the events, see _Event_Seize(). The - * thread queues use the thread lock for synchronization. - */ - _Atomic_Fence( ATOMIC_ORDER_RELEASE ); - wait_class = wait_flags & THREAD_WAIT_CLASS_MASK; ready_again = wait_class | THREAD_WAIT_STATE_READY_AGAIN; - success = _Thread_Wait_flags_try_change_critical( + success = _Thread_Wait_flags_try_change_release( the_thread, wait_class | THREAD_WAIT_STATE_INTEND_TO_BLOCK, ready_again |