KVM: x86: Mask off reserved bits in CPUID.80000001H
authorJim Mattson <jmattson@google.com>
Thu, 29 Sep 2022 22:51:58 +0000 (00:51 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Sat, 22 Oct 2022 11:54:35 +0000 (07:54 -0400)
commit0469e56a14bf8cfb80507e51b7aeec0332cdbc13
tree37320d4565fcb1a35b3633228359d21f6e8db97d
parent9aec606c1609a5da177b579475a73f6c948e034a
KVM: x86: Mask off reserved bits in CPUID.80000001H

KVM_GET_SUPPORTED_CPUID should only enumerate features that KVM
actually supports. CPUID.80000001:EBX[27:16] are reserved bits and
should be masked off.

Fixes: 0771671749b5 ("KVM: Enhance guest cpuid management")
Signed-off-by: Jim Mattson <jmattson@google.com>
Cc: stable@vger.kernel.org
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/cpuid.c