KVM: x86: Improve thread safety in pit
authorAndy Honig <[email protected]>
Wed, 27 Aug 2014 21:42:54 +0000 (14:42 -0700)
committerPaolo Bonzini <[email protected]>
Fri, 24 Oct 2014 11:21:14 +0000 (13:21 +0200)
commit2febc839133280d5a5e8e1179c94ea674489dae2
tree4c3f4f0ab1273a88cd7edf639c944ad4212a13c0
parent8b3c3104c3f4f706e99365c3e0d2aa61b95f969f
KVM: x86: Improve thread safety in pit

There's a race condition in the PIT emulation code in KVM.  In
__kvm_migrate_pit_timer the pit_timer object is accessed without
synchronization.  If the race condition occurs at the wrong time this
can crash the host kernel.

This fixes CVE-2014-3611.

Cc: [email protected]
Signed-off-by: Andrew Honig <[email protected]>
Signed-off-by: Paolo Bonzini <[email protected]>
arch/x86/kvm/i8254.c