All of lore.kernel.org
 help / color / mirror / Atom feed
From: Petr Mladek <pmladek@suse.com>
To: John Ogness <john.ogness@linutronix.de>
Cc: Sergey Senozhatsky <senozhatsky@chromium.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	linux-kernel@vger.kernel.org, Rik van Riel <riel@surriel.com>,
	Omar Sandoval <osandov@meta.com>
Subject: Re: [PATCH printk v1 2/2] printk: Defer legacy printing when holding printk_cpu_sync
Date: Wed, 11 Dec 2024 16:03:34 +0100	[thread overview]
Message-ID: <Z1mpxhCU-WpaKJIt@pathway.suse.cz> (raw)
In-Reply-To: <20241209111746.192559-3-john.ogness@linutronix.de>

On Mon 2024-12-09 12:23:46, John Ogness wrote:
> The documentation of printk_cpu_sync_get() clearly states
> that the owner must never perform any activities where it waits
> for a CPU. For legacy printing there can be spinning on the
> console_lock and on the port lock. Therefore legacy printing
> must be deferred when holding the printk_cpu_sync.
> 
> Note that in the case of emergency states, atomic consoles
> are not prevented from printing when printk is deferred. This
> is appropriate because they do not spin-wait indefinitely for
> other CPUs.
> 

It might be worth adding a reference to the original report
to show that the problem is real.

Reported-by: Rik van Riel <riel@surriel.com>
Closes: https://lore.kernel.org/r/20240715232052.73eb7fb1@imladris.surriel.com

> Signed-off-by: John Ogness <john.ogness@linutronix.de>
> Fixes: 55d6af1d6688 ("lib/nmi_backtrace: explicitly serialize banner and regs")

Anyway, it looks good.

Reviewed-by: Petr Mladek <pmladek@suse.com>

Best Regards,
Petr

PS: I am going to wait few more days for eventual feedback. I'll push
    it when nobody complains.

    I could add the above mentioned references when pushing.

  reply	other threads:[~2024-12-11 15:03 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-09 11:17 [PATCH printk v1 0/2] Fix ABBA deadlock for legacy printing with cpu_sync John Ogness
2024-12-09 11:17 ` [PATCH printk v1 1/2] printk: Remove redundant deferred check in vprintk() John Ogness
2024-12-11 14:24   ` Petr Mladek
2024-12-09 11:17 ` [PATCH printk v1 2/2] printk: Defer legacy printing when holding printk_cpu_sync John Ogness
2024-12-11 15:03   ` Petr Mladek [this message]
2024-12-11 16:48     ` John Ogness
2024-12-16 14:17       ` Petr Mladek
2025-01-10 11:22         ` John Ogness
2025-01-10 15:30           ` Petr Mladek

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=Z1mpxhCU-WpaKJIt@pathway.suse.cz \
    --to=pmladek@suse.com \
    --cc=john.ogness@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=osandov@meta.com \
    --cc=riel@surriel.com \
    --cc=rostedt@goodmis.org \
    --cc=senozhatsky@chromium.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.