diff options
author | Ulrich Obergfell <uobergfe@redhat.com> | 2014-10-13 18:55:37 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-10-13 20:18:27 -0400 |
commit | 9919e39a17381058dd0cdef2f78dbf5619e26474 (patch) | |
tree | 9fddb1c5b884a6055ea8d28974acb67e07be1069 /arch/x86/kernel | |
parent | 6e7458a6f074c71e74cda31c483114e65ea0f570 (diff) |
kvm: ensure hard lockup detection is disabled by default
Use watchdog_enable_hardlockup_detector() to set hard lockup detection's
default value to false. It's risky to run this detection in a guest, as
false positives are easy to trigger, especially if the host is
overcommitted.
Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Signed-off-by: Andrew Jones <drjones@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r-- | arch/x86/kernel/kvm.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c index 3dd8e2c4d74a..95c3cb16af3e 100644 --- a/arch/x86/kernel/kvm.c +++ b/arch/x86/kernel/kvm.c | |||
@@ -35,6 +35,7 @@ | |||
35 | #include <linux/slab.h> | 35 | #include <linux/slab.h> |
36 | #include <linux/kprobes.h> | 36 | #include <linux/kprobes.h> |
37 | #include <linux/debugfs.h> | 37 | #include <linux/debugfs.h> |
38 | #include <linux/nmi.h> | ||
38 | #include <asm/timer.h> | 39 | #include <asm/timer.h> |
39 | #include <asm/cpu.h> | 40 | #include <asm/cpu.h> |
40 | #include <asm/traps.h> | 41 | #include <asm/traps.h> |
@@ -499,6 +500,13 @@ void __init kvm_guest_init(void) | |||
499 | #else | 500 | #else |
500 | kvm_guest_cpu_init(); | 501 | kvm_guest_cpu_init(); |
501 | #endif | 502 | #endif |
503 | |||
504 | /* | ||
505 | * Hard lockup detection is enabled by default. Disable it, as guests | ||
506 | * can get false positives too easily, for example if the host is | ||
507 | * overcommitted. | ||
508 | */ | ||
509 | watchdog_enable_hardlockup_detector(false); | ||
502 | } | 510 | } |
503 | 511 | ||
504 | static noinline uint32_t __kvm_cpuid_base(void) | 512 | static noinline uint32_t __kvm_cpuid_base(void) |