diff --git a/libgloss/aarch64/crt0.S b/libgloss/aarch64/crt0.S index cbff11a49..3bf027874 100644 --- a/libgloss/aarch64/crt0.S +++ b/libgloss/aarch64/crt0.S @@ -157,6 +157,7 @@ bl FUNCTION (_init) +#ifdef ARM_RDI_MONITOR /* Fetch and parse the command line. */ ldr x1, .Lcmdline /* Command line descriptor. */ mov w0, #AngelSVC_Reason_GetCmdLine @@ -219,6 +220,11 @@ and x4, x1, ~15 mov sp, x4 +#else + mov x0, #0 /* argc = 0 */ + mov x1, #0 /* argv = NULL */ +#endif + bl FUNCTION (main) b FUNCTION (exit) /* Cannot return. */