Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932754AbcDNPTk (ORCPT ); Thu, 14 Apr 2016 11:19:40 -0400 Received: from mx1.redhat.com ([209.132.183.28]:35153 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752827AbcDNPTi (ORCPT ); Thu, 14 Apr 2016 11:19:38 -0400 Date: Thu, 14 Apr 2016 16:19:33 +0100 From: Aaron Tomlin To: Chris Metcalf Cc: Peter Zijlstra , "Rafael J. Wysocki" , Petr Mladek , Russell King , Thomas Gleixner , Ingo Molnar , Andrew Morton , Daniel Thompson , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v5 2/4] nmi_backtrace: do a local dump_stack() instead of a self-NMI Message-ID: <20160414151933.GF20425@atomlin.usersys.redhat.com> References: <1459877208-15119-1-git-send-email-cmetcalf@mellanox.com> <1459877208-15119-3-git-send-email-cmetcalf@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <1459877208-15119-3-git-send-email-cmetcalf@mellanox.com> X-PGP-Key: http://pgp.mit.edu/pks/lookup?search=atomlin%40redhat.com X-PGP-Fingerprint: 7906 84EB FA8A 9638 8D1E 6E9B E2DE 9658 19CC 77D6 User-Agent: Mutt/1.5.23.1-rc1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1210 Lines: 30 On Tue 2016-04-05 13:26 -0400, Chris Metcalf wrote: > Currently on arm there is code that checks whether it should call > dump_stack() explicitly, to avoid trying to raise an NMI when the > current context is not preemptible by the backtrace IPI. Similarly, > the forthcoming arch/tile support uses an IPI mechanism that does > not support generating an NMI to self. > > Accordingly, move the code that guards this case into the generic > mechanism, and invoke it unconditionally whenever we want a > backtrace of the current cpu. It seems plausible that in all cases, > dump_stack() will generate better information than generating a > stack from the NMI handler. The register state will be missing, > but that state is likely not particularly helpful in any case. > > Or, if we think it is helpful, we should be capturing and emitting > the current register state in all cases when regs == NULL is passed > to nmi_cpu_backtrace(). > > Signed-off-by: Chris Metcalf > --- > arch/arm/kernel/smp.c | 9 --------- > lib/nmi_backtrace.c | 9 +++++++++ > 2 files changed, 9 insertions(+), 9 deletions(-) Thanks Chris. Acked-by: Aaron Tomlin -- Aaron Tomlin