mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-16 09:34:18 +00:00
feat(cpus): conform DSU errata to errata framework PCS
Errata framework expects workarounds to clobber x0 to x8 and checker functions to clobber x0-x4. Update DSU errata functions to adhere to the standard, which is documented here: https://review.trustedfirmware.org/c/TF-A/trusted-firmware-a/+/19295. Signed-off-by: Kathleen Capella <kathleen.capella@arm.com> Change-Id: Ie0e492473ab8b2bee4335b6b1db00796fabdd59d
This commit is contained in:
parent
a0f3b552cf
commit
ee6d04d449
1 changed files with 14 additions and 15 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2019-2022, Arm Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2019-2023, Arm Limited and Contributors. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -44,11 +44,11 @@ endfunc check_errata_dsu_798953
|
|||
/* --------------------------------------------------
|
||||
* Errata Workaround for DSU erratum #798953.
|
||||
*
|
||||
* Can clobber only: x0-x17
|
||||
* Can clobber only: x0-x8
|
||||
* --------------------------------------------------
|
||||
*/
|
||||
func errata_dsu_798953_wa
|
||||
mov x17, x30
|
||||
mov x8, x30
|
||||
bl check_errata_dsu_798953
|
||||
cbz x0, 1f
|
||||
|
||||
|
@ -58,7 +58,7 @@ func errata_dsu_798953_wa
|
|||
msr CLUSTERACTLR_EL1, x0
|
||||
isb
|
||||
1:
|
||||
ret x17
|
||||
ret x8
|
||||
endfunc errata_dsu_798953_wa
|
||||
|
||||
/* -----------------------------------------------------------------------
|
||||
|
@ -72,7 +72,7 @@ endfunc errata_dsu_798953_wa
|
|||
* This function is called from both assembly and C environment. So it
|
||||
* follows AAPCS.
|
||||
*
|
||||
* Clobbers: x0-x15
|
||||
* Clobbers: x0-x4
|
||||
* -----------------------------------------------------------------------
|
||||
*/
|
||||
.globl check_errata_dsu_936184
|
||||
|
@ -83,7 +83,7 @@ endfunc errata_dsu_798953_wa
|
|||
* Default behaviour respresents SCU is always present with DSU.
|
||||
* CPUs can override this definition if required.
|
||||
*
|
||||
* Can clobber only: x0-x14
|
||||
* Can clobber only: x0-x3
|
||||
* --------------------------------------------------------------------
|
||||
*/
|
||||
func is_scu_present_in_dsu
|
||||
|
@ -92,7 +92,7 @@ func is_scu_present_in_dsu
|
|||
endfunc is_scu_present_in_dsu
|
||||
|
||||
func check_errata_dsu_936184
|
||||
mov x15, x30
|
||||
mov x4, x30
|
||||
bl is_scu_present_in_dsu
|
||||
cmp x0, xzr
|
||||
/* Default error status */
|
||||
|
@ -116,17 +116,17 @@ func check_errata_dsu_936184
|
|||
b.hs 1f
|
||||
mov x0, #ERRATA_APPLIES
|
||||
1:
|
||||
ret x15
|
||||
ret x4
|
||||
endfunc check_errata_dsu_936184
|
||||
|
||||
/* --------------------------------------------------
|
||||
* Errata Workaround for DSU erratum #936184.
|
||||
*
|
||||
* Can clobber only: x0-x17
|
||||
* Can clobber only: x0-x8
|
||||
* --------------------------------------------------
|
||||
*/
|
||||
func errata_dsu_936184_wa
|
||||
mov x17, x30
|
||||
mov x8, x30
|
||||
bl check_errata_dsu_936184
|
||||
cbz x0, 1f
|
||||
|
||||
|
@ -137,7 +137,7 @@ func errata_dsu_936184_wa
|
|||
msr CLUSTERACTLR_EL1, x0
|
||||
isb
|
||||
1:
|
||||
ret x17
|
||||
ret x8
|
||||
endfunc errata_dsu_936184_wa
|
||||
|
||||
/* -----------------------------------------------------------------------
|
||||
|
@ -176,11 +176,11 @@ endfunc check_errata_dsu_2313941
|
|||
/* --------------------------------------------------
|
||||
* Errata Workaround for DSU erratum #2313941.
|
||||
*
|
||||
* Can clobber only: x0-x17
|
||||
* Can clobber only: x0-x8
|
||||
* --------------------------------------------------
|
||||
*/
|
||||
func errata_dsu_2313941_wa
|
||||
mov x17, x30
|
||||
mov x8, x30
|
||||
bl check_errata_dsu_2313941
|
||||
cbz x0, 1f
|
||||
|
||||
|
@ -190,6 +190,5 @@ func errata_dsu_2313941_wa
|
|||
msr CLUSTERACTLR_EL1, x0
|
||||
isb
|
||||
1:
|
||||
ret x17
|
||||
ret x8
|
||||
endfunc errata_dsu_2313941_wa
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue