summaryrefslogtreecommitdiff
path: root/plat/arm
diff options
context:
space:
mode:
authorJohn Tsichritzis <john.tsichritzis@arm.com>2019-06-03 16:20:46 +0100
committerJohn Tsichritzis <john.tsichritzis@arm.com>2019-06-05 17:46:50 +0100
commit9c29e5f78e54cda2f323604332d167ae38d04d1a (patch)
treeda3642d3b5aee5ba56cc9e1c12b7f4a3b001db74 /plat/arm
parentc9e40ec59eeebb7e7d5c77ca052c1d1eb8ece511 (diff)
FVP: Remove GIC initialisation from secondary core cold boot
During the secondary cores' cold boot path, the cores initialise the GIC CPU interface. However this is a redundant action since 1) the cores are powered down immediately after that, 2) the GIC CPU interface is initialised from scratch when the secondary cores are powered up again later. Moreover, this part of code was introducing a bug. In a GICv3 system, the GIC's CPU interface system registers must not be written without the core being marked as "awake" in the redistributor. However, this sequence was performing such accesses and this would cause those cores to hang. The hang was caused by the DSB instruction that would never complete because of the GIC not recognising those writes. For the two aforementioned reasons, the entire part of the GIC CPU interface initialisation is removed. Change-Id: I6c33a1edda69dd5b6add16a27390a70731b5532a Signed-off-by: John Tsichritzis <john.tsichritzis@arm.com>
Diffstat (limited to 'plat/arm')
-rw-r--r--plat/arm/board/fvp/aarch64/fvp_helpers.S39
1 files changed, 1 insertions, 38 deletions
diff --git a/plat/arm/board/fvp/aarch64/fvp_helpers.S b/plat/arm/board/fvp/aarch64/fvp_helpers.S
index 09f19f6c..8efc2386 100644
--- a/plat/arm/board/fvp/aarch64/fvp_helpers.S
+++ b/plat/arm/board/fvp/aarch64/fvp_helpers.S
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013-2017, ARM Limited and Contributors. All rights reserved.
+ * Copyright (c) 2013-2019, ARM Limited and Contributors. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
@@ -16,14 +16,6 @@
.globl plat_is_my_cpu_primary
.globl plat_arm_calc_core_pos
- .macro fvp_choose_gicmmap param1, param2, x_tmp, w_tmp, res
- mov_imm \x_tmp, V2M_SYSREGS_BASE + V2M_SYS_ID
- ldr \w_tmp, [\x_tmp]
- ubfx \w_tmp, \w_tmp, #V2M_SYS_ID_BLD_SHIFT, #V2M_SYS_ID_BLD_LENGTH
- cmp \w_tmp, #BLD_GIC_VE_MMAP
- csel \res, \param1, \param2, eq
- .endm
-
/* -----------------------------------------------------
* void plat_secondary_cold_boot_setup (void);
*
@@ -50,35 +42,6 @@ func plat_secondary_cold_boot_setup
str w0, [x1, #PPOFFR_OFF]
/* ---------------------------------------------
- * Disable GIC bypass as well
- * ---------------------------------------------
- */
- /* Check for GICv3 system register access */
- mrs x0, id_aa64pfr0_el1
- ubfx x0, x0, #ID_AA64PFR0_GIC_SHIFT, #ID_AA64PFR0_GIC_WIDTH
- cmp x0, #1
- b.ne gicv2_bypass_disable
-
- /* Check for SRE enable */
- mrs x1, ICC_SRE_EL3
- tst x1, #ICC_SRE_SRE_BIT
- b.eq gicv2_bypass_disable
-
- mrs x2, ICC_SRE_EL3
- orr x2, x2, #(ICC_SRE_DIB_BIT | ICC_SRE_DFB_BIT)
- msr ICC_SRE_EL3, x2
- b secondary_cold_boot_wait
-
-gicv2_bypass_disable:
- mov_imm x0, VE_GICC_BASE
- mov_imm x1, BASE_GICC_BASE
- fvp_choose_gicmmap x0, x1, x2, w2, x1
- mov w0, #(IRQ_BYP_DIS_GRP1 | FIQ_BYP_DIS_GRP1)
- orr w0, w0, #(IRQ_BYP_DIS_GRP0 | FIQ_BYP_DIS_GRP0)
- str w0, [x1, #GICC_CTLR]
-
-secondary_cold_boot_wait:
- /* ---------------------------------------------
* There is no sane reason to come out of this
* wfi so panic if we do. This cpu will be pow-
* ered on and reset by the cpu_on pm api