From: Ingo Molnar <mingo@elte.hu>
To: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
Cc: Toshikazu Nakayama <nakayama.ts@ncos.nec.co.jp>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] printk: fix discarding message when recursion_bug
Date: Fri, 19 Dec 2008 23:35:58 +0100 [thread overview]
Message-ID: <20081219223558.GC13409@elte.hu> (raw)
In-Reply-To: <494C1D20.9000008@ct.jp.nec.com>
* Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com> wrote:
> Ingo Molnar wrote:
> > * Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com> wrote:
> >
> >> From: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
> >>
> >> Impact: fix
> >>
> >> When recursion_bug is true, kernel discards original message because printk_buf
> >> contains recursion_bug_msg with NULL terminator. The sizeof(recursion_bug_msg)
> >> makes this, use strlen() to get correct length without NULL terminator.
> >>
> >> Reported-by: Toshikazu Nakayama <nakayama.ts@ncos.nec.co.jp>
> >> Signed-off-by: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
> >> ---
> >> kernel/printk.c | 2 +-
> >> 1 files changed, 1 insertions(+), 1 deletions(-)
> >
> > Good one - applied to tip/core/printk, thanks!
> >
> > Btw., i'm curious: in what situation was such recursion observed, and how
> > did the kernel behave? You saw a truncated recursion message in dmesg - or
> > was it worse?
>
> I'm not sure about the real situation. I've heard this issue was found
> in printing messages in NMI handler, maybe with artificial kernel stuck.
yeah, accidental NMI recursion back into printk could indeed cause the
recursion message to pop up.
Ingo
prev parent reply other threads:[~2008-12-19 22:36 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-19 18:23 [PATCH] printk: fix discarding message when recursion_bug Hiroshi Shimamoto
2008-12-19 21:53 ` Ingo Molnar
2008-12-19 22:16 ` Hiroshi Shimamoto
2008-12-19 22:35 ` Ingo Molnar [this message]
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=20081219223558.GC13409@elte.hu \
--to=mingo@elte.hu \
--cc=h-shimamoto@ct.jp.nec.com \
--cc=linux-kernel@vger.kernel.org \
--cc=nakayama.ts@ncos.nec.co.jp \
/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