x86: Rename board_final_cleanup() to board_final_init()
authorSimon Glass <sjg@chromium.org>
Fri, 17 Jul 2020 03:22:38 +0000 (21:22 -0600)
committerBin Meng <bmeng.cn@gmail.com>
Fri, 17 Jul 2020 06:32:24 +0000 (14:32 +0800)
This function sounds like something that is called when U-Boot is about to
jump to Linux. In fact it is an init function.

Rename it to reduce confusion.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Wolfgang Wallner <wolfgang.wallner@br-automation.com>
arch/x86/cpu/coreboot/coreboot.c
arch/x86/cpu/cpu.c
arch/x86/cpu/efi/app.c
arch/x86/cpu/quark/quark.c
arch/x86/lib/fsp/fsp_common.c

index d44db13..22a9325 100644 (file)
@@ -42,7 +42,7 @@ int print_cpuinfo(void)
        return default_print_cpuinfo();
 }
 
-static void board_final_cleanup(void)
+static void board_final_init(void)
 {
        /*
         * Un-cache the ROM so the kernel has one
@@ -80,7 +80,7 @@ int last_stage_init(void)
        if (CONFIG_IS_ENABLED(USB_KEYBOARD))
                usb_init();
 
-       board_final_cleanup();
+       board_final_init();
 
        return 0;
 }
index 9ef797b..98ed66e 100644 (file)
@@ -179,10 +179,10 @@ void show_boot_progress(int val)
 
 #if !defined(CONFIG_SYS_COREBOOT) && !defined(CONFIG_EFI_STUB)
 /*
- * Implement a weak default function for boards that optionally
- * need to clean up the system before jumping to the kernel.
+ * Implement a weak default function for boards that need to do some final init
+ * before the system is ready.
  */
-__weak void board_final_cleanup(void)
+__weak void board_final_init(void)
 {
 }
 
@@ -190,7 +190,7 @@ int last_stage_init(void)
 {
        struct acpi_fadt __maybe_unused *fadt;
 
-       board_final_cleanup();
+       board_final_init();
 
        if (IS_ENABLED(CONFIG_HAVE_ACPI_RESUME)) {
                fadt = acpi_find_fadt();
index 10677ec..f754489 100644 (file)
@@ -24,7 +24,7 @@ int print_cpuinfo(void)
        return default_print_cpuinfo();
 }
 
-void board_final_cleanup(void)
+void board_final_init(void)
 {
 }
 
index ddad02e..30b4711 100644 (file)
@@ -363,7 +363,7 @@ int arch_misc_init(void)
        return 0;
 }
 
-void board_final_cleanup(void)
+void board_final_init(void)
 {
        struct quark_rcba *rcba;
        u32 base, val;
index 8e3082d..ea52954 100644 (file)
@@ -47,7 +47,7 @@ int fsp_init_phase_pci(void)
        return status ? -EPERM : 0;
 }
 
-void board_final_cleanup(void)
+void board_final_init(void)
 {
        u32 status;