public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: tip-bot for Li Zefan <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, hpa@zytor.com, mingo@kernel.org,
	tglx@linutronix.de, dzickus@redhat.com, lizefan@huawei.com
Subject: [tip:perf/core] watchdog: Disallow setting watchdog_thresh to -1
Date: Tue, 28 May 2013 06:30:57 -0700	[thread overview]
Message-ID: <tip-a6572f84c5b135d9b6df279ed3c8de028bd1edd9@git.kernel.org> (raw)
In-Reply-To: <51959668.9040106@huawei.com>

Commit-ID:  a6572f84c5b135d9b6df279ed3c8de028bd1edd9
Gitweb:     http://git.kernel.org/tip/a6572f84c5b135d9b6df279ed3c8de028bd1edd9
Author:     Li Zefan <lizefan@huawei.com>
AuthorDate: Fri, 17 May 2013 10:31:04 +0800
Committer:  Ingo Molnar <mingo@kernel.org>
CommitDate: Tue, 28 May 2013 11:28:18 +0200

watchdog: Disallow setting watchdog_thresh to -1

In old kernels, it's allowed to set softlockup_thresh to -1 or 0
to disable softlockup detection. However watchdog_thresh only
uses 0 to disable detection, and setting it to -1 just froze my
box and nothing I can do but reboot.

Signed-off-by: Li Zefan <lizefan@huawei.com>
Acked-by: Don Zickus <dzickus@redhat.com>
Link: http://lkml.kernel.org/r/51959668.9040106@huawei.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
 kernel/sysctl.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/kernel/sysctl.c b/kernel/sysctl.c
index 9edcf45..b0a1f99 100644
--- a/kernel/sysctl.c
+++ b/kernel/sysctl.c
@@ -120,7 +120,6 @@ extern int blk_iopoll_enabled;
 /* Constants used for minimum and  maximum */
 #ifdef CONFIG_LOCKUP_DETECTOR
 static int sixty = 60;
-static int neg_one = -1;
 #endif
 
 static int zero;
@@ -814,7 +813,7 @@ static struct ctl_table kern_table[] = {
 		.maxlen		= sizeof(int),
 		.mode		= 0644,
 		.proc_handler	= proc_dowatchdog,
-		.extra1		= &neg_one,
+		.extra1		= &zero,
 		.extra2		= &sixty,
 	},
 	{

      parent reply	other threads:[~2013-05-28 13:32 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-17  2:31 [PATCH 1/3] watchdog: Disallow setting watchdog_thresh to -1 Li Zefan
2013-05-17  2:31 ` [PATCH 2/3] watchdog: Document watchdog_thresh sysctl Li Zefan
2013-05-17 13:07   ` Don Zickus
2013-05-28 13:32   ` [tip:perf/core] " tip-bot for Li Zefan
2013-05-17  2:31 ` [PATCH 3/3] watchdog: Remove softlockup_thresh from Documentation Li Zefan
2013-05-17 13:07   ` Don Zickus
2013-05-28 13:33   ` [tip:perf/core] " tip-bot for Li Zefan
2013-05-17 13:06 ` [PATCH 1/3] watchdog: Disallow setting watchdog_thresh to -1 Don Zickus
2013-05-28 13:30 ` tip-bot for Li Zefan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=tip-a6572f84c5b135d9b6df279ed3c8de028bd1edd9@git.kernel.org \
    --to=tipbot@zytor.com \
    --cc=dzickus@redhat.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=lizefan@huawei.com \
    --cc=mingo@kernel.org \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox