diff --git a/common/cmd_elf.c b/common/cmd_elf.c index d6a2036a992c4dd23072265cc15dbd503302d942..86e694ac69c42c314a28d5214dae9972469858a0 100644 --- a/common/cmd_elf.c +++ b/common/cmd_elf.c @@ -20,6 +20,7 @@ #include #ifdef CONFIG_X86 #include +#include #endif /* @@ -379,7 +380,12 @@ int do_bootvx(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) printf("## Starting vxWorks at 0x%08lx ...\n", addr); dcache_disable(); +#ifdef CONFIG_X86 + /* VxWorks on x86 uses stack to pass parameters */ + ((asmlinkage void (*)(int))addr)(0); +#else ((void (*)(int))addr)(0); +#endif puts("## vxWorks terminated\n");