summaryrefslogtreecommitdiff
path: root/kernel/watchdog.c
diff options
context:
space:
mode:
authorLaurence Oberman <loberman@redhat.com>2018-11-01 09:30:18 -0400
committerThomas Gleixner <tglx@linutronix.de>2018-11-01 14:33:35 +0100
commit11295055526308ee71d82dc97f0a9ca2dd61c3b9 (patch)
treecf2489649e89da0c9a097b041fa4a6e278a9fe23 /kernel/watchdog.c
parent5b7449810ae6d652629c550d3974c8453836d229 (diff)
watchdog/core: Add watchdog_thresh command line parameter
The hard and soft lockup detector threshold has a default value of 10 seconds which can only be changed via sysctl. During early boot lockup detection can trigger when noisy debugging emits a large amount of messages to the console, but there is no way to set a larger threshold on the kernel command line. The detector can only be completely disabled. Add a new watchdog_thresh= command line parameter to allow boot time control over the threshold. It works in the same way as the sysctl and affects both the soft and the hard lockup detectors. Signed-off-by: Laurence Oberman <loberman@redhat.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: rdunlap@infradead.org Cc: prarit@redhat.com Link: https://lkml.kernel.org/r/1541079018-13953-1-git-send-email-loberman@redhat.com
Diffstat (limited to 'kernel/watchdog.c')
-rw-r--r--kernel/watchdog.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/kernel/watchdog.c b/kernel/watchdog.c
index 977918d5d350..8fbfda94a67b 100644
--- a/kernel/watchdog.c
+++ b/kernel/watchdog.c
@@ -199,6 +199,13 @@ static int __init nosoftlockup_setup(char *str)
}
__setup("nosoftlockup", nosoftlockup_setup);
+static int __init watchdog_thresh_setup(char *str)
+{
+ get_option(&str, &watchdog_thresh);
+ return 1;
+}
+__setup("watchdog_thresh=", watchdog_thresh_setup);
+
#ifdef CONFIG_SMP
int __read_mostly sysctl_softlockup_all_cpu_backtrace;