Skip to content
Commit ea25ace7 authored by Vishal Annapurve's avatar Vishal Annapurve Committed by Sean Christopherson
Browse files

KVM: selftests: x86: Use host's native hypercall instruction in kvm_hypercall()



Use the host CPU's native hypercall instruction, i.e. VMCALL vs. VMMCALL,
in kvm_hypercall(), as relying on KVM to patch in the native hypercall on
a #UD for the "wrong" hypercall requires KVM_X86_QUIRK_FIX_HYPERCALL_INSN
to be enabled and flat out doesn't work if guest memory is encrypted with
a private key, e.g. for SEV VMs.

Suggested-by: default avatarSean Christopherson <seanjc@google.com>
Reviewed-by: default avatarDavid Matlack <dmatlack@google.com>
Signed-off-by: default avatarVishal Annapurve <vannapurve@google.com>
Link: https://lore.kernel.org/r/20230111004445.416840-4-vannapurve@google.com


Signed-off-by: default avatarSean Christopherson <seanjc@google.com>
parent e6df2ae3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment