diff --git a/Makefile b/Makefile index 7f781a09a..a02f04bcc 100644 --- a/Makefile +++ b/Makefile @@ -1283,6 +1283,7 @@ $(eval $(call assert_booleans,\ ENABLE_RUNTIME_INSTRUMENTATION \ ENABLE_SME_FOR_SWD \ ENABLE_SVE_FOR_SWD \ + ENABLE_FEAT_RAS \ ERROR_DEPRECATED \ FAULT_INJECTION_SUPPORT \ GENERATE_COT \ @@ -1360,7 +1361,6 @@ $(eval $(call assert_numerics,\ ENABLE_FEAT_AMU \ ENABLE_FEAT_AMUv1p1 \ ENABLE_FEAT_CSV2_2 \ - ENABLE_FEAT_RAS \ ENABLE_FEAT_DIT \ ENABLE_FEAT_ECV \ ENABLE_FEAT_FGT \ @@ -1443,6 +1443,7 @@ $(eval $(call add_defines,\ ENABLE_SPE_FOR_NS \ ENABLE_SVE_FOR_NS \ ENABLE_SVE_FOR_SWD \ + ENABLE_FEAT_RAS \ ENCRYPT_BL31 \ ENCRYPT_BL32 \ ERROR_DEPRECATED \ @@ -1460,7 +1461,6 @@ $(eval $(call add_defines,\ PROGRAMMABLE_RESET_ADDRESS \ PSCI_EXTENDED_STATE_ID \ PSCI_OS_INIT_MODE \ - ENABLE_FEAT_RAS \ RAS_FFH_SUPPORT \ RESET_TO_BL31 \ SEPARATE_CODE_AND_RODATA \ diff --git a/docs/getting_started/build-options.rst b/docs/getting_started/build-options.rst index 347cf20bc..51c5c785f 100644 --- a/docs/getting_started/build-options.rst +++ b/docs/getting_started/build-options.rst @@ -813,8 +813,10 @@ Common build options - ``ENABLE_FEAT_RAS``: Numeric value to enable Armv8.2 RAS features. RAS features are an optional extension for pre-Armv8.2 CPUs, but are mandatory for Armv8.2 - or later CPUs. This flag can take the values 0 to 2, to align with the - ``FEATURE_DETECTION`` mechanism. + or later CPUs. This flag can take the values 0 or 1. The default value is 0. + NOTE: This flag enables use of IESB capability to reduce entry latency into + EL3 even when RAS error handling is not performed on the platform. Hence this + flag is recommended to be turned on Armv8.2 and later CPUs. - ``RAS_FFH_SUPPORT``: Support to enable Firmware first handling of RAS errors originating from NS world. When ``RAS_FFH_SUPPORT`` is set to ``1``, diff --git a/include/arch/aarch64/asm_macros.S b/include/arch/aarch64/asm_macros.S index 53c7d0b08..d09ad0f0d 100644 --- a/include/arch/aarch64/asm_macros.S +++ b/include/arch/aarch64/asm_macros.S @@ -309,12 +309,7 @@ * entry and exception return, so there is no need for any explicit instruction. */ .macro synchronize_errors - /* - * This is a hot path, so we don't want to do some actual FEAT_RAS runtime - * detection here. For ENABLE_FEAT_RAS==2, its not ideal but won't hurt as - * state 2 is mostly used by configurable platforms(fvp/qemu). - */ -#if ENABLE_FEAT_RAS != 1 +#if !ENABLE_FEAT_RAS /* Complete any stores that may return an abort */ dsb sy /* Synchronise the CPU context with the completion of the dsb */ diff --git a/include/arch/aarch64/el3_common_macros.S b/include/arch/aarch64/el3_common_macros.S index b40473a4e..a78837f23 100644 --- a/include/arch/aarch64/el3_common_macros.S +++ b/include/arch/aarch64/el3_common_macros.S @@ -208,7 +208,7 @@ */ mov_imm x0, (SCTLR_RESET_VAL & ~(SCTLR_EE_BIT | SCTLR_WXN_BIT \ | SCTLR_SA_BIT | SCTLR_A_BIT | SCTLR_DSSBS_BIT)) -#if ENABLE_FEAT_RAS == 1 +#if ENABLE_FEAT_RAS /* If FEAT_RAS is present assume FEAT_IESB is also present */ orr x0, x0, #SCTLR_IESB_BIT #endif diff --git a/plat/arm/board/fvp/platform.mk b/plat/arm/board/fvp/platform.mk index f7c174f78..3104efa5e 100644 --- a/plat/arm/board/fvp/platform.mk +++ b/plat/arm/board/fvp/platform.mk @@ -56,7 +56,6 @@ ifneq (${SPD}, tspd) ENABLE_FEAT_RNG := 2 ENABLE_FEAT_TWED := 2 ENABLE_FEAT_GCS := 2 - ENABLE_FEAT_RAS := 2 ifeq (${ARCH}, aarch64) ifneq (${SPD}, spmd) ifeq (${SPM_MM}, 0)