KVM: x86: emulating RDPID failure shall return #UD rather than #GP
authorRobert Hoo <robert.hu@linux.intel.com>
Fri, 28 Aug 2020 02:23:42 +0000 (10:23 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Mon, 28 Sep 2020 11:57:22 +0000 (07:57 -0400)
commita9e2e0ae686094571378c72d8146b5a1a92d0652
treeb9db31fe237e8cf29f9bcde3d7edafaf3e694a9c
parent25bb2cf97139f81e3bb8910d26016a529019528e
KVM: x86: emulating RDPID failure shall return #UD rather than #GP

Per Intel's SDM, RDPID takes a #UD if it is unsupported, which is more or
less what KVM is emulating when MSR_TSC_AUX is not available.  In fact,
there are no scenarios in which RDPID is supposed to #GP.

Fixes: fb6d4d340e ("KVM: x86: emulate RDPID")
Signed-off-by: Robert Hoo <robert.hu@linux.intel.com>
Message-Id: <1598581422-76264-1-git-send-email-robert.hu@linux.intel.com>
Reviewed-by: Jim Mattson <jmattson@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/emulate.c