aboutsummaryrefslogtreecommitdiffstats
path: root/init/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'init/main.c')
-rw-r--r--init/main.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/init/main.c b/init/main.c
index 05b313283311..844209453c02 100644
--- a/init/main.c
+++ b/init/main.c
@@ -62,6 +62,7 @@
62#include <linux/signal.h> 62#include <linux/signal.h>
63#include <linux/idr.h> 63#include <linux/idr.h>
64#include <linux/ftrace.h> 64#include <linux/ftrace.h>
65#include <linux/async.h>
65#include <trace/boot.h> 66#include <trace/boot.h>
66 67
67#include <asm/io.h> 68#include <asm/io.h>
@@ -685,7 +686,7 @@ asmlinkage void __init start_kernel(void)
685 rest_init(); 686 rest_init();
686} 687}
687 688
688static int initcall_debug; 689int initcall_debug;
689core_param(initcall_debug, initcall_debug, bool, 0644); 690core_param(initcall_debug, initcall_debug, bool, 0644);
690 691
691int do_one_initcall(initcall_t fn) 692int do_one_initcall(initcall_t fn)
@@ -786,6 +787,8 @@ static void run_init_process(char *init_filename)
786 */ 787 */
787static noinline int init_post(void) 788static noinline int init_post(void)
788{ 789{
790 /* need to finish all async __init code before freeing the memory */
791 async_synchronize_full();
789 free_initmem(); 792 free_initmem();
790 unlock_kernel(); 793 unlock_kernel();
791 mark_rodata_ro(); 794 mark_rodata_ro();