diff options
author | Nick Piggin <nickpiggin@yahoo.com.au> | 2004-08-23 21:06:56 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2004-08-23 21:06:56 -0700 |
commit | 70a0b8e7c76a71a401332dd6a2a890f32445615a (patch) | |
tree | 67d0a3e8767df0118075ef5078e61fd62884066b /init | |
parent | b2a0e9136df914459cbcf0f072385404f6c4b36d (diff) | |
download | history-70a0b8e7c76a71a401332dd6a2a890f32445615a.tar.gz |
[PATCH] sched: cleanup init_idle()
Clean up init_idle to not use wake_up_forked_process, then undo all the stuff
that call does. Instead, do everything in init_idle.
Make double_rq_lock depend on CONFIG_SMP because it is no longer used on UP.
Signed-off-by: Nick Piggin <nickpiggin@yahoo.com.au>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'init')
-rw-r--r-- | init/main.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/init/main.c b/init/main.c index 46fe75c96308f7..d1c2a7aa1924e4 100644 --- a/init/main.c +++ b/init/main.c @@ -472,6 +472,14 @@ asmlinkage void __init start_kernel(void) */ sched_init(); + /* + * Make us the idle thread. Technically, schedule() should not be + * called from this thread, however somewhere below it might be, + * but because we are the idle thread, we just pick up running again + * when this runqueue becomes "idle". + */ + init_idle(current, smp_processor_id()); + build_all_zonelists(); page_alloc_init(); printk("Kernel command line: %s\n", saved_command_line); @@ -538,13 +546,6 @@ asmlinkage void __init start_kernel(void) acpi_early_init(); /* before LAPIC and SMP init */ - /* - * We count on the initial thread going ok - * Like idlers init is an unlocked kernel thread, which will - * make syscalls (and thus be locked). - */ - init_idle(current, smp_processor_id()); - /* Do the rest non-__init'ed, we're now alive */ rest_init(); } |