diff options
author | Andrew Scull <ascull@google.com> | 2022-05-30 10:00:10 +0000 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2022-06-23 12:58:18 -0400 |
commit | 001c39a196c2f4414ddab8713fa113dd06a028eb (patch) | |
tree | 657e0e6aac951a08364ef2c85ac83bdf601725f0 /arch/sandbox/cpu/os.c | |
parent | 36f641c54e1ad7f08552fe51f9826c1a27b662f9 (diff) |
sandbox: Decouple program entry from sandbox init
Move the program's entry point to os.c, in preparation for a separate
fuzzing entry point to be added.
Signed-off-by: Andrew Scull <ascull@google.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'arch/sandbox/cpu/os.c')
-rw-r--r-- | arch/sandbox/cpu/os.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/sandbox/cpu/os.c b/arch/sandbox/cpu/os.c index 5ea54179176..f229d1621a4 100644 --- a/arch/sandbox/cpu/os.c +++ b/arch/sandbox/cpu/os.c @@ -27,6 +27,7 @@ #include <linux/types.h> #include <asm/getopt.h> +#include <asm/main.h> #include <asm/sections.h> #include <asm/state.h> #include <os.h> @@ -1001,3 +1002,8 @@ void os_relaunch(char *argv[]) execv(argv[0], argv); os_exit(1); } + +int main(int argc, char *argv[]) +{ + return sandbox_main(argc, argv); +} |