KVM: x86: MOV to CR3 can set bit 63
authorNadav Amit <namit@cs.technion.ac.il>
Sun, 2 Nov 2014 09:54:52 +0000 (11:54 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 7 Nov 2014 14:44:07 +0000 (15:44 +0100)
commit9d88fca71a99a65c37cbfe481b4aa4e91a27ff13
tree9e698aa68ff7b8cbabcdcda3b3d1ac46d86636b3
parent0fcc207c66a7cff024b05367b86d70d742072d61
KVM: x86: MOV to CR3 can set bit 63

Although Intel SDM mentions bit 63 is reserved, MOV to CR3 can have bit 63 set.
As Intel SDM states in section 4.10.4 "Invalidation of TLBs and
Paging-Structure Caches": " MOV to CR3. ... If CR4.PCIDE = 1 and bit 63 of the
instruction’s source operand is 0 ..."

In other words, bit 63 is not reserved. KVM emulator currently consider bit 63
as reserved. Fix it.

Signed-off-by: Nadav Amit <namit@cs.technion.ac.il>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/emulate.c
arch/x86/kvm/x86.c