aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kernel/head32.c9
-rw-r--r--arch/x86/kernel/head64.c9
-rw-r--r--arch/x86/kernel/setup.c9
3 files changed, 9 insertions, 18 deletions
diff --git a/arch/x86/kernel/head32.c b/arch/x86/kernel/head32.c
index a795b54de7d3..138463a24877 100644
--- a/arch/x86/kernel/head32.c
+++ b/arch/x86/kernel/head32.c
@@ -33,9 +33,6 @@ void __init i386_start_kernel(void)
33{ 33{
34 sanitize_boot_params(&boot_params); 34 sanitize_boot_params(&boot_params);
35 35
36 memblock_reserve(__pa_symbol(&_text),
37 __pa_symbol(&__bss_stop) - __pa_symbol(&_text));
38
39 /* Call the subarch specific early setup function */ 36 /* Call the subarch specific early setup function */
40 switch (boot_params.hdr.hardware_subarch) { 37 switch (boot_params.hdr.hardware_subarch) {
41 case X86_SUBARCH_MRST: 38 case X86_SUBARCH_MRST:
@@ -49,11 +46,5 @@ void __init i386_start_kernel(void)
49 break; 46 break;
50 } 47 }
51 48
52 /*
53 * At this point everything still needed from the boot loader
54 * or BIOS or kernel text should be early reserved or marked not
55 * RAM in e820. All other memory is free game.
56 */
57
58 start_kernel(); 49 start_kernel();
59} 50}
diff --git a/arch/x86/kernel/head64.c b/arch/x86/kernel/head64.c
index 6873b070d72c..57334f4cd3af 100644
--- a/arch/x86/kernel/head64.c
+++ b/arch/x86/kernel/head64.c
@@ -186,16 +186,7 @@ void __init x86_64_start_reservations(char *real_mode_data)
186 if (!boot_params.hdr.version) 186 if (!boot_params.hdr.version)
187 copy_bootdata(__va(real_mode_data)); 187 copy_bootdata(__va(real_mode_data));
188 188
189 memblock_reserve(__pa_symbol(&_text),
190 __pa_symbol(&__bss_stop) - __pa_symbol(&_text));
191
192 reserve_ebda_region(); 189 reserve_ebda_region();
193 190
194 /*
195 * At this point everything still needed from the boot loader
196 * or BIOS or kernel text should be early reserved or marked not
197 * RAM in e820. All other memory is free game.
198 */
199
200 start_kernel(); 191 start_kernel();
201} 192}
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index 5dc47c3e537b..a74701af74e3 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -805,8 +805,17 @@ early_param("reservelow", parse_reservelow);
805 805
806void __init setup_arch(char **cmdline_p) 806void __init setup_arch(char **cmdline_p)
807{ 807{
808 memblock_reserve(__pa_symbol(_text),
809 (unsigned long)__bss_stop - (unsigned long)_text);
810
808 early_reserve_initrd(); 811 early_reserve_initrd();
809 812
813 /*
814 * At this point everything still needed from the boot loader
815 * or BIOS or kernel text should be early reserved or marked not
816 * RAM in e820. All other memory is free game.
817 */
818
810#ifdef CONFIG_X86_32 819#ifdef CONFIG_X86_32
811 memcpy(&boot_cpu_data, &new_cpu_data, sizeof(new_cpu_data)); 820 memcpy(&boot_cpu_data, &new_cpu_data, sizeof(new_cpu_data));
812 visws_early_detect(); 821 visws_early_detect();