hw/arm/boot: fix SVE for EL3 direct kernel boot
PATCH 1/1 hw/arm/boot: fix SVE for EL3 direct kernel boot
From: Rémi Denis-Courmont <[email protected]>
When booting a CPU with EL3 using the -kernel flag, set up CPTR_EL3 so that SVE will not trap to EL3.
Signed-off-by Rémi Denis-Courmont <[email protected]>
--- hw/arm/boot.c | 3 +++ 1 file changed, 3 insertions(+)
hw/arm/boot.c +3 -0
@@ -742,6 +742,9 @@ static void do_cpu_reset(void *opaque)if (cpu_isar_feature (aa64_mte, cpu)) { env->cp15.scr_el3 |=SCR_ATA ; } +if (cpu_isar_feature (aa64_sve, cpu)) { + env->cp15.cptr_el[3 ] |=CPTR_EZ ; + }/* AArch64 kernels never boot in secure mode */ assert (!info->secure_boot);/* This hook is only supported for AArch32 currently:
Signature · 1 line
2.29.1
Quoted 9 lines · On 10/30/20 8:15 AM, [email protected] wrote:
From: Rémi Denis-Courmont <[email protected]>
When booting a CPU with EL3 using the -kernel flag, set up
CPTR_EL3so that SVE will not trap to EL3.Signed-off-by Rémi Denis-Courmont <[email protected]>--- hw/arm/boot.c | 3 +++ 1 file changed, 3 insertions(+)
Reviewed-by Richard Henderson <[email protected]>
r~
Peter Maydell
AppliedQuoted 7 lines · Richard Henderson
Quoted 5 lines · On 10/30/20 8:15 AM, [email protected] wrote:
From: Rémi Denis-Courmont <[email protected]>
When booting a CPU with EL3 using the -kernel flag, set up
CPTR_EL3so that SVE will not trap to EL3.
Quoted 6 lines
Quoted 4 lines
Signed-off-by Rémi Denis-Courmont <[email protected]>--- hw/arm/boot.c | 3 +++ 1 file changed, 3 insertions(+)Reviewed-by Richard Henderson <[email protected]>
Applied to target-arm.next, thanks.
-- PMM