]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86: Reload pit counters for all channels when restoring state
authorAndrew Honig <ahonig@google.com>
Wed, 18 Nov 2015 22:50:23 +0000 (14:50 -0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Tue, 22 Dec 2015 14:36:26 +0000 (15:36 +0100)
commit7c9670a5d10bceda4e54663dbd89d5b0042f26ad
tree227382c16c0ce92f1912892e159f6aa770235f3a
parentf8a0dc02e4e7db310ad5bc79900a2cc271cb9aaf
KVM: x86: Reload pit counters for all channels when restoring state

Currently if userspace restores the pit counters with a count of 0
on channels 1 or 2 and the guest attempts to read the count on those
channels, then KVM will perform a mod of 0 and crash.  This will ensure
that 0 values are converted to 65536 as per the spec.

This is CVE-2015-7513.

Signed-off-by: Andy Honig <ahonig@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/x86.c