]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
KVM: arm64: nv: Accelerate EL0 counter accesses from hypervisor context
authorMarc Zyngier <maz@kernel.org>
Tue, 17 Dec 2024 14:23:14 +0000 (14:23 +0000)
committerMarc Zyngier <maz@kernel.org>
Thu, 2 Jan 2025 19:19:10 +0000 (19:19 +0000)
commit9b3b2f00291e1abd54bff345761a7fadd8df4daa
treea8532dafdbdf7b9e0fd66408431af6cb896f85a1
parent338f8ea51944d02ea29eadb3d5fa9196e74a100d
KVM: arm64: nv: Accelerate EL0 counter accesses from hypervisor context

Similarly to handling the physical timer accesses early when FEAT_ECV
causes a trap, we try to handle the physical counter without returning
to the general sysreg handling.

More surprisingly, we introduce something similar for the virtual
counter. Although this isn't necessary yet, it will prove useful on
systems that have a broken CNTVOFF_EL2 implementation. Yes, they exist.

Acked-by: Oliver Upton <oliver.upton@linux.dev>
Link: https://lore.kernel.org/r/20241217142321.763801-7-maz@kernel.org
Signed-off-by: Marc Zyngier <maz@kernel.org>
arch/arm64/kvm/hyp/vhe/switch.c