summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorNicholas Piggin <npiggin@gmail.com>2019-01-08 00:04:20 +1000
committerStewart Smith <stewart@linux.ibm.com>2019-02-13 14:36:43 +1100
commit02aea4c8760ae9a9913189b9cb93bb8c109e46ed (patch)
treeaa52e120e4f5e9271b86ee189c24807bb09c2a64 /core
parente1d44e8c117f4efa24fcfb7ceb25131774eebfa0 (diff)
downloadtalos-skiboot-02aea4c8760ae9a9913189b9cb93bb8c109e46ed.tar.gz
talos-skiboot-02aea4c8760ae9a9913189b9cb93bb8c109e46ed.zip
core/init: rearrange final boot steps
Take secondaries out of sleep mode as late as possible, which tends to help with simulator boot speeds. Make give_self_os() the last step before starting the kernel, which matches the way secondaries behave. Signed-off-by: Nicholas Piggin <npiggin@gmail.com> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
Diffstat (limited to 'core')
-rw-r--r--core/init.c23
1 files changed, 11 insertions, 12 deletions
diff --git a/core/init.c b/core/init.c
index a2ddbae1..0ad2bfb8 100644
--- a/core/init.c
+++ b/core/init.c
@@ -565,24 +565,12 @@ void __noreturn load_and_boot_kernel(bool is_reboot)
/* Clear SRCs on the op-panel when Linux starts */
op_panel_clear_src();
- cpu_give_self_os();
-
mem_dump_free();
- /* Take processours out of nap */
- cpu_set_sreset_enable(false);
- cpu_set_ipi_enable(false);
-
/* Dump the selected console */
stdoutp = dt_prop_get_def(dt_chosen, "linux,stdout-path", NULL);
prlog(PR_DEBUG, "INIT: stdout-path: %s\n", stdoutp ? stdoutp : "");
-
- printf("INIT: Starting kernel at 0x%llx, fdt at %p %u bytes\n",
- kernel_entry, fdt, fdt_totalsize(fdt));
-
- debug_descriptor.state_flags |= OPAL_BOOT_COMPLETE;
-
fdt_set_boot_cpuid_phys(fdt, this_cpu()->pir);
/* Check there is something there before we branch to it */
@@ -591,6 +579,17 @@ void __noreturn load_and_boot_kernel(bool is_reboot)
assert(0);
}
+ /* Take processors out of nap */
+ cpu_set_sreset_enable(false);
+ cpu_set_ipi_enable(false);
+
+ printf("INIT: Starting kernel at 0x%llx, fdt at %p %u bytes\n",
+ kernel_entry, fdt, fdt_totalsize(fdt));
+
+ debug_descriptor.state_flags |= OPAL_BOOT_COMPLETE;
+
+ cpu_give_self_os();
+
if (kernel_32bit)
start_kernel32(kernel_entry, fdt, mem_top);
start_kernel(kernel_entry, fdt, mem_top);
OpenPOWER on IntegriCloud