aboutsummaryrefslogtreecommitdiff
path: root/libgloss/aarch64/crt0.S
diff options
context:
space:
mode:
Diffstat (limited to 'libgloss/aarch64/crt0.S')
-rw-r--r--libgloss/aarch64/crt0.S6
1 files changed, 6 insertions, 0 deletions
diff --git a/libgloss/aarch64/crt0.S b/libgloss/aarch64/crt0.S
index cbff11a..3bf0278 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. */