aboutsummaryrefslogtreecommitdiffstats
path: root/init
diff options
context:
space:
mode:
Diffstat (limited to 'init')
-rw-r--r--init/initramfs.c2
-rw-r--r--init/main.c19
2 files changed, 1 insertions, 20 deletions
diff --git a/init/initramfs.c b/init/initramfs.c
index 77b934cccefe..679d870d991b 100644
--- a/init/initramfs.c
+++ b/init/initramfs.c
@@ -519,7 +519,7 @@ void __init populate_rootfs(void)
519 return; 519 return;
520 } 520 }
521 printk("it isn't (%s); looks like an initrd\n", err); 521 printk("it isn't (%s); looks like an initrd\n", err);
522 fd = sys_open("/initrd.image", O_WRONLY|O_CREAT, 700); 522 fd = sys_open("/initrd.image", O_WRONLY|O_CREAT, 0700);
523 if (fd >= 0) { 523 if (fd >= 0) {
524 sys_write(fd, (char *)initrd_start, 524 sys_write(fd, (char *)initrd_start,
525 initrd_end - initrd_start); 525 initrd_end - initrd_start);
diff --git a/init/main.c b/init/main.c
index 006dcd547dc2..64466ea1984c 100644
--- a/init/main.c
+++ b/init/main.c
@@ -645,24 +645,6 @@ static void run_init_process(char *init_filename)
645 execve(init_filename, argv_init, envp_init); 645 execve(init_filename, argv_init, envp_init);
646} 646}
647 647
648static inline void fixup_cpu_present_map(void)
649{
650#ifdef CONFIG_SMP
651 int i;
652
653 /*
654 * If arch is not hotplug ready and did not populate
655 * cpu_present_map, just make cpu_present_map same as cpu_possible_map
656 * for other cpu bringup code to function as normal. e.g smp_init() etc.
657 */
658 if (cpus_empty(cpu_present_map)) {
659 for_each_cpu(i) {
660 cpu_set(i, cpu_present_map);
661 }
662 }
663#endif
664}
665
666static int init(void * unused) 648static int init(void * unused)
667{ 649{
668 lock_kernel(); 650 lock_kernel();
@@ -684,7 +666,6 @@ static int init(void * unused)
684 666
685 do_pre_smp_initcalls(); 667 do_pre_smp_initcalls();
686 668
687 fixup_cpu_present_map();
688 smp_init(); 669 smp_init();
689 sched_init_smp(); 670 sched_init_smp();
690 671