Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932551AbWCGCNi (ORCPT ); Mon, 6 Mar 2006 21:13:38 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932610AbWCGCNh (ORCPT ); Mon, 6 Mar 2006 21:13:37 -0500 Received: from omega.webmasters.gr.jp ([218.44.239.78]:22657 "EHLO webmasters.gr.jp") by vger.kernel.org with ESMTP id S932551AbWCGCNh (ORCPT ); Mon, 6 Mar 2006 21:13:37 -0500 Date: Tue, 07 Mar 2006 11:13:22 +0900 Message-ID: <81irqrknnh.wl%gotom@sanori.org> From: GOTO Masanori To: linux-kernel@vger.kernel.org, akpm@osdl.org Cc: gotom@sanori.org Subject: [PATCH] x86: Fix i386 nmi_watchdog that does not trigger die_nmi User-Agent: Wanderlust/2.11.30 (Wonderwall) SEMI/1.14.6 (Maruoka) FLIM/1.14.6 (Marutamachi) APEL/10.6 Emacs/21.4 (i386-pc-linux-gnu) MULE/5.0 (SAKAKI) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1401 Lines: 38 It fixes i386 nmi_watchdog that does not meet watchdog timeout condition. It does not hit die_nmi when it should be triggered, because the current nmi_watchdog_tick in arch/i386/kernel/nmi.c never count up alert_counter like this: void nmi_watchdog_tick (struct pt_regs * regs) { if (last_irq_sums[cpu] == sum) { alert_counter[cpu]++; <- count up alert_counter, but if (alert_counter[cpu] == 5*nmi_hz) die_nmi(regs, "NMI Watchdog detected LOCKUP"); alert_counter[cpu] = 0; <- reset alert_counter This patch changes it back to the previous and working version. Tested with 2.6.15. It's also OK for 2.6.16-rc5. This was found and originally written by Kohta NAKASHIMA. -- gotom Signed-Off-By: GOTO Masanori --- --- linux-2.6.15/arch/i386/kernel/nmi.c.gotom 2006-03-02 17:52:49.021365056 +0900 +++ linux-2.6.15/arch/i386/kernel/nmi.c 2006-03-02 17:53:19.939664760 +0900 @@ -544,7 +544,7 @@ void nmi_watchdog_tick (struct pt_regs * * die_nmi will return ONLY if NOTIFY_STOP happens.. */ die_nmi(regs, "NMI Watchdog detected LOCKUP"); - + } else { last_irq_sums[cpu] = sum; alert_counter[cpu] = 0; } - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/