hv_exc: Handle SYS_IMP_APL_CYC_OVRD in the fast path

m1n1 now uses this for SMP, and due to wfi FIQ leakage from the HV
timer this gets spammed thousands of times per second. Handle it in
the HV directly.

Fixes: #107

Signed-off-by: Hector Martin <marcan@marcan.st>
This commit is contained in:
Hector Martin 2021-09-18 22:27:27 +09:00
parent 37b2fdda7c
commit c3ba77ce16
2 changed files with 4 additions and 1 deletions

View file

@ -546,7 +546,6 @@ class HV(Reloadable):
} }
ro = { ro = {
ACC_CFG_EL1, ACC_CFG_EL1,
CYC_OVRD_EL1,
ACC_OVRD_EL1, ACC_OVRD_EL1,
} }
value = 0 value = 0

View file

@ -166,6 +166,10 @@ static bool hv_handle_msr(u64 *regs, u64 iss)
SYSREG_PASS(SYS_IMP_APL_PMC7) SYSREG_PASS(SYS_IMP_APL_PMC7)
SYSREG_PASS(SYS_IMP_APL_PMC8) SYSREG_PASS(SYS_IMP_APL_PMC8)
SYSREG_PASS(SYS_IMP_APL_PMC9) SYSREG_PASS(SYS_IMP_APL_PMC9)
/* Handle this one here because m1n1/Linux (will) use it for explicit cpuidle.
* We can pass it through; going into deep sleep doesn't break the HV since we
* don't do any wfis that assume otherwise in m1n1. */
SYSREG_PASS(SYS_IMP_APL_CYC_OVRD)
/* IPI handling */ /* IPI handling */
SYSREG_PASS(SYS_IMP_APL_IPI_RR_LOCAL_EL1) SYSREG_PASS(SYS_IMP_APL_IPI_RR_LOCAL_EL1)
SYSREG_PASS(SYS_IMP_APL_IPI_RR_GLOBAL_EL1) SYSREG_PASS(SYS_IMP_APL_IPI_RR_GLOBAL_EL1)