From patchwork Tue Aug 29 09:14:20 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jose Abreu X-Patchwork-Id: 807007 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=65.50.211.133; helo=bombadil.infradead.org; envelope-from=linux-snps-arc-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="b+cvZHMD"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3xhNJk71h2z9t2v for ; Tue, 29 Aug 2017 19:15:18 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=ty4NQ6lKUaqelJ0xRmUFTPti5kxHlSNNbtm3oPwgDDM=; b=b+c vZHMDI31yaAew71fB/RxSnTFhto8CqquyqLbltPLyiyF4qBnCkY6UTir9ABcWpz1JyL+qzBJ8jNJ4 vjeu6+ySvhCgUWyzLsPH4f97t8K/bg6UkW1Gx6z22oH0IdxL3q5wTlKpKcU8CdrzCkz+XGDXDvCUD GtJcTQUv6XBgFc2gPe3j8V4Bmsp0T5RJggDTfNtFpet1kQMOrj22SskZ8j+DGpGqrKbql9Z2U0L6y gG2eHA0jAJa8YSbTURI+nH2cGH2awb383w5glC5WoMr9TBtM9Aw+UG5+TVC2mjLoF0WZmzQ0wJJ7o vaneRL/L+MXboiBotzLXqVxyk2io6Jw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dmcc9-00030b-3r; Tue, 29 Aug 2017 09:15:17 +0000 Received: from smtprelay.synopsys.com ([198.182.60.111]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dmcbs-0001c9-Si for linux-snps-arc@lists.infradead.org; Tue, 29 Aug 2017 09:15:14 +0000 Received: from mailhost.synopsys.com (mailhost1.synopsys.com [10.12.238.239]) by smtprelay.synopsys.com (Postfix) with ESMTP id E649C10C0F28 for ; Tue, 29 Aug 2017 02:14:38 -0700 (PDT) Received: from mailhost.synopsys.com (localhost [127.0.0.1]) by mailhost.synopsys.com (Postfix) with ESMTP id CDF4EBCB; Tue, 29 Aug 2017 02:14:38 -0700 (PDT) Received: from joabreu-VirtualBox.internal.synopsys.com (joabreu-e7440.internal.synopsys.com [10.107.19.73]) by mailhost.synopsys.com (Postfix) with ESMTP id AFF92BB5; Tue, 29 Aug 2017 02:14:37 -0700 (PDT) From: Jose Abreu To: linux-snps-arc@lists.infradead.org Subject: [PATCH] arc: Show fault information passed to show_kernel_fault_diag() Date: Tue, 29 Aug 2017 10:14:20 +0100 Message-Id: X-Mailer: git-send-email 1.9.1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170829_021501_618635_0D59ABED X-CRM114-Status: UNSURE ( 6.43 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -1.9 (-) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-1.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [198.182.60.111 listed in list.dnswl.org] -0.0 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-BeenThere: linux-snps-arc@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Linux on Synopsys ARC Processors List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jose Abreu , Vineet Gupta , Alexey Brodkin MIME-Version: 1.0 Sender: "linux-snps-arc" Errors-To: linux-snps-arc-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org Currently we pass a string argument to show_kernel_fault_diag() which describes the reason for the fault. This is not being used so just add a pr_info() which outputs the fault information. With this change we get from: -------------------------- Path: /bin/busybox CPU: 0 PID: 92 Comm: modprobe Not tainted 4.12.0-rc6 #30 task: 9a254780 task.stack: 9a212000 [ECR ]: 0x00200400 => Other Fatal Err -------------------------- to: -------------------------- Machine Check Exception Path: /bin/busybox CPU: 0 PID: 92 Comm: modprobe Not tainted 4.12.0-rc6 #37 task: 9a240780 task.stack: 9a226000 [ECR ]: 0x00200400 => Other Fatal Err -------------------------- Which can help debugging. Signed-off-by: Jose Abreu Cc: Vineet Gupta Cc: Alexey Brodkin --- arch/arc/kernel/troubleshoot.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arc/kernel/troubleshoot.c b/arch/arc/kernel/troubleshoot.c index f9caf79..03f0654 100644 --- a/arch/arc/kernel/troubleshoot.c +++ b/arch/arc/kernel/troubleshoot.c @@ -233,6 +233,9 @@ void show_kernel_fault_diag(const char *str, struct pt_regs *regs, { current->thread.fault_address = address; + /* Show fault description */ + pr_info("\n%s\n", str); + /* Caller and Callee regs */ show_regs(regs);