diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2016-06-27 10:20:34 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2016-07-27 10:55:30 +0200 |
commit | ac8402ddd6e4a8eb6defb98220d39d4c20a6f025 (patch) | |
tree | 611996f2488f8b38180735dc9f51c1252bc024e5 /cpukit/score/src/mutex.c | |
parent | score: Split _Thread_Change_priority() (diff) | |
download | rtems-ac8402ddd6e4a8eb6defb98220d39d4c20a6f025.tar.bz2 |
score: Simplify _Thread_queue_Boost_priority()
Raise the priority under thread queue lock protection and omit the
superfluous thread queue priority change, since the thread is extracted
anyway. The unblock operation will pick up the new priority.
Update #2412.
Update #2556.
Update #2765.
Diffstat (limited to 'cpukit/score/src/mutex.c')
-rw-r--r-- | cpukit/score/src/mutex.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cpukit/score/src/mutex.c b/cpukit/score/src/mutex.c index 525992afe5..4b95262f18 100644 --- a/cpukit/score/src/mutex.c +++ b/cpukit/score/src/mutex.c @@ -136,13 +136,13 @@ static void _Mutex_Release_slow( mutex->Queue.Queue.owner = first; ++first->resource_count; + _Thread_queue_Boost_priority( &mutex->Queue.Queue, first ); unblock = _Thread_queue_Extract_locked( &mutex->Queue.Queue, operations, first, queue_context ); - _Thread_queue_Boost_priority( &mutex->Queue.Queue, first ); _Thread_queue_Unblock_critical( unblock, &mutex->Queue.Queue, |