mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-26 14:55:16 +00:00
Add support for Cortex-A57 erratum 826977 workaround
Change-Id: Icaacd19c4cef9c10d02adcc2f84a4d7c97d4bcfa
This commit is contained in:
parent
0b77197baf
commit
072888656d
4 changed files with 43 additions and 0 deletions
|
@ -63,6 +63,9 @@ For Cortex-A57, following errata build flags are defined :
|
||||||
* `ERRATA_A57_826974`: This applies errata 826974 workaround to Cortex-A57
|
* `ERRATA_A57_826974`: This applies errata 826974 workaround to Cortex-A57
|
||||||
CPU. This needs to be enabled only for revision <= r1p1 of the CPU.
|
CPU. This needs to be enabled only for revision <= r1p1 of the CPU.
|
||||||
|
|
||||||
|
* `ERRATA_A57_826977`: This applies errata 826977 workaround to Cortex-A57
|
||||||
|
CPU. This needs to be enabled only for revision <= r1p1 of the CPU.
|
||||||
|
|
||||||
* `ERRATA_A57_828024`: This applies errata 828024 workaround to Cortex-A57
|
* `ERRATA_A57_828024`: This applies errata 828024 workaround to Cortex-A57
|
||||||
CPU. This needs to be enabled only for revision <= r1p1 of the CPU.
|
CPU. This needs to be enabled only for revision <= r1p1 of the CPU.
|
||||||
|
|
||||||
|
|
|
@ -62,6 +62,7 @@
|
||||||
#define CPUACTLR_EL1 S3_1_C15_C2_0 /* Instruction def. */
|
#define CPUACTLR_EL1 S3_1_C15_C2_0 /* Instruction def. */
|
||||||
|
|
||||||
#define CPUACTLR_DIS_LOAD_PASS_DMB (1 << 59)
|
#define CPUACTLR_DIS_LOAD_PASS_DMB (1 << 59)
|
||||||
|
#define CPUACTLR_GRE_NGRE_AS_NGNRE (1 << 54)
|
||||||
#define CPUACTLR_DIS_OVERREAD (1 << 52)
|
#define CPUACTLR_DIS_OVERREAD (1 << 52)
|
||||||
#define CPUACTLR_NO_ALLOC_WBWA (1 << 49)
|
#define CPUACTLR_NO_ALLOC_WBWA (1 << 49)
|
||||||
#define CPUACTLR_DCC_AS_DCCI (1 << 44)
|
#define CPUACTLR_DCC_AS_DCCI (1 << 44)
|
||||||
|
|
|
@ -193,6 +193,32 @@ apply_826974:
|
||||||
ret
|
ret
|
||||||
endfunc errata_a57_826974_wa
|
endfunc errata_a57_826974_wa
|
||||||
|
|
||||||
|
/* ---------------------------------------------------
|
||||||
|
* Errata Workaround for Cortex A57 Errata #826977.
|
||||||
|
* This applies only to revision <= r1p1 of Cortex A57.
|
||||||
|
* Inputs:
|
||||||
|
* x0: variant[4:7] and revision[0:3] of current cpu.
|
||||||
|
* Clobbers : x0 - x5
|
||||||
|
* ---------------------------------------------------
|
||||||
|
*/
|
||||||
|
func errata_a57_826977_wa
|
||||||
|
/*
|
||||||
|
* Compare x0 against revision r1p1
|
||||||
|
*/
|
||||||
|
cmp x0, #0x11
|
||||||
|
b.ls apply_826977
|
||||||
|
#if LOG_LEVEL >= LOG_LEVEL_VERBOSE
|
||||||
|
b print_revision_warning
|
||||||
|
#else
|
||||||
|
ret
|
||||||
|
#endif
|
||||||
|
apply_826977:
|
||||||
|
mrs x1, CPUACTLR_EL1
|
||||||
|
orr x1, x1, #CPUACTLR_GRE_NGRE_AS_NGNRE
|
||||||
|
msr CPUACTLR_EL1, x1
|
||||||
|
ret
|
||||||
|
endfunc errata_a57_826977_wa
|
||||||
|
|
||||||
/* ---------------------------------------------------
|
/* ---------------------------------------------------
|
||||||
* Errata Workaround for Cortex A57 Errata #828024.
|
* Errata Workaround for Cortex A57 Errata #828024.
|
||||||
* This applies only to revision <= r1p1 of Cortex A57.
|
* This applies only to revision <= r1p1 of Cortex A57.
|
||||||
|
@ -289,6 +315,11 @@ func cortex_a57_reset_func
|
||||||
bl errata_a57_826974_wa
|
bl errata_a57_826974_wa
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if ERRATA_A57_826977
|
||||||
|
mov x0, x15
|
||||||
|
bl errata_a57_826977_wa
|
||||||
|
#endif
|
||||||
|
|
||||||
#if ERRATA_A57_828024
|
#if ERRATA_A57_828024
|
||||||
mov x0, x15
|
mov x0, x15
|
||||||
bl errata_a57_828024_wa
|
bl errata_a57_828024_wa
|
||||||
|
|
|
@ -78,6 +78,10 @@ ERRATA_A57_813420 ?=0
|
||||||
# only to revision <= r1p1 of the Cortex A57 cpu.
|
# only to revision <= r1p1 of the Cortex A57 cpu.
|
||||||
ERRATA_A57_826974 ?=0
|
ERRATA_A57_826974 ?=0
|
||||||
|
|
||||||
|
# Flag to apply erratum 826977 workaround during reset. This erratum applies
|
||||||
|
# only to revision <= r1p1 of the Cortex A57 cpu.
|
||||||
|
ERRATA_A57_826977 ?=0
|
||||||
|
|
||||||
# Flag to apply erratum 828024 workaround during reset. This erratum applies
|
# Flag to apply erratum 828024 workaround during reset. This erratum applies
|
||||||
# only to revision <= r1p1 of the Cortex A57 cpu.
|
# only to revision <= r1p1 of the Cortex A57 cpu.
|
||||||
ERRATA_A57_828024 ?=0
|
ERRATA_A57_828024 ?=0
|
||||||
|
@ -106,6 +110,10 @@ $(eval $(call add_define,ERRATA_A57_813420))
|
||||||
$(eval $(call assert_boolean,ERRATA_A57_826974))
|
$(eval $(call assert_boolean,ERRATA_A57_826974))
|
||||||
$(eval $(call add_define,ERRATA_A57_826974))
|
$(eval $(call add_define,ERRATA_A57_826974))
|
||||||
|
|
||||||
|
# Process ERRATA_A57_826977 flag
|
||||||
|
$(eval $(call assert_boolean,ERRATA_A57_826977))
|
||||||
|
$(eval $(call add_define,ERRATA_A57_826977))
|
||||||
|
|
||||||
# Process ERRATA_A57_828024 flag
|
# Process ERRATA_A57_828024 flag
|
||||||
$(eval $(call assert_boolean,ERRATA_A57_828024))
|
$(eval $(call assert_boolean,ERRATA_A57_828024))
|
||||||
$(eval $(call add_define,ERRATA_A57_828024))
|
$(eval $(call add_define,ERRATA_A57_828024))
|
||||||
|
|
Loading…
Add table
Reference in a new issue