From patchwork Sun Dec 1 14:39:30 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Hurley X-Patchwork-Id: 295690 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 93AAC2C0092 for ; Mon, 2 Dec 2013 01:55:18 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751035Ab3LAOzG (ORCPT ); Sun, 1 Dec 2013 09:55:06 -0500 Received: from mailout02.c08.mtsvc.net ([205.186.168.190]:55137 "EHLO mailout02.c08.mtsvc.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751075Ab3LAOzF (ORCPT ); Sun, 1 Dec 2013 09:55:05 -0500 X-Greylist: delayed 914 seconds by postgrey-1.27 at vger.kernel.org; Sun, 01 Dec 2013 09:55:05 EST Received: from n18.c08.mtsvc.net ([205.186.176.18]) by mailout02.c08.mtsvc.net with esmtp (Exim 4.72) (envelope-from ) id 1Vn8BW-0000la-Qx; Sun, 01 Dec 2013 06:39:47 -0800 Received: from 68-184-16-174.dhcp.unas.ma.charter.com ([68.184.16.174]:56358 helo=thor.lan) by n18.c08.mtsvc.net with esmtpsa (TLS1.1:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.80.1) (envelope-from ) id 1Vn8BV-00065m-45; Sun, 01 Dec 2013 06:39:46 -0800 From: Peter Hurley To: Meelis Roos Cc: Greg Kroah-Hartman , David Miller , sparclinux@vger.kernel.org, Peter Hurley Subject: Re: RED state exception (trap type 0x64) on U5 reboot Date: Sun, 1 Dec 2013 09:39:30 -0500 Message-Id: <1385908770-14131-1-git-send-email-peter@hurleysoftware.com> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: References: X-Authenticated-User: 125194 peter@hurleysoftware.com X-Spam-Status: "score=-0.9 tests=ALL_TRUSTED, TVD_RCVD_IP version=3.3.1 cmae=v=2.1 cv=drviVTQ4 c=1 sm=0 tr=0 a=fi+bEUf2jW8nBMmSb+pBTg==:17 a=xxUMHBKTmZQA:10 a=lF0tP7JmhmIA:10 a=xGRsDScCAAAA:8 a=zFmFt3I4AAAA:8 a=IIQeXsxtAAAA:8 a=fMTZZcM98HQA:10 a=MVccjD2DAxBvecX--o8A:9 a=A4LuvFU5fKoA:10" X-Spam-Level: Sender: sparclinux-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: sparclinux@vger.kernel.org On 12/01/2013 03:16 AM, Meelis Roos wrote: >> On 11/30/2013 08:31 PM, Meelis Roos wrote: >>>> Does the RED state exception trigger if you manually break to the prom >>>> command line and issue a boot command? >>> >>> It seems I can not break from running kernel to PROM by sending break >>> from minicom. PROM itself reacts to my break (during memory test for >>> example) so it's Linux not accepting the break. I seem to remember it >>> having worked some time ago, although not when the kergel hung. >> >> Argghh. >> >> There were some changes to sunsab.c a couple of versions ago; maybe we >> broke it. >> >> Can you confirm BRKs are being received with >> 'sudo cat /proc/tty/driver/serial' > > In 3.12: > > # cat /proc/tty/driver/sunsab > serinfo:1.0 driver revision: > 0: uart:SAB82532 V3.2 mmio:0x1FFF1400000 irq:5 tx:5163 rx:0 CTS|DSR|CD > 1: uart:SAB82532 V3.2 mmio:0x1FFF1400040 irq:5 tx:0 rx: > > cat /proc/sys/kernel/stop-a > 1 > > # cat /proc/sys/kernel/reboot-cmd > > (it was empty, so default "boot" should be used AFAIK) Meelis, Would you please re-test trying to break to the PROM with this debug patch? As with the bootpromfs debug patch, the output is in '/sys/kernel/debug/trace'. Regards, Peter Hurley --- >% --- Subject: [PATCH] serial/sunsab: Debug BRKs Debug patch. Signed-off-by: Peter Hurley --- drivers/tty/serial/sunsab.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/tty/serial/sunsab.c b/drivers/tty/serial/sunsab.c index 5d6136b..1e7a17e 100644 --- a/drivers/tty/serial/sunsab.c +++ b/drivers/tty/serial/sunsab.c @@ -153,9 +153,12 @@ receive_chars(struct uart_sunsab_port *up, } /* Count may be zero for BRK, so we check for it here */ - if ((stat->sreg.isr1 & SAB82532_ISR1_BRK) && - (up->port.line == up->port.cons->index)) - saw_console_brk = 1; + if (stat->sreg.isr1 & SAB82532_ISR1_BRK) { + if (up->port.line == up->port.cons->index) + saw_console_brk = 1; + trace_printk("%d: console:%d count:%d port:%p\n", + up->port.line, up->port.cons->index, count, port); + } for (i = 0; i < count; i++) { unsigned char ch = buf[i], flag;