[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7702bdc2-78ce-00f5-d5a4-c06527c3ae72@igalia.com>
Date: Tue, 22 Feb 2022 11:08:22 -0300
From: "Guilherme G. Piccoli" <gpiccoli@...lia.com>
To: Sergey Senozhatsky <senozhatsky@...omium.org>, bhe@...hat.com,
pmladek@...e.com
Cc: linux-kernel@...r.kernel.org, akpm@...ux-foundation.org,
anton@...msg.org, ccross@...roid.com, dyoung@...hat.com,
feng.tang@...el.com, john.ogness@...utronix.de,
keescook@...omium.org, kernel@...ccoli.net,
kexec@...ts.infradead.org, rostedt@...dmis.org,
tony.luck@...el.com, vgoyal@...hat.com
Subject: Re: [PATCH V6] panic: Move panic_print before kmsg dumpers
On 21/02/2022 22:45, Sergey Senozhatsky wrote:
> [...]
> Yeah, if Petr is fine with that then I'm OK. But at the same time,
> we have `panic_print' which is a bit mask of what panic_print_sys_info()
> should do. And now we also have a boolean `console_flush` flag that tells
> panic_print_sys_info() to ignore some (one as of now) bits of `panic_print'.
>
> So _maybe_ panic_print_sys_info() can just accept panic_print as
> its parameter and then we can do something like this (as an example)
>
> panic_print_sys_info(panic_print & ~PANIC_PRINT_ALL_PRINTK_MSG);
>
>
>> if (panic_print & PANIC_PRINT_ALL_CPU_BT)
>> trigger_all_cpu_backtrace();
>> @@ -286,6 +289,8 @@ void panic(const char *fmt, ...)
>> */
>> atomic_notifier_call_chain(&panic_notifier_list, 0, buf);
>
> [..]
>
>> + panic_print_sys_info(false);
>
> Merely because `panic_print_sys_info(false);` doesn't tell much to a reader.
> Like what is print sys info false?
>
> Or did you already discuss this?
Hi Sergey, thanks for your feedback. So, personally I prefer having the
flag - for me it's clear, it's just a matter of reading the prototype -
either we print the info _or_ we console_flush.
But let's see if others have a preference - if the preference is to use
the bitmask as you suggest, we can do it in a next version.
Cheers,
Guilherme
Powered by blists - more mailing lists