diff options
author | PikalaxALT <pikalaxalt@gmail.com> | 2020-05-08 11:55:16 -0400 |
---|---|---|
committer | PikalaxALT <pikalaxalt@gmail.com> | 2020-05-08 11:55:16 -0400 |
commit | 782eca721768b17d51d79e36b519e95d8d9e5b9b (patch) | |
tree | 7ab6dcdcffbb9e4c02ae8b8dc5ce9df7a9113d78 /arm9/lib/src/OS_terminate_proc.c | |
parent | d3bd9a77bb8ca065d295911aca7fbd2da4a846f5 (diff) | |
parent | f76cec09f8a2995244256d4b097d9eed2bebd34a (diff) |
Merge branch 'master' of github.com:martmists/pokediamond into libfs
Diffstat (limited to 'arm9/lib/src/OS_terminate_proc.c')
-rw-r--r-- | arm9/lib/src/OS_terminate_proc.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/arm9/lib/src/OS_terminate_proc.c b/arm9/lib/src/OS_terminate_proc.c new file mode 100644 index 00000000..eb267c6b --- /dev/null +++ b/arm9/lib/src/OS_terminate_proc.c @@ -0,0 +1,21 @@ +// +// Created by red031000 on 2020-05-07. +// + +#include "types.h" +#include "OS_terminate_proc.h" +#include "function_target.h" +#include "OS_system.h" + +ARM_FUNC void OS_Terminate() { + while (TRUE) { + (void)OS_DisableInterrupts(); + OS_Halt(); + } +} + +ARM_FUNC asm void OS_Halt() { + mov r0, #0x0 + mcr p15, 0x0, r0, c7, c0, 0x4 + bx lr +} |