lkml.org 
[lkml]   [2021]   [Jun]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] printk: Add CONFIG_CONSOLE_LOGLEVEL_PANIC
From
Date
On 6/28/21 1:43 PM, Petr Mladek wrote:
[..]
> Is it enough to keep the current level during panic()?

Yes.

> It might be
> easier to introduce a commandline option, for example, no_console_verbose_panic.
> It would do:
>
> static inline void console_verbose_panic(void)
> {
> if (!no_console_verbose_panic)
> console_verbose();
> }
>
> It is clear what it does. On the other hand, the logic with particular
> loglevels is not clear. 3 different proposals has already been mentioned
> in this thread:
>
> if (console_loglevel &&
> (CONFIG_CONSOLE_LOGLEVEL_PANIC > console_loglevel)) {
> console_loglevel = CONFIG_CONSOLE_LOGLEVEL_PANIC;
> }
>
> vs.
>
> if (console_loglevel)
> console_loglevel = CONFIG_CONSOLE_LOGLEVEL_PANIC;
>
> vs.
>
> if (console_loglevel && CONFIG_CONSOLE_LOGLEVEL_PANIC)
> console_loglevel = CONFIG_CONSOLE_LOGLEVEL_PANIC;
>
>
> Just imagine that you are a distributor, developer or admin:
>
> What value you would choose for CONFIG_CONSOLE_LOGLEVEL_PANIC?
> What console loglevel will be used at the end?
>
> The answer depends on the implemented alhorith, console_loglevel,
> and CONFIG_CONSOLE_LOGLEVEL_PANIC.
>
> The answer would be much easier if "no_verbose_console_panic" is
> used instead.

Thanks for your replies, Petr, I'll send v2 with the function rename
patch and a patch to introduce this boot option, after the merge window
closes. I appreciate your inputs :-)

Thanks,
Dmitry

\
 
 \ /
  Last update: 2021-06-28 19:27    [W:1.120 / U:0.004 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site