|
@@ -37,6 +37,7 @@
|
|
#include <linux/memblock.h>
|
|
#include <linux/memblock.h>
|
|
#include <linux/hugetlb.h>
|
|
#include <linux/hugetlb.h>
|
|
#include <linux/memory.h>
|
|
#include <linux/memory.h>
|
|
|
|
+#include <linux/nmi.h>
|
|
|
|
|
|
#include <asm/io.h>
|
|
#include <asm/io.h>
|
|
#include <asm/kdump.h>
|
|
#include <asm/kdump.h>
|
|
@@ -779,3 +780,22 @@ unsigned long memory_block_size_bytes(void)
|
|
struct ppc_pci_io ppc_pci_io;
|
|
struct ppc_pci_io ppc_pci_io;
|
|
EXPORT_SYMBOL(ppc_pci_io);
|
|
EXPORT_SYMBOL(ppc_pci_io);
|
|
#endif
|
|
#endif
|
|
|
|
+
|
|
|
|
+#ifdef CONFIG_HARDLOCKUP_DETECTOR
|
|
|
|
+u64 hw_nmi_get_sample_period(int watchdog_thresh)
|
|
|
|
+{
|
|
|
|
+ return ppc_proc_freq * watchdog_thresh;
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+/*
|
|
|
|
+ * The hardlockup detector breaks PMU event based branches and is likely
|
|
|
|
+ * to get false positives in KVM guests, so disable it by default.
|
|
|
|
+ */
|
|
|
|
+static int __init disable_hardlockup_detector(void)
|
|
|
|
+{
|
|
|
|
+ watchdog_enable_hardlockup_detector(false);
|
|
|
|
+
|
|
|
|
+ return 0;
|
|
|
|
+}
|
|
|
|
+early_initcall(disable_hardlockup_detector);
|
|
|
|
+#endif
|