summaryrefslogtreecommitdiff
path: root/arm9/asm/OS_protectionUnit.s
diff options
context:
space:
mode:
Diffstat (limited to 'arm9/asm/OS_protectionUnit.s')
-rw-r--r--arm9/asm/OS_protectionUnit.s18
1 files changed, 18 insertions, 0 deletions
diff --git a/arm9/asm/OS_protectionUnit.s b/arm9/asm/OS_protectionUnit.s
new file mode 100644
index 00000000..c26f86ba
--- /dev/null
+++ b/arm9/asm/OS_protectionUnit.s
@@ -0,0 +1,18 @@
+ .include "asm/macros.inc"
+ .include "global.inc"
+
+ .text
+
+ arm_func_start OS_EnableProtectionUnit
+OS_EnableProtectionUnit: ; 0x020CC9B8
+ mrc p15, 0x0, r0, c1, c0, 0x0
+ orr r0, r0, #0x1
+ mcr p15, 0x0, r0, c1, c0, 0x0
+ bx lr
+
+ arm_func_start OS_DisableProtectionUnit
+OS_DisableProtectionUnit: ; 0x020CC9C8
+ mrc p15, 0x0, r0, c1, c0, 0x0
+ bic r0, r0, #0x1
+ mcr p15, 0x0, r0, c1, c0, 0x0
+ bx lr