]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86: PREFETCH and HINT_NOP should have SrcMem flag
authorNadav Amit <namit@cs.technion.ac.il>
Mon, 13 Oct 2014 10:04:14 +0000 (13:04 +0300)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 24 Oct 2014 11:30:36 +0000 (13:30 +0200)
commit473d442d374c1335afe7f89d43c866ca2b800fb0
tree988959255d9ac2f34c7fbc95af889f31ee4ef9d0
parent1552b800d5272c6ec9966b09259c98a03d28ed4f
KVM: x86: PREFETCH and HINT_NOP should have SrcMem flag

The decode phase of the x86 emulator assumes that every instruction with the
ModRM flag, and which can be used with RIP-relative addressing, has either
SrcMem or DstMem.  This is not the case for several instructions - prefetch,
hint-nop and clflush.

Adding SrcMem|NoAccess for prefetch and hint-nop and SrcMem for clflush.

This fixes CVE-2014-8480.

Fixes: 4f5ee7780a8e229349a8b9366434959f76cbf56c
Cc: stable@vger.kernel.org
Signed-off-by: Nadav Amit <namit@cs.technion.ac.il>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/emulate.c