From patchwork Fri Jul 11 12:30:11 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Thompson X-Patchwork-Id: 33488 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ie0-f198.google.com (mail-ie0-f198.google.com [209.85.223.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id B81B12113E for ; Fri, 11 Jul 2014 12:34:44 +0000 (UTC) Received: by mail-ie0-f198.google.com with SMTP id lx4sf5147551iec.5 for ; Fri, 11 Jul 2014 05:34:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=+xiZvBpzK1rJhHju2SFNlmqVrCKjkC01LSoBmmeUefs=; b=DNwhJf7AtvVeiDlnglkUvoxFs0vaOfYF0lYZBdSop2LsBM47LUtyNfesjKIy8Bdkp2 wO4B1GwQSzaQ4I2fLx5vLTJQ/alByfdf1mAPvXpFxfes9f5m/3k0PbXvRs0HjVhj/n6j NU18hCvYE3KUDzyv1cxq52bigWuTGVUjk0r09urCvfm2VONG1uMOrzEBOt08RpADu2ib yLdvRO01NdUBd5pv3Dho5l+PzJV4ps4Tm4/6acs8iRV7udJy8uWt0lX/DVvUFHVWDg+M SkoUEB/s4xNbT33mKb+u5RwZ40IRMDW6um1qFerZgOu3m1vmfbqSAofXpEkJMcM1OcTw OdQQ== X-Gm-Message-State: ALoCoQlDXUEmM4+oEXe3b5puVW2W6Yvn3JTYuxFP0bcNNPPn+u7n542k/o37g2YXX9vTr8ExBfRI X-Received: by 10.182.213.135 with SMTP id ns7mr24123370obc.46.1405082084280; Fri, 11 Jul 2014 05:34:44 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.21.35 with SMTP id 32ls180538qgk.13.gmail; Fri, 11 Jul 2014 05:34:44 -0700 (PDT) X-Received: by 10.220.162.74 with SMTP id u10mr6544677vcx.32.1405082084201; Fri, 11 Jul 2014 05:34:44 -0700 (PDT) Received: from mail-vc0-f178.google.com (mail-vc0-f178.google.com [209.85.220.178]) by mx.google.com with ESMTPS id ah1si1429351vec.13.2014.07.11.05.34.44 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Jul 2014 05:34:44 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.178 as permitted sender) client-ip=209.85.220.178; Received: by mail-vc0-f178.google.com with SMTP id ij19so1857607vcb.37 for ; Fri, 11 Jul 2014 05:34:44 -0700 (PDT) X-Received: by 10.58.227.229 with SMTP id sd5mr3193494vec.15.1405082084107; Fri, 11 Jul 2014 05:34:44 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp31483vcb; Fri, 11 Jul 2014 05:34:43 -0700 (PDT) X-Received: by 10.66.237.39 with SMTP id uz7mr1814999pac.144.1405082082085; Fri, 11 Jul 2014 05:34:42 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id kn9si2302350pbc.239.2014.07.11.05.34.41; Fri, 11 Jul 2014 05:34:41 -0700 (PDT) Received-SPF: none (google.com: linux-serial-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753111AbaGKMel (ORCPT + 1 other); Fri, 11 Jul 2014 08:34:41 -0400 Received: from mail-we0-f171.google.com ([74.125.82.171]:47050 "EHLO mail-we0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752863AbaGKMek (ORCPT ); Fri, 11 Jul 2014 08:34:40 -0400 Received: by mail-we0-f171.google.com with SMTP id q58so1019932wes.30 for ; Fri, 11 Jul 2014 05:34:39 -0700 (PDT) X-Received: by 10.180.35.34 with SMTP id e2mr4942823wij.12.1405082078179; Fri, 11 Jul 2014 05:34:38 -0700 (PDT) Received: from harvey.bri.st.com (LPuteaux-656-01-48-212.w82-127.abo.wanadoo.fr. [82.127.83.212]) by mx.google.com with ESMTPSA id w5sm7055745wif.3.2014.07.11.05.34.36 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 11 Jul 2014 05:34:37 -0700 (PDT) From: Daniel Thompson To: Greg Kroah-Hartman Cc: Daniel Thompson , linux-kernel@vger.kernel.org, patches@linaro.org, linaro-kernel@lists.linaro.org, Jiri Slaby , linux-serial@vger.kernel.org Subject: [PATCH] tty: kgdb_nmi: Convert kgdb_nmi_tty_enabled into a module parameter Date: Fri, 11 Jul 2014 13:30:11 +0100 Message-Id: <1405081811-15254-1-git-send-email-daniel.thompson@linaro.org> X-Mailer: git-send-email 1.9.3 Sender: linux-serial-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-serial@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: daniel.thompson@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.178 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , At present it is not possible to boot with the ttyNMI0 console treating character input normally. To use the console requires that kdb be entered and the nmi_console command be used to enable the console (or if only kgdb is present then gdb must directly manipulate the value of kgdb_nmi_tty_enabled). Introducing a module parameter makes the console much more usable. Signed-off-by: Daniel Thompson Cc: Greg Kroah-Hartman Cc: Jiri Slaby Cc: linux-serial@vger.kernel.org --- drivers/tty/serial/kgdb_nmi.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/tty/serial/kgdb_nmi.c b/drivers/tty/serial/kgdb_nmi.c index cfadf29..9361d69 100644 --- a/drivers/tty/serial/kgdb_nmi.c +++ b/drivers/tty/serial/kgdb_nmi.c @@ -43,6 +43,11 @@ module_param_named(magic, kgdb_nmi_magic, charp, 0600); MODULE_PARM_DESC(magic, "magic sequence to enter NMI debugger (default $3#33)"); static bool kgdb_nmi_tty_enabled; +module_param_named(tty, kgdb_nmi_tty_enabled, bool, 0600); +MODULE_PARM_DESC(tty, "if set to false (default), characters received from " + "the UART will be passed exclusively to the knock " + "detector; when set to true characters will be passed " + "both to the knock detector and to the TTY layer"); static int kgdb_nmi_console_setup(struct console *co, char *options) {