mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
x86, ia64, smp: use workqueues unconditionally during do_boot_cpu()
Workqueues are now initialized as part of the early_initcall(). So they are available for use during cold boot process aswell. Signed-off-by: Suresh Siddha <[email protected]> Cc: "H. Peter Anvin" <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: Tejun Heo <[email protected]> Cc: Oleg Nesterov <[email protected]> Cc: Tony Luck <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
e446127134
commit
d7a7c57393
2 changed files with 8 additions and 15 deletions
|
|
@ -508,21 +508,18 @@ do_boot_cpu (int sapicid, int cpu)
|
|||
.done = COMPLETION_INITIALIZER(c_idle.done),
|
||||
};
|
||||
|
||||
/*
|
||||
* We can't use kernel_thread since we must avoid to
|
||||
* reschedule the child.
|
||||
*/
|
||||
c_idle.idle = get_idle_for_cpu(cpu);
|
||||
if (c_idle.idle) {
|
||||
init_idle(c_idle.idle, cpu);
|
||||
goto do_rest;
|
||||
}
|
||||
|
||||
/*
|
||||
* We can't use kernel_thread since we must avoid to reschedule the child.
|
||||
*/
|
||||
if (!keventd_up())
|
||||
c_idle.work.func(&c_idle.work);
|
||||
else {
|
||||
schedule_work(&c_idle.work);
|
||||
wait_for_completion(&c_idle.done);
|
||||
}
|
||||
schedule_work(&c_idle.work);
|
||||
wait_for_completion(&c_idle.done);
|
||||
|
||||
if (IS_ERR(c_idle.idle))
|
||||
panic("failed fork for CPU %d", cpu);
|
||||
|
|
|
|||
Loading…
Reference in a new issue