From 961a3b05975f8c2b07c54638f5f1843d5f9ce7e0 Mon Sep 17 00:00:00 2001
From: iliya <iliya.saroukha@hes-so.ch>
Date: Wed, 10 Jan 2024 19:40:20 +0100
Subject: [PATCH] feat: added magic values (user / supervisor) for CONTROL
 register when calling switch_mode

---
 macro.h | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/macro.h b/macro.h
index 30581ec..01ddae9 100644
--- a/macro.h
+++ b/macro.h
@@ -8,6 +8,9 @@
 #ifndef MACRO_H_
 #define MACRO_H_
 
+#define SUPERVISOR_CONTROL_VALUE 0
+#define USER_CONTROL_VALUE 3
+
 // Region enable bit
 #define REGION_ENABLE (0x1 << 0)
 
@@ -26,6 +29,4 @@
 #define RW_PRIV (0x1 << 24)
 #define RW_PRIV_R_UNPRIV (0x2 << 24)
 
-
-
 #endif /* MACRO_H_ */
-- 
GitLab