aboutsummaryrefslogtreecommitdiffstats
path: root/init/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'init/main.c')
-rw-r--r--init/main.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/init/main.c b/init/main.c
index 6bf83afd654d..3585f073d636 100644
--- a/init/main.c
+++ b/init/main.c
@@ -71,6 +71,7 @@
71#include <asm/setup.h> 71#include <asm/setup.h>
72#include <asm/sections.h> 72#include <asm/sections.h>
73#include <asm/cacheflush.h> 73#include <asm/cacheflush.h>
74#include <trace/kmemtrace.h>
74 75
75#ifdef CONFIG_X86_LOCAL_APIC 76#ifdef CONFIG_X86_LOCAL_APIC
76#include <asm/smp.h> 77#include <asm/smp.h>
@@ -407,8 +408,7 @@ static void __init smp_init(void)
407 * Set up the current CPU as possible to migrate to. 408 * Set up the current CPU as possible to migrate to.
408 * The other ones will be done by cpu_up/cpu_down() 409 * The other ones will be done by cpu_up/cpu_down()
409 */ 410 */
410 cpu = smp_processor_id(); 411 set_cpu_active(smp_processor_id(), true);
411 cpu_set(cpu, cpu_active_map);
412 412
413 /* FIXME: This should be done in userspace --RR */ 413 /* FIXME: This should be done in userspace --RR */
414 for_each_present_cpu(cpu) { 414 for_each_present_cpu(cpu) {
@@ -649,6 +649,7 @@ asmlinkage void __init start_kernel(void)
649 enable_debug_pagealloc(); 649 enable_debug_pagealloc();
650 cpu_hotplug_init(); 650 cpu_hotplug_init();
651 kmem_cache_init(); 651 kmem_cache_init();
652 kmemtrace_init();
652 debug_objects_mem_init(); 653 debug_objects_mem_init();
653 idr_init_cache(); 654 idr_init_cache();
654 setup_per_cpu_pageset(); 655 setup_per_cpu_pageset();
@@ -770,6 +771,7 @@ static void __init do_basic_setup(void)
770{ 771{
771 rcu_init_sched(); /* needed by module_init stage. */ 772 rcu_init_sched(); /* needed by module_init stage. */
772 init_workqueues(); 773 init_workqueues();
774 cpuset_init_smp();
773 usermodehelper_init(); 775 usermodehelper_init();
774 driver_init(); 776 driver_init();
775 init_irq_proc(); 777 init_irq_proc();
@@ -794,6 +796,7 @@ static void run_init_process(char *init_filename)
794 * makes it inline to init() and it becomes part of init.text section 796 * makes it inline to init() and it becomes part of init.text section
795 */ 797 */
796static noinline int init_post(void) 798static noinline int init_post(void)
799 __releases(kernel_lock)
797{ 800{
798 /* need to finish all async __init code before freeing the memory */ 801 /* need to finish all async __init code before freeing the memory */
799 async_synchronize_full(); 802 async_synchronize_full();
@@ -842,7 +845,7 @@ static int __init kernel_init(void * unused)
842 /* 845 /*
843 * init can run on any cpu. 846 * init can run on any cpu.
844 */ 847 */
845 set_cpus_allowed_ptr(current, CPU_MASK_ALL_PTR); 848 set_cpus_allowed_ptr(current, cpu_all_mask);
846 /* 849 /*
847 * Tell the world that we're going to be the grim 850 * Tell the world that we're going to be the grim
848 * reaper of innocent orphaned children. 851 * reaper of innocent orphaned children.
@@ -863,8 +866,6 @@ static int __init kernel_init(void * unused)
863 smp_init(); 866 smp_init();
864 sched_init_smp(); 867 sched_init_smp();
865 868
866 cpuset_init_smp();
867
868 do_basic_setup(); 869 do_basic_setup();
869 870
870 /* 871 /*