riscv: bootm: Support booting VxWorks
authorBin Meng <bmeng.cn@gmail.com>
Fri, 21 Dec 2018 15:13:41 +0000 (07:13 -0800)
committerTom Rini <trini@konsulko.com>
Mon, 31 Dec 2018 13:08:51 +0000 (08:08 -0500)
Register the 'bootm' function for booting VxWorks kernel for
RISC-V architecture.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
arch/riscv/lib/bootm.c
common/bootm_os.c

index 60b32cca818acce8fd5624c496028893b62055fc..f36b8702ef3d3067f034bf5dd5b55004896f6610 100644 (file)
@@ -86,7 +86,7 @@ static void boot_jump_linux(bootm_headers_t *images, int flag)
 
        bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 
        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);
              (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;
 }
        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);
+}
index 473b9400c87ded388fc2b5c0987833bf4003a5df..855c471c28e6b73ae45c4686d9a4ce93377a550a 100644 (file)
@@ -482,7 +482,7 @@ static boot_os_fn *boot_os[] = {
        [IH_OS_PLAN9] = do_bootm_plan9,
 #endif
 #if defined(CONFIG_BOOTM_VXWORKS) && \
        [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)
        [IH_OS_VXWORKS] = do_bootm_vxworks,
 #endif
 #if defined(CONFIG_CMD_ELF)