spl: Rename jump_to_image_no_args()
This function is currently a misnomer at times as we have cases where it
passes arguments to the image. In preparation for making that be a more
common case rename this function to jump_to_image(...). In order to do
this, rename jump_to_image in board_init_r(...) to jumper so that we do
not have a conflict.
Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Reword the commit message, adding missing cases of
jump_to_image_no_args()]
Signed-off-by: Tom Rini <trini@konsulko.com>
diff --git a/common/spl/spl.c b/common/spl/spl.c
index 76fd56d..d8e2660 100644
--- a/common/spl/spl.c
+++ b/common/spl/spl.c
@@ -392,7 +392,7 @@
}
#endif
-__weak void __noreturn jump_to_image_no_args(struct spl_image_info *spl_image)
+__weak void __noreturn jump_to_image(struct spl_image_info *spl_image)
{
typedef void __noreturn (*image_entry_noargs_t)(void);
@@ -689,7 +689,7 @@
BOOT_DEVICE_NONE,
BOOT_DEVICE_NONE,
};
- spl_jump_to_image_t jump_to_image = &jump_to_image_no_args;
+ spl_jump_to_image_t jumper = &jump_to_image;
struct spl_image_info spl_image;
int ret, os;
@@ -783,20 +783,20 @@
} else if (CONFIG_IS_ENABLED(ATF) && os == IH_OS_ARM_TRUSTED_FIRMWARE) {
debug("Jumping to U-Boot via ARM Trusted Firmware\n");
spl_fixup_fdt(spl_image_fdt_addr(&spl_image));
- jump_to_image = &spl_invoke_atf;
+ jumper = &spl_invoke_atf;
} else if (CONFIG_IS_ENABLED(OPTEE_IMAGE) && os == IH_OS_TEE) {
debug("Jumping to U-Boot via OP-TEE\n");
spl_board_prepare_for_optee(spl_image_fdt_addr(&spl_image));
- jump_to_image = &jump_to_image_optee;
+ jumper = &jump_to_image_optee;
} else if (CONFIG_IS_ENABLED(OPENSBI) && os == IH_OS_OPENSBI) {
debug("Jumping to U-Boot via RISC-V OpenSBI\n");
- jump_to_image = &spl_invoke_opensbi;
+ jumper = &spl_invoke_opensbi;
} else if (CONFIG_IS_ENABLED(OS_BOOT) && os == IH_OS_LINUX) {
debug("Jumping to Linux\n");
if (IS_ENABLED(CONFIG_SPL_OS_BOOT))
spl_fixup_fdt((void *)SPL_PAYLOAD_ARGS_ADDR);
spl_board_prepare_for_linux();
- jump_to_image = &jump_to_image_linux;
+ jumper = &jump_to_image_linux;
} else {
debug("Unsupported OS image.. Jumping nevertheless..\n");
}
@@ -848,7 +848,7 @@
if (CONFIG_IS_ENABLED(RELOC_LOADER)) {
int ret;
- ret = spl_reloc_jump(&spl_image, jump_to_image);
+ ret = spl_reloc_jump(&spl_image, jumper);
if (ret) {
if (xpl_phase() == PHASE_VPL)
printf("jump failed %d\n", ret);
@@ -856,7 +856,7 @@
}
}
- jump_to_image(&spl_image);
+ jumper(&spl_image);
}
/*