Skip to content

Commit 9a1950f

Browse files
author
Marc Zyngier
committed
KVM: arm64: nv: Don't advance PC when pending an SVE exception
Jan reports that running a nested guest on Neoverse-V2 leads to a WARN in the host due to simultaneously pending an exception and PC increment after an access to ZCR_EL2. Returning true from a sysreg accessor is an indication that the sysreg instruction has been retired. Of course this isn't the case when we've pended a synchronous SVE exception for the guest. Fix the return value and let the exception propagate to the guest as usual. Reported-by: Jan Kotas <[email protected]> Closes: https://lore.kernel.org/kvmarm/[email protected]/ Signed-off-by: Oliver Upton <[email protected]> Signed-off-by: Marc Zyngier <[email protected]>
1 parent ed25dcf commit 9a1950f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/arm64/kvm/sys_regs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2704,7 +2704,7 @@ static bool access_zcr_el2(struct kvm_vcpu *vcpu,
27042704

27052705
if (guest_hyp_sve_traps_enabled(vcpu)) {
27062706
kvm_inject_nested_sve_trap(vcpu);
2707-
return true;
2707+
return false;
27082708
}
27092709

27102710
if (!p->is_write) {

0 commit comments

Comments
 (0)