Commit 262aceaa authored by Sandeep Tripathy's avatar Sandeep Tripathy
Browse files

ehf: use common priority level enumuration



'EHF' is used by RAS, SDEI, SPM_MM common frameworks.
If platform needs to plug-in specific handlers then
'PLAT_EHF_DESC' can be used to populate platform specific
priority levels.
Signed-off-by: default avatarSandeep Tripathy <sandeep.tripathy@broadcom.com>
Change-Id: I37af7e0e48111f87b6982604bf5c15db3e05755d
parent 3e1e08b7
...@@ -568,7 +568,7 @@ ...@@ -568,7 +568,7 @@
#define PLAT_SDEI_NORMAL_PRI 0x70 #define PLAT_SDEI_NORMAL_PRI 0x70
/* ARM platforms use 3 upper bits of secure interrupt priority */ /* ARM platforms use 3 upper bits of secure interrupt priority */
#define ARM_PRI_BITS 3 #define PLAT_PRI_BITS 3
/* SGI used for SDEI signalling */ /* SGI used for SDEI signalling */
#define ARM_SDEI_SGI ARM_IRQ_SEC_SGI_0 #define ARM_SDEI_SGI ARM_IRQ_SEC_SGI_0
......
...@@ -258,7 +258,7 @@ endif ...@@ -258,7 +258,7 @@ endif
endif endif
ifeq (${EL3_EXCEPTION_HANDLING},1) ifeq (${EL3_EXCEPTION_HANDLING},1)
BL31_SOURCES += plat/arm/common/aarch64/arm_ehf.c BL31_SOURCES += plat/common/aarch64/plat_ehf.c
endif endif
ifeq (${SDEI_SUPPORT},1) ifeq (${SDEI_SUPPORT},1)
......
/* /*
* Copyright (c) 2017-2019, ARM Limited and Contributors. All rights reserved. * Copyright (c) 2017-2020, ARM Limited and Contributors. All rights reserved.
* * Copyright (c) 2020, Broadcom
* SPDX-License-Identifier: BSD-3-Clause * SPDX-License-Identifier: BSD-3-Clause
*/ */
#include <platform_def.h>
#include <bl31/ehf.h> #include <bl31/ehf.h>
#include <platform_def.h>
/* /*
* Enumeration of priority levels on ARM platforms. * Enumeration of priority levels on ARM platforms.
*/ */
ehf_pri_desc_t arm_exceptions[] = { ehf_pri_desc_t plat_exceptions[] = {
#if RAS_EXTENSION #if RAS_EXTENSION
/* RAS Priority */ /* RAS Priority */
EHF_PRI_DESC(ARM_PRI_BITS, PLAT_RAS_PRI), EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_RAS_PRI),
#endif #endif
#if SDEI_SUPPORT #if SDEI_SUPPORT
/* Critical priority SDEI */ /* Critical priority SDEI */
EHF_PRI_DESC(ARM_PRI_BITS, PLAT_SDEI_CRITICAL_PRI), EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_SDEI_CRITICAL_PRI),
/* Normal priority SDEI */ /* Normal priority SDEI */
EHF_PRI_DESC(ARM_PRI_BITS, PLAT_SDEI_NORMAL_PRI), EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_SDEI_NORMAL_PRI),
#endif #endif
#if SPM_MM #if SPM_MM
EHF_PRI_DESC(ARM_PRI_BITS, PLAT_SP_PRI), EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_SP_PRI),
#endif
/* Plaform specific exceptions description */
#ifdef PLAT_EHF_DESC
PLAT_EHF_DESC,
#endif #endif
}; };
/* Plug in ARM exceptions to Exception Handling Framework. */ /* Plug in ARM exceptions to Exception Handling Framework. */
EHF_REGISTER_PRIORITIES(arm_exceptions, ARRAY_SIZE(arm_exceptions), ARM_PRI_BITS); EHF_REGISTER_PRIORITIES(plat_exceptions, ARRAY_SIZE(plat_exceptions), PLAT_PRI_BITS);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment