public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Heiko Carstens <heiko.carstens@de.ibm.com>
To: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org,
	Steven Rostedt <rostedt@goodmis.org>,
	Prarit Bhargava <prarit@redhat.com>
Subject: Re: [PATCH] lib/bug.c: use common WARN helper
Date: Tue, 23 Feb 2016 13:14:21 +0100	[thread overview]
Message-ID: <20160223121421.GA4024@osiris> (raw)
In-Reply-To: <14cbeea6c0eb49dc17437b2b8f9448e9e8d40236.1456199584.git.jpoimboe@redhat.com>

On Mon, Feb 22, 2016 at 09:54:17PM -0600, Josh Poimboeuf wrote:
> The traceoff_on_warning option doesn't have any effect on s390, powerpc,
> arm64, parisc, and sh because there are two different types of WARN
> implementations:
> 
> 1) The above mentioned architectures treat WARN() as a special case of a
>    BUG() exception.  They handle warnings in report_bug() in lib/bug.c.
> 
> 2) All other architectures just call warn_slowpath_*() directly.  Their
>    warnings are handled in warn_slowpath_common() in kernel/panic.c.
> 
> Support traceoff_on_warning on all architectures and prevent any future
> divergence by using a single common function to emit the warning.
> 
> Also remove the '()' from '%pS()', because the parentheses look funky:
> 
>   [   45.607629] WARNING: at /root/warn_mod/warn_mod.c:17 .init_dummy+0x20/0x40 [warn_mod]()
> 
> Reported-by: Chunyu Hu <chuhu@redhat.com>
> Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
> ---
> Based on linux-next/master.
> 
>  include/asm-generic/bug.h |  7 +++++++
>  kernel/panic.c            | 44 +++++++++++++++++++++++++-------------------
>  lib/bug.c                 | 27 +++------------------------
>  3 files changed, 35 insertions(+), 43 deletions(-)

Nice! Just tested this on s390.

Acked-by: Heiko Carstens <heiko.carstens@de.ibm.com>

  reply	other threads:[~2016-02-23 12:14 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-23  3:54 [PATCH] lib/bug.c: use common WARN helper Josh Poimboeuf
2016-02-23 12:14 ` Heiko Carstens [this message]
2016-02-23 13:13 ` Prarit Bhargava
2016-02-23 13:35 ` Steven Rostedt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160223121421.GA4024@osiris \
    --to=heiko.carstens@de.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=jpoimboe@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=prarit@redhat.com \
    --cc=rostedt@goodmis.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox