public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Chris Down <chris@chrisdown.name>
To: Petr Mladek <pmladek@suse.com>
Cc: Rik van Riel <riel@surriel.com>,
	linux-kernel@vger.kernel.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Sergey Senozhatsky <senozhatsky@chromium.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	John Ogness <john.ogness@linutronix.de>,
	Geert Uytterhoeven <geert@linux-m68k.org>,
	kernel-team@fb.com
Subject: Re: [RFC PATCH v2] printk: console: Allow each console to have its own loglevel
Date: Wed, 13 Jul 2022 15:32:27 +0100	[thread overview]
Message-ID: <Ys7Xe8iSOYzmQeIu@chrisdown.name> (raw)
In-Reply-To: <Ysbv3HUYJTzRpjeq@alley>

Petr Mladek writes:
>The problem is clear. But the big part of the problem is that printk()
>tries to show the messages on all consoles immediately.
>
>I wonder how much the per-console loglevel would be needed
>when the console handling is offloaded to per-console kthreads, see
>https://lore.kernel.org/all/20220421212250.565456-1-john.ogness@linutronix.de/
>It causes that printk() should "never" block and each console might
>run on its own speed.
>
>It still might be useful from some reasons:
>
>    + Serial consoles might miss messages because the old messages are
>      over-written before they reach the console. It might be solved
>      by big enough buffer.
>
>    + printk() still tries to show the messages immediately in some
>      critical situations, for example, early boot, watchdog warnings,
>      suspend, reboot, OOps, panic(). The slow consoles might still
>      cause stalls and put the system into its knees.
>
>    + People might need to explicitly disable the kthreads, for
>      example, when debugging a situation when kthreads are not
>      scheduled.

Indeed. In addition to these, there are cases (like the pstore case mentioned 
by Vincent) where we want to bump the console loglevel up to the maximum for 
debugging, but it still doesn't make sense to emit it over all consoles -- 
especially netconsoles where processing capacity on the netconsole 
receiver/server is likely limited. The same is true for things like baseboard 
management controllers where they may blindly store the console output in a 
similar fashion.

The kthread offloading is definitely going to help a lot here here, but to 
capably be able to use netconsole in prod we're going to need both.

>PS: I am sorry for the late response. I am still snowed under
>many tasks. The printk kthreads are complicated and need
>a lot of attention. Plus there was a sickness, vacations,
>and other tasks.

Don't worry, I totally understand :-) I really appreciate you getting back.

  reply	other threads:[~2022-07-13 14:32 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-20 12:57 [RFC PATCH v2] printk: console: Allow each console to have its own loglevel Chris Down
2022-05-20 16:06 ` Rik van Riel
2022-07-07 14:38   ` Petr Mladek
2022-07-13 14:32     ` Chris Down [this message]
2022-05-21 18:51 ` Greg Kroah-Hartman
2022-05-21 19:23   ` Chris Down
2022-05-23 13:09 ` Vincent Whitchurch
2022-05-23 14:24   ` Chris Down
2022-06-16 15:57 ` Chris Down
2022-07-08 15:23 ` design: was: " Petr Mladek
2022-07-08 19:04   ` John Ogness
2022-07-11  8:32     ` Petr Mladek
2022-07-11 10:17       ` Sergey Senozhatsky
2022-07-13 14:50       ` Chris Down
2022-07-13 14:49   ` Chris Down
2022-07-14 15:44     ` Petr Mladek
2022-07-15 12:49       ` Petr Mladek
2022-07-15 13:00         ` Chris Down
2022-07-19 12:11           ` Chris Down
2022-07-19 13:00             ` 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=Ys7Xe8iSOYzmQeIu@chrisdown.name \
    --to=chris@chrisdown.name \
    --cc=geert@linux-m68k.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=john.ogness@linutronix.de \
    --cc=kernel-team@fb.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pmladek@suse.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox