Re: [PATCH printk v3 14/14] panic: Flush kernel log buffer at the end

From: Petr Mladek
Date: Fri Feb 02 2024 - 04:47:28 EST


On Thu 2023-12-14 22:48:01, John Ogness wrote:
> If the kernel crashes in a context where printk() calls always
> defer printing (such as in NMI or inside a printk_safe section)
> then the final panic messages will be deferred to irq_work. But
> if irq_work is not available, the messages will not get printed
> unless explicitly flushed. The result is that the final
> "end Kernel panic" banner does not get printed.
>
> Add one final flush after the last printk() call to make sure
> the final panic messages make it out as well.
>
> Signed-off-by: John Ogness <john.ogness@xxxxxxxxxxxxx>

Makes sense.

Reviewed-by: Petr Mladek <pmladek@xxxxxxxx>

Best Regards,
Petr