Re: [PATCH printk v4 04/17] printk: nbcon: Add context to usable() and emit()

From: Petr Mladek
Date: Tue Aug 27 2024 - 08:21:22 EST


On Tue 2024-08-27 06:49:20, John Ogness wrote:
> The nbcon consoles will have two callbacks to be used for
> different contexts. In order to determine if an nbcon console
> is usable, console_is_usable() must know if it is a context
> that will need to use the optional write_atomic() callback.
> Also, nbcon_emit_next_record() must know which callback it
> needs to call.
>
> Add an extra parameter @use_atomic to console_is_usable() and
> nbcon_emit_next_record() to specify this.
>
> Since so far only the write_atomic() callback exists,
> @use_atomic is set to true for all call sites.
>
> For legacy consoles, @use_atomic is not used.
>
> Signed-off-by: John Ogness <john.ogness@xxxxxxxxxxxxx>

Reviewed-by: Petr Mladek <pmladek@xxxxxxxx>

Best Regards,
Petr