android_kernel_samsung_msm8976/arch
Marcelo Tosatti 73c1d981f0 KVM: x86: move steal time initialization to vcpu entry time
commit 7cae2bedcbd4680b155999655e49c27b9cf020fa upstream.

As reported at https://bugs.launchpad.net/qemu/+bug/1494350,
it is possible to have vcpu->arch.st.last_steal initialized
from a thread other than vcpu thread, say the iothread, via
KVM_SET_MSRS.

Which can cause an overflow later (when subtracting from vcpu threads
sched_info.run_delay).

To avoid that, move steal time accumulation to vcpu entry time,
before copying steal time data to guest.

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Reviewed-by: David Matlack <dmatlack@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-03-16 08:41:36 -07:00
..
alpha vm: add VM_FAULT_SIGSEGV handling support 2015-04-29 10:34:00 +02:00
arc ARC: dw2 unwind: Remove falllback linear search thru FDE entries 2016-03-03 15:06:21 -08:00
arm ARM: 8517/1: ICST: avoid arithmetic overflow in icst_hz() 2016-02-25 11:57:48 -08:00
arm64 arm64: mm: ensure that the zero page is visible to the page table walker 2016-01-28 21:49:36 -08:00
avr32 vm: add VM_FAULT_SIGSEGV handling support 2015-04-29 10:34:00 +02:00
blackfin
c6x C6x: time: Ensure consistency in __init 2015-05-06 21:56:28 +02:00
cris vm: add VM_FAULT_SIGSEGV handling support 2015-04-29 10:34:00 +02:00
frv vm: add VM_FAULT_SIGSEGV handling support 2015-04-29 10:34:00 +02:00
h8300
hexagon arch: mm: pass userspace fault flag to generic fault handler 2014-11-21 09:22:56 -08:00
ia64 vm: add VM_FAULT_SIGSEGV handling support 2015-04-29 10:34:00 +02:00
m32r m32r: fix m32104ut_defconfig build fail 2016-02-25 11:57:49 -08:00
m68k m68k/uaccess: Fix asm constraints for userspace access 2015-10-27 09:44:49 +09:00
metag vm: add VM_FAULT_SIGSEGV handling support 2015-04-29 10:34:00 +02:00
microblaze vm: add VM_FAULT_SIGSEGV handling support 2015-04-29 10:34:00 +02:00
mips MIPS: KVM: Uninit VCPU in vcpu_create error path 2016-03-03 15:06:20 -08:00
mn10300 mn10300: Select CONFIG_HAVE_UID16 to fix build failure 2016-01-28 21:49:37 -08:00
openrisc openrisc: fix CONFIG_UID16 setting 2016-01-28 21:49:36 -08:00
parisc parisc: Fix __ARCH_SI_PREAMBLE_SIZE 2016-02-19 14:22:38 -08:00
powerpc powerpc: Fix dedotify for binutils >= 2.26 2016-03-16 08:41:36 -07:00
s390 s390: fix normalization bug in exception table sorting 2016-03-03 15:06:22 -08:00
score vm: add VM_FAULT_SIGSEGV handling support 2015-04-29 10:34:00 +02:00
sh sh64: fix __NR_fgetxattr 2016-02-19 14:22:38 -08:00
sparc sparc64: fix incorrect sign extension in sys_sparc64_personality 2016-03-03 15:06:23 -08:00
tile tile: use free_bootmem_late() for initrd 2015-08-10 12:20:30 -07:00
um uml: flush stdout before forking 2016-03-03 15:06:23 -08:00
unicore32 nosave: consolidate __nosave_{begin,end} in <asm/sections.h> 2015-05-06 21:56:28 +02:00
x86 KVM: x86: move steal time initialization to vcpu entry time 2016-03-16 08:41:36 -07:00
xtensa xtensa: don't use echo -e needlessly 2015-09-21 10:00:10 -07:00
.gitignore
Kconfig