diff options
Diffstat (limited to 'src/user')
-rw-r--r-- | src/user/user.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/user/user.c b/src/user/user.c index 87f4b49..620ffd0 100644 --- a/src/user/user.c +++ b/src/user/user.c @@ -15,11 +15,12 @@ void user_delay(uint32_t ms) int fork(void) { - int result; + int result = 0; asm("\ - svc 3; \ - mov %0, r0; \ - " : "=r" (result)); + mov r0, 1; \ + mov r1, %0; \ + svc 0; \ + " :: "r" (&result)); return result; } |