#include <linux/smpboot.h>
#include <linux/sched/rt.h>
#include <linux/tick.h>
+#include <linux/dmi.h>
#include <asm/irq_regs.h>
#include <linux/kvm_para.h>
__setup("softlockup_all_cpu_backtrace=", softlockup_all_cpu_backtrace_setup);
#endif
+static int disable_watchdog(const struct dmi_system_id *d)
+{
+ printk(KERN_INFO "watchdog: disabled (inside virtual machine)\n");
+ watchdog_user_enabled = 0;
+ return 0;
+}
+
+static const struct dmi_system_id watchdog_virt_dmi_table[] = {
+ {
+ .callback = disable_watchdog,
+ .ident = "VMware",
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "VMware, Inc."),
+ },
+ },
+ {
+ .callback = disable_watchdog,
+ .ident = "Bochs",
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "Bochs"),
+ },
+ },
+ {}
+};
+
+
/*
* Hard-lockup warnings should be triggered after just a few seconds. Soft-
* lockups can have false positives under extreme conditions. So we generally
void __init lockup_detector_init(void)
{
+ dmi_check_system(watchdog_virt_dmi_table);
+
set_sample_period();
#ifdef CONFIG_NO_HZ_FULL