Commit b23decf
sched: Initialize idle tasks only once
Idle tasks are initialized via __sched_fork() twice:
fork_idle()
copy_process()
sched_fork()
__sched_fork()
init_idle()
__sched_fork()
Instead of cleaning this up, sched_ext hacked around it. Even when analyis
and solution were provided in a discussion, nobody cared to clean this up.
init_idle() is also invoked from sched_init() to initialize the boot CPU's
idle task, which requires the __sched_fork() invocation. But this can be
trivially solved by invoking __sched_fork() before init_idle() in
sched_init() and removing the __sched_fork() invocation from init_idle().
Do so and clean up the comments explaining this historical leftover.
Signed-off-by: Thomas Gleixner <[email protected]>
Signed-off-by: Peter Zijlstra (Intel) <[email protected]>
Link: https://lore.kernel.org/r/[email protected]1 parent 1a61510 commit b23decf
1 file changed
+5
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4423 | 4423 | | |
4424 | 4424 | | |
4425 | 4425 | | |
4426 | | - | |
| 4426 | + | |
| 4427 | + | |
4427 | 4428 | | |
4428 | 4429 | | |
4429 | 4430 | | |
| |||
7697 | 7698 | | |
7698 | 7699 | | |
7699 | 7700 | | |
7700 | | - | |
7701 | | - | |
7702 | 7701 | | |
7703 | 7702 | | |
7704 | 7703 | | |
| |||
7713 | 7712 | | |
7714 | 7713 | | |
7715 | 7714 | | |
7716 | | - | |
7717 | | - | |
7718 | | - | |
7719 | | - | |
| 7715 | + | |
| 7716 | + | |
7720 | 7717 | | |
7721 | 7718 | | |
7722 | 7719 | | |
| |||
8561 | 8558 | | |
8562 | 8559 | | |
8563 | 8560 | | |
| 8561 | + | |
8564 | 8562 | | |
8565 | 8563 | | |
8566 | 8564 | | |
| |||
0 commit comments