We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8d59983 commit 8dd2a07Copy full SHA for 8dd2a07
src/scheduler.c
@@ -130,16 +130,7 @@ static struct rt_thread* _get_highest_priority_thread(rt_ubase_t *highest_prio)
130
struct rt_cpu* pcpu = rt_cpu_self();
131
#if RT_THREAD_PRIORITY_MAX > 32
132
register rt_ubase_t number;
133
-#endif
134
135
- if (rt_thread_ready_priority_group == 0 && pcpu->priority_group == 0)
136
- {
137
- *highest_prio = pcpu->current_thread->current_priority;
138
- /* only local IDLE is readly */
139
- return pcpu->current_thread;
140
- }
141
-
142
-#if RT_THREAD_PRIORITY_MAX > 32
143
number = __rt_ffs(rt_thread_ready_priority_group) - 1;
144
highest_ready_priority = (number << 3) + __rt_ffs(rt_thread_ready_table[number]) - 1;
145
number = __rt_ffs(pcpu->priority_group) - 1;
0 commit comments