From a0fee7474fb946fcbcd43c4947cf113147e26301 Mon Sep 17 00:00:00 2001 From: Antonio Nino Diaz Date: Wed, 31 Oct 2018 15:25:35 +0000 Subject: context_mgmt: Fix MISRA defects The macro EL_IMPLEMENTED() has been deprecated in favour of the new function el_implemented(). Change-Id: Ic9b1b81480b5e019b50a050e8c1a199991bf0ca9 Signed-off-by: Antonio Nino Diaz --- bl1/aarch64/bl1_context_mgmt.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'bl1') diff --git a/bl1/aarch64/bl1_context_mgmt.c b/bl1/aarch64/bl1_context_mgmt.c index b9304dcf..9bfb3094 100644 --- a/bl1/aarch64/bl1_context_mgmt.c +++ b/bl1/aarch64/bl1_context_mgmt.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015-2017, ARM Limited and Contributors. All rights reserved. + * Copyright (c) 2015-2018, ARM Limited and Contributors. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -49,9 +49,9 @@ void bl1_prepare_next_image(unsigned int image_id) * Ensure that the build flag to save AArch32 system registers in CPU * context is not set for AArch64-only platforms. */ - if (EL_IMPLEMENTED(1) == EL_IMPL_A64ONLY) { + if (el_implemented(1) == EL_IMPL_A64ONLY) { ERROR("EL1 supports AArch64-only. Please set build flag " - "CTX_INCLUDE_AARCH32_REGS = 0"); + "CTX_INCLUDE_AARCH32_REGS = 0\n"); panic(); } #endif @@ -76,7 +76,7 @@ void bl1_prepare_next_image(unsigned int image_id) DISABLE_ALL_EXCEPTIONS); } else { /* Use EL2 if supported; else use EL1. */ - if (EL_IMPLEMENTED(2)) { + if (el_implemented(2) != EL_IMPL_NONE) { next_bl_ep->spsr = SPSR_64(MODE_EL2, MODE_SP_ELX, DISABLE_ALL_EXCEPTIONS); } else { -- cgit v1.2.3