[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aEf3t7Z4z3g7mHdg@pathway.suse.cz>
Date: Tue, 10 Jun 2025 11:15:35 +0200
From: Petr Mladek <pmladek@...e.com>
To: John Ogness <john.ogness@...utronix.de>
Cc: Sergey Senozhatsky <senozhatsky@...omium.org>,
Steven Rostedt <rostedt@...dmis.org>,
Michael Kelley <mhklinux@...look.com>,
Toshiyuki Sato <fj6611ie@...itsu.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH printk v1] printk: nbcon: Allow reacquire during panic
On Fri 2025-06-06 21:01:49, John Ogness wrote:
> If a console printer is interrupted during panic, it will never
> be able to reacquire ownership in order to perform and cleanup.
> That in itself is not a problem, since the non-panic CPU will
> simply quiesce in an endless loop within nbcon_reacquire_nobuf().
>
> However, in this state, platforms that do not support a true NMI
> to interrupt the quiesced CPU will not be able to shutdown that
> CPU from within panic(). This then causes problems for such as
> being unable to load and run a kdump kernel.
>
> Fix this by allowing non-panic CPUs to reacquire ownership using
> a direct acquire. Then the non-panic CPUs can successfullyl exit
> the nbcon_reacquire_nobuf() loop and the console driver can
> perform any necessary cleanup. But more importantly, the CPU is
> no longer quiesced and is free to process any interrupts
> necessary for panic() to shutdown the CPU.
>
> All other forms of acquire are still not allowed for non-panic
> CPUs since it is safer to have them avoid gaining console
> ownership that is not strictly necessary.
>
> Reported-by: Michael Kelley <mhklinux@...look.com>
> Closes: https://lore.kernel.org/r/SN6PR02MB4157A4C5E8CB219A75263A17D46DA@SN6PR02MB4157.namprd02.prod.outlook.com
> Signed-off-by: John Ogness <john.ogness@...utronix.de>
The patch looks good to me:
Reviewed-by: Petr Mladek <pmladek@...e.com>
I am going to wait few days for a potential feedback and then
queue it for 6.17 unless anyone complains.
Best Regards,
Petr
Powered by blists - more mailing lists