riscv: bootm: Support booting VxWorks
PATCH 1/1 riscv: bootm: Support booting VxWorks
Register the 'bootm' function for booting VxWorks kernel.
Signed-off-by Bin Meng <[email protected]>
---
arch/riscv/lib/bootm.c | 8 +++++++- common/bootm_os.c | 2 +- include/bootm.h | 2 ++ 3 files changed, 10 insertions(+), 2 deletions(-)
arch/riscv/lib/bootm.c +7 -1
@@ -86,7 +86,7 @@ static void boot_jump_linux(bootm_headers_t *images, int flag)bootstage_mark (BOOTSTAGE_ID_RUN_OS ); -debug ("## Transferring control to Linux (at address %08lx) ...\n" , +debug ("## Transferring control to kernel (at address %08lx) ...\n" , (ulong )kernel);announce_and_cleanup (fake);
@@ -118,3 +118,9 @@ int do_bootm_linux(int flag, int argc, char * const argv[],boot_jump_linux (images, flag);return 0 ; } + +int do_bootm_vxworks (int flag,int argc,char *const argv[], +bootm_headers_t *images) +{ +return do_bootm_linux (flag, argc, argv, images); +}
common/bootm_os.c +1 -1
@@ -482,7 +482,7 @@ static boot_os_fn *boot_os[] = { [IH_OS_PLAN9] = do_bootm_plan9,#endif #if defined(CONFIG_BOOTM_VXWORKS ) && \ - (defined(CONFIG_PPC ) || defined(CONFIG_ARM )) + (defined(CONFIG_PPC ) || defined(CONFIG_ARM ) || defined(CONFIG_RISCV )) [IH_OS_VXWORKS] = do_bootm_vxworks,#endif #if defined(CONFIG_CMD_ELF )
include/bootm.h +2 -0
@@ -35,6 +35,8 @@ typedef int boot_os_fn(int flag, int argc, char * const argv[], bootm_headers_t *images);extern boot_os_fn do_bootm_linux; +extern boot_os_fn do_bootm_vxworks; +int do_bootelf (cmd_tbl_t *cmdtp,int flag,int argc,char *const argv[]);void lynxkdi_boot (image_header_t *hdr);
Signature · 1 line
2.7.4