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 0666656 commit 5d54006Copy full SHA for 5d54006
kernel/task.c
@@ -243,8 +243,8 @@ static list_node_t *find_next_ready_task(void)
243
/* If the counter reaches zero, this task is selected to run. */
244
if (counter == 0) {
245
/* Reload counter from its base priority for the next cycle. */
246
- counter = (task->prio >> 8) & 0xFF;
247
- task->prio = (task->prio & 0xFF00) | counter;
+ uint8_t base = task->prio >> 8;
+ task->prio = (task->prio & 0xFF00) | base;
248
kcb->last_ready_hint = node; /* Update hint for next time */
249
return node;
250
}
0 commit comments