Received: by 2002:ac0:aa62:0:0:0:0:0 with SMTP id w31-v6csp834740ima; Wed, 24 Oct 2018 09:54:28 -0700 (PDT) X-Google-Smtp-Source: AJdET5caYwMuhQMQJ/s7PzIXWrBiZ0TbfwfA/MLqe553JjtRKA3sK4RHxYOJzFIJ+3dE2j+7cWnd X-Received: by 2002:a62:7d81:: with SMTP id y123-v6mr1417036pfc.245.1540400068293; Wed, 24 Oct 2018 09:54:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540400068; cv=none; d=google.com; s=arc-20160816; b=C26FVdmZx9izBJveFjPaucjPrlP/BTMowDkqwYgEbvpgcJpKKk1vXZ9/5Fkz1DwNn3 WfngUXVg6o+++/AXmKJ0pFsW7eRYE+x97I1SY6+gB+OIqEncj0WmBPJ944qeYtcO5RBO Z9msxONucYJbkHdjlLYX1vrxTaIfwBO56SWzgdGMnnmXt3by7OrtOagion+H1ULtraYu 2x5go5YOJe8x5/DF8uvwxvBr7QahpfCFFOqIro5XVTbR9hiYxuXijV3vsmBYLsCGbi7+ s52nYwNGEnoAm5GoVzr7AmnZ/8CoC4ZFe9vNVlXrv/00vjjI5zQayA7iC6x5z/PDqpM9 ED6A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=hjyFlFl9nu9gz3uc74GRc+XWm6Ople/bHld3gtLgfTY=; b=ulkmnABjD75gEmkww4tH1LGQ2BjDDCQ4SsR/o6kqnO/HS9D1tp4ULHjg7I6P2uYKz8 ejV4lbF77KWZPCbEzZjTk/WJ7aDKdUvr2Fdhn0CzGJvwsQCVq9XH/XZSKZlKTLjP9Vi0 C3qdoBzjYcYvE43Flk63qlyHO+239Ld9A12fuKYHd22vjKzTax9ldV4S2h/fRAKHbex7 whqFaub99iNKWX6oJdL60gxJqMxrQZFEAHkxWBZc0Rw7uEFKZHpFapO2A+wG8OeYFMzo iNTjJG4FkHM3luh8yJ8YmYOiUX1N3Aen33NwnBRmefUYRElevSF0hJcTlOCH+m1qmqxi hsiQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h17-v6si4925532plr.343.2018.10.24.09.54.12; Wed, 24 Oct 2018 09:54:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727555AbeJYBWS (ORCPT + 99 others); Wed, 24 Oct 2018 21:22:18 -0400 Received: from mx1.redhat.com ([209.132.183.28]:48159 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727535AbeJYBWS (ORCPT ); Wed, 24 Oct 2018 21:22:18 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 75AE330F8BEA; Wed, 24 Oct 2018 16:53:29 +0000 (UTC) Received: from loberhel74.redhat.com (ovpn-121-56.rdu2.redhat.com [10.10.121.56]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0D7EB79806; Wed, 24 Oct 2018 16:53:25 +0000 (UTC) From: Laurence Oberman To: linux-kernel@vger.kernel.org, loberman@redhat.com Cc: rdunlap@infradead.org, tglx@linutronix.de Subject: [PATCH] V3 init/main.c Enable watchdog_thresh control from kernel line Date: Wed, 24 Oct 2018 12:53:12 -0400 Message-Id: <1540399992-23448-1-git-send-email-loberman@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.46]); Wed, 24 Oct 2018 16:53:29 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Both graphics and serial consoles are exposed to hard lockups when handling a large amount of messaging. The kernel watchdog_thresh parameter up to now has not been available to be set on the kernel line for early boot. This patch allows the setting of watchdog_thresh to be increased when needed to avoid the hard lockups in the console code. Signed-off-by: Laurence Oberman --- Documentation/admin-guide/kernel-parameters.txt | 8 ++++++++ init/main.c | 9 +++++++++ 2 files changed, 17 insertions(+) diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt index 4cdcd1a..cd8d588 100644 --- a/Documentation/admin-guide/kernel-parameters.txt +++ b/Documentation/admin-guide/kernel-parameters.txt @@ -4932,6 +4932,14 @@ or other driver-specific files in the Documentation/watchdog/ directory. + watchdog_thresh= + This parameter is now available as a kernel line + parameter. Use watchdog_thresh=30 as example + This will allow early boot changes of the current + default of 10s to be increased when needed to + avoid hard lockups. + Default: 10 + workqueue.watchdog_thresh= If CONFIG_WQ_WATCHDOG is configured, workqueue can warn stall conditions and dump internal state to diff --git a/init/main.c b/init/main.c index 1c3f902..88cbed9 100644 --- a/init/main.c +++ b/init/main.c @@ -1038,6 +1038,15 @@ static int __init set_debug_rodata(char *str) __setup("rodata=", set_debug_rodata); #endif +static int __init +is_watchdog_thresh_setup(char *str) +{ + get_option(&str, &watchdog_thresh); + return 1; +} +__setup("watchdog_thresh=", is_watchdog_thresh_setup); + + #ifdef CONFIG_STRICT_KERNEL_RWX static void mark_readonly(void) { -- 1.8.3.1