init_task: Use the existing DEFAULT_PRIO macro instead of open-coding it
PATCH 1/1 init_task: Use the existing DEFAULT_PRIO macro instead of open-coding it
There is already a DEFAULT_PRIO macro, which is equal to 'MAX_PRIO - 20'.
We can use it directly in init_task instead of open-coding it.
Signed-off-by Yuntao Wang <[email protected]>
--- init/init_task.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
init/init_task.c +3 -3
@@ -72,9 +72,9 @@ struct task_struct init_task __aligned(L1_CACHE_BYTES) = { .stack = init_stack, .usage = REFCOUNT_INIT(2), .flags = PF_KTHREAD, - .prio = MAX_PRIO - 20, - .static_prio = MAX_PRIO - 20, - .normal_prio = MAX_PRIO - 20, + .prio = DEFAULT_PRIO, + .static_prio = DEFAULT_PRIO, + .normal_prio = DEFAULT_PRIO, .policy = SCHED_NORMAL, .cpus_ptr = &init_task.cpus_mask, .user_cpus_ptr = NULL,
Signature · 1 line
2.47.1