aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Rutland <mark.rutland@arm.com>2013-02-08 16:55:09 +0000
committerMark Rutland <mark.rutland@arm.com>2013-06-05 13:56:14 +0100
commit3ca15bca1ec85810f1438a76413cd4e7e8b45254 (patch)
tree7a80b11ac88aa17943054db05ddb0ca6a0afc5df
parentd7e15e0470b60c4c69c0d58ba278231b33b86c69 (diff)
downloadboot-wrapper-aarch64-3ca15bca1ec85810f1438a76413cd4e7e8b45254.tar.gz
Add CURRENTEL_EL3 #define
Add a CURRENTEL_EL3 #define to make tests against the value of CurrentEL clearer. Signed-off-by: Mark Rutland <mark.rutland@arm.com>
-rw-r--r--boot.S2
-rw-r--r--common.S2
2 files changed, 3 insertions, 1 deletions
diff --git a/boot.S b/boot.S
index 9cc382b..69d1714 100644
--- a/boot.S
+++ b/boot.S
@@ -17,7 +17,7 @@ _start:
* EL3 initialisation
*/
mrs x0, CurrentEL
- cmp x0, #0xc // EL3?
+ cmp x0, #CURRENTEL_EL3
b.ne start_ns // skip EL3 initialisation
mov x0, #0x30 // RES1
diff --git a/common.S b/common.S
index d82d11b..bbe005b 100644
--- a/common.S
+++ b/common.S
@@ -7,6 +7,8 @@
* found in the LICENSE.txt file.
*/
+#define CURRENTEL_EL3 (3 << 2)
+
#define SPSR_A (1 << 8) /* System Error masked */
#define SPSR_D (1 << 9) /* Debug masked */
#define SPSR_I (1 << 7) /* IRQ masked */