diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2021-08-10 15:07:35 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2021-08-12 20:58:26 +0200 |
commit | a5aaf20a2d25846c2bfe78e286550fed38d2c111 (patch) | |
tree | 6918797e365abb7fba28ef3adc9ef2ed260bde02 /cpukit/score/src/threadrestart.c | |
parent | rtems: Fix rtems_partition_return_buffer() (diff) | |
download | rtems-a5aaf20a2d25846c2bfe78e286550fed38d2c111.tar.bz2 |
score: Replace priority prepend it with an enum
Use the new Priority_Group_order enum instead of a boolean to indicated if a
priority should be inserted as the first or last node into its priority group.
This makes the code more expressive. It is also a bit more efficient since a
branch in _Scheduler_Node_set_priority() is avoided and a simple bitwise or
operation can be used.
Diffstat (limited to '')
-rw-r--r-- | cpukit/score/src/threadrestart.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cpukit/score/src/threadrestart.c b/cpukit/score/src/threadrestart.c index 79a154e3d3..4b1907a2d9 100644 --- a/cpukit/score/src/threadrestart.c +++ b/cpukit/score/src/threadrestart.c @@ -70,7 +70,7 @@ static void _Thread_Raise_real_priority( the_thread, &the_thread->Real_priority, priority, - false, + PRIORITY_GROUP_LAST, &queue_context ); } @@ -576,7 +576,7 @@ Status_Control _Thread_Restart( the_thread, &the_thread->Real_priority, the_thread->Start.initial_priority, - false, + PRIORITY_GROUP_LAST, &queue_context ); _Thread_Wait_release( the_thread, &queue_context ); |