linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
Cc: Petr Mladek <pmladek@suse.com>, Jan Kara <jack@suse.cz>,
	linux-kernel@vger.kernel.org,
	Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
Subject: Re: [PATCH v2] printk/nmi: avoid direct printk()-s from __printk_nmi_flush()
Date: Tue, 30 Aug 2016 15:03:15 -0700	[thread overview]
Message-ID: <20160830150315.93efc592aa631f474af760b5@linux-foundation.org> (raw)
In-Reply-To: <20160830161354.581-1-sergey.senozhatsky@gmail.com>

On Wed, 31 Aug 2016 01:13:54 +0900 Sergey Senozhatsky <sergey.senozhatsky@gmail.com> wrote:

> __printk_nmi_flush() can be called from nmi_panic(), therefore it has to
> test whether it's executed in NMI context and thus must route the messages
> through deferred printk() or via direct printk().

Why?  What misbehaviour does the current code cause?

> Except for two places
> where __printk_nmi_flush() does unconditional direct printk() calls:
>  - pr_err("printk_nmi_flush: internal error ...")
>  - pr_cont("\n")
> 
> Factor out print_nmi_seq_line() parts into a new printk_nmi_flush_line()
> function, which takes care of in_nmi(), and use it in __printk_nmi_flush()
> for printing and error-reporting.

  reply	other threads:[~2016-08-30 22:03 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-30 16:13 [PATCH v2] printk/nmi: avoid direct printk()-s from __printk_nmi_flush() Sergey Senozhatsky
2016-08-30 22:03 ` Andrew Morton [this message]
2016-08-31  1:44   ` Sergey Senozhatsky
2016-08-31 20:15     ` Andrew Morton
2016-09-01  0:55       ` Sergey Senozhatsky

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=20160830150315.93efc592aa631f474af760b5@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=jack@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pmladek@suse.com \
    --cc=sergey.senozhatsky.work@gmail.com \
    --cc=sergey.senozhatsky@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).