summaryrefslogtreecommitdiff
path: root/common/bl_common.c
diff options
context:
space:
mode:
authorAndrew Thoelke <andrew.thoelke@arm.com>2014-05-16 12:26:26 +0100
committerAndrew Thoelke <andrew.thoelke@arm.com>2014-05-16 12:26:26 +0100
commitef27980d71d0f5f8f83895929e246d0495c9d189 (patch)
tree5e868eed032f450ad30961447a522249d744d74f /common/bl_common.c
parent19ea62d398f9dcb4d25f0856b3f44fb4bd0c4b83 (diff)
parentb793e43166348772af74331df7be46d7a696a7aa (diff)
Merge pull request #69 from sandrine-bailleux:sb/split-mmu-fcts-per-el
Diffstat (limited to 'common/bl_common.c')
-rw-r--r--common/bl_common.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/common/bl_common.c b/common/bl_common.c
index 5361c383..86b0cc5c 100644
--- a/common/bl_common.c
+++ b/common/bl_common.c
@@ -106,9 +106,7 @@ void __dead2 raise_el(aapcs64_params_t *args)
*/
void __dead2 change_el(el_change_info_t *info)
{
- unsigned long current_el = read_current_el();
-
- if (GET_EL(current_el) == MODE_EL3) {
+ if (IS_IN_EL3()) {
/*
* We can go anywhere from EL3. So find where.
* TODO: Lots to do if we are going non-secure.
@@ -551,7 +549,6 @@ void __dead2 run_image(unsigned long entrypoint,
void *second_arg)
{
el_change_info_t run_image_info;
- unsigned long current_el = read_current_el();
/* Tell next EL what we want done */
run_image_info.args.arg0 = RUN_IMAGE;
@@ -565,7 +562,7 @@ void __dead2 run_image(unsigned long entrypoint,
* to jump to a higher EL and issue an SMC. Contents of argY
* will go into the general purpose register xY e.g. arg0->x0
*/
- if (GET_EL(current_el) == MODE_EL3) {
+ if (IS_IN_EL3()) {
run_image_info.args.arg1 = (unsigned long) first_arg;
run_image_info.args.arg2 = (unsigned long) second_arg;
} else {