Re: [PATCH 1/2] printk: export pr_flush()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



John Ogness <john.ogness@xxxxxxxxxxxxx> writes:

> On 2024-04-02, Esben Haabendal <esben@xxxxxxxxxx> wrote:
>>> printk() tries to print directly from the calling context. Are you
>>> experiencing problems where you do not see the restarting message?
>>
>> Yes, that is exactly what we are seing.
>>
>> It is an i.MX8MP system, and console is attached to ttymxc1
>> (drivers/tty/serial/imx.c).
>>
>> Booting up, and simply executing "reboot" command. Without these two
>> patches, the "reboot: Restarting system" message is not written to
>> ttymxc1 console. With the patches, it is.
>
> This console driver is using the legacy console interface. For
> PREEMPT_RT, legacy consoles run exclusively as a thread and thus may not
> have a chance to flush messages before a shutdown/reboot. The correct
> solution is to port the driver to the new nbcon console interface.

I see. The `if (IS_ENABLED(CONFIG_PREEMPT_RT))` in console_unlock() is
preventing the console_lock/console_unlock dance to do what I need.

Are there any other examples other than 8250 for how to port a driver to
nbcon?

What is the plans for porting all of this to mainline?  Should all
drivers be ported first, or will a solution to prevent this type of
regression be implemented at some later time?

/Esben




[Index of Archives]     [RT Stable]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux