• Jim Mattson's avatar
    kvm: vmx: Do not disable intercepts for BNDCFGS · a8b6fda3
    Jim Mattson authored
    The MSR permission bitmaps are shared by all VMs. However, some VMs
    may not be configured to support MPX, even when the host does. If the
    host supports VMX and the guest does not, we should intercept accesses
    to the BNDCFGS MSR, so that we can synthesize a #GP
    fault. Furthermore, if the host does not support MPX and the
    "ignore_msrs" kvm kernel parameter is set, then we should intercept
    accesses to the BNDCFGS MSR, so that we can skip over the rdmsr/wrmsr
    without raising a #GP fault.
    
    Fixes: da8999d3 ("KVM: x86: Intel MPX vmx and msr handle")
    Signed-off-by: default avatarJim Mattson <jmattson@google.com>
    Signed-off-by: default avatarRadim Krčmář <rkrcmar@redhat.com>
    a8b6fda3
vmx.c 329 KB