[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20201022114228.9098-1-pmladek@suse.com>
Date: Thu, 22 Oct 2020 13:42:26 +0200
From: Petr Mladek <pmladek@...e.com>
To: Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
Steven Rostedt <rostedt@...dmis.org>,
John Ogness <john.ogness@...utronix.de>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>,
Guenter Roeck <linux@...ck-us.net>,
Shreyas Joshi <shreyas.joshi@...mp.com>,
shreyasjoshi15@...il.com,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>,
linux-kernel@...r.kernel.org, Petr Mladek <pmladek@...e.com>
Subject: [RFC 0/2] printk: Official way to mute consoles
The long discussion about handling empty console= came up with several
problems. This patchset tries to solve the two original problems
with empty console="" parameter:
+ Prevent the potential crash by registering console for /dev/console.
+ Prevent the performance regression by muting the consoles.
IMHO, the patchset makes sense on its own. It fixes a regression. It seems
that people want this functionality [1][2][3].
Note that there are still some problems that might be solved later:
+ Invalid console=bla name might still prevent registering any console.
+ The kernel should not crash even when /dev/console does not point
to any real console.
+ Should we add some fallback for stdin, stdout, and stderr when /dev/console
can't be opened? For example, /dev/null?
+ How user space handle missing none-console associated with /dev/console?
[1] https://www.programmersought.com/article/19374022450/
[2] https://developer.toradex.com/knowledge-base/how-to-disable-enable-debug-messages-in-linux
[3] https://unix.stackexchange.com/questions/117926/try-to-disable-console-output-console-null-doesnt-work
Petr Mladek (2):
printk: Add kernel parameter: mute_console
printk: Restore and document obsolete ways to disable console output
.../admin-guide/kernel-parameters.txt | 11 +++++++
kernel/printk/printk.c | 30 +++++++++++++++++--
2 files changed, 39 insertions(+), 2 deletions(-)
--
2.26.2
Powered by blists - more mailing lists