[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v5 04/12] target/arm: Remove EL2 and EL3 setup from user-only
From: |
Richard Henderson |
Subject: |
[PATCH v5 04/12] target/arm: Remove EL2 and EL3 setup from user-only |
Date: |
Fri, 28 Feb 2020 17:28:03 -0800 |
We have disabled EL2 and EL3 for user-only, which means that these
registers "don't exist" and should not be set.
Signed-off-by: Richard Henderson <address@hidden>
---
target/arm/cpu.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/target/arm/cpu.c b/target/arm/cpu.c
index 33c28fe868..af541431e6 100644
--- a/target/arm/cpu.c
+++ b/target/arm/cpu.c
@@ -191,19 +191,13 @@ static void arm_cpu_reset(CPUState *s)
/* Enable all PAC keys. */
env->cp15.sctlr_el[1] |= (SCTLR_EnIA | SCTLR_EnIB |
SCTLR_EnDA | SCTLR_EnDB);
- /* Enable all PAC instructions */
- env->cp15.hcr_el2 |= HCR_API;
- env->cp15.scr_el3 |= SCR_API;
/* and to the FP/Neon instructions */
env->cp15.cpacr_el1 = deposit64(env->cp15.cpacr_el1, 20, 2, 3);
/* and to the SVE instructions */
env->cp15.cpacr_el1 = deposit64(env->cp15.cpacr_el1, 16, 2, 3);
- env->cp15.cptr_el[3] |= CPTR_EZ;
/* with maximum vector length */
env->vfp.zcr_el[1] = cpu_isar_feature(aa64_sve, cpu) ?
cpu->sve_max_vq - 1 : 0;
- env->vfp.zcr_el[2] = env->vfp.zcr_el[1];
- env->vfp.zcr_el[3] = env->vfp.zcr_el[1];
/*
* Enable TBI0 and TBI1. While the real kernel only enables TBI0,
* turning on both here will produce smaller code and otherwise
--
2.20.1
- [PATCH v5 00/12] target/arm: Honor more HCR_EL2 traps, Richard Henderson, 2020/02/28
- [PATCH v5 01/12] target/arm: Improve masking of HCR/HCR2 RES0 bits, Richard Henderson, 2020/02/28
- [PATCH v5 02/12] target/arm: Add HCR_EL2 bit definitions from ARMv8.6, Richard Henderson, 2020/02/28
- [PATCH v5 05/12] target/arm: Improve masking in arm_hcr_el2_eff, Richard Henderson, 2020/02/28
- [PATCH v5 04/12] target/arm: Remove EL2 and EL3 setup from user-only,
Richard Henderson <=
- [PATCH v5 06/12] target/arm: Honor the HCR_EL2.{TVM,TRVM} bits, Richard Henderson, 2020/02/28
- [PATCH v5 08/12] target/arm: Honor the HCR_EL2.TACR bit, Richard Henderson, 2020/02/28
- [PATCH v5 11/12] target/arm: Honor the HCR_EL2.TTLB bit, Richard Henderson, 2020/02/28
- [PATCH v5 07/12] target/arm: Honor the HCR_EL2.TSW bit, Richard Henderson, 2020/02/28
- [PATCH v5 09/12] target/arm: Honor the HCR_EL2.TPCP bit, Richard Henderson, 2020/02/28
- [PATCH v5 10/12] target/arm: Honor the HCR_EL2.TPU bit, Richard Henderson, 2020/02/28
- [PATCH v5 12/12] tests/tcg/aarch64: Add newline in pauth-1 printf, Richard Henderson, 2020/02/28
- [PATCH v5 03/12] target/arm: Disable has_el2 and has_el3 for user-only, Richard Henderson, 2020/02/28