diff options
author | red031000 <rubenru09@aol.com> | 2020-05-07 15:40:45 +0100 |
---|---|---|
committer | red031000 <rubenru09@aol.com> | 2020-05-07 15:42:07 +0100 |
commit | c8255e7f323a58625992973f9777a9928947f310 (patch) | |
tree | 23c55b3ce891cb00f546d13a86a4d1c6fb02724e /arm9/lib/src/OS_terminate_proc.c | |
parent | 7bd2d6636ba5a34fb0ae984f377f690d51ba97f0 (diff) |
OS_terminate_proc
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 +} |