diff --git a/sys/arm64/arm64/locore.S b/sys/arm64/arm64/locore.S --- a/sys/arm64/arm64/locore.S +++ b/sys/arm64/arm64/locore.S @@ -420,6 +420,11 @@ isb 2: + /* Set CNTPOFF_EL2 if available */ + CHECK_CPU_FEAT(x2, ID_AA64MMFR0, ECV, POFF, .Lno_feat_ecv_poff) + msr CNTPOFF_EL2_REG, xzr +.Lno_feat_ecv_poff: + /* Don't trap to EL2 for CP15 traps */ msr hstr_el2, xzr