diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2016-06-28 06:54:50 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2016-09-08 09:55:28 +0200 |
commit | b20b736382280fb522d176273645a7e955a97a60 (patch) | |
tree | beb78ee50ef8b6a9257ecf5f8d276af35db11c5a /cpukit/score/src/threadqops.c | |
parent | score: Add scheduler node implementation header (diff) | |
download | rtems-b20b736382280fb522d176273645a7e955a97a60.tar.bz2 |
score: Introduce _Thread_Get_priority()
Avoid direct access to thread internal data fields.
Diffstat (limited to 'cpukit/score/src/threadqops.c')
-rw-r--r-- | cpukit/score/src/threadqops.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cpukit/score/src/threadqops.c b/cpukit/score/src/threadqops.c index 4177151fae..e20241d494 100644 --- a/cpukit/score/src/threadqops.c +++ b/cpukit/score/src/threadqops.c @@ -230,7 +230,7 @@ static bool _Thread_queue_Priority_less( scheduler_node = SCHEDULER_NODE_OF_WAIT_RBTREE_NODE( right ); the_right = _Scheduler_Node_get_owner( scheduler_node ); - return *the_left < the_right->current_priority; + return *the_left < _Thread_Get_priority( the_right ); } static void _Thread_queue_Priority_priority_change( @@ -302,7 +302,7 @@ static void _Thread_queue_Priority_do_enqueue( #endif scheduler_node = _Scheduler_Thread_get_own_node( the_thread ); - current_priority = the_thread->current_priority; + current_priority = _Thread_Get_priority( the_thread ); _RBTree_Initialize_node( &scheduler_node->Wait.Node.RBTree ); _RBTree_Insert_inline( |