diff options
author | John Ogness <john.ogness@linutronix.de> | 2025-01-08 00:27:01 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-01-10 18:08:25 +0300 |
commit | b63e6f60eab45b16a1bf734fef9035a4c4187cd5 (patch) | |
tree | 5b8a1ba5879a404e5508e3a893c79d5dc93a40d5 /scripts/gdb/linux/utils.py | |
parent | 910ef438e93cd2ceb70c72caea418710d648feef (diff) | |
download | linux-b63e6f60eab45b16a1bf734fef9035a4c4187cd5.tar.xz |
serial: 8250: Switch to nbcon console
Implement the necessary callbacks to switch the 8250 console driver
to perform as an nbcon console.
Add implementations for the nbcon console callbacks:
->write_atomic()
->write_thread()
->device_lock()
->device_unlock()
and add CON_NBCON to the initial @flags.
All register access in the callbacks are within unsafe sections.
The ->write_atomic() and ->write_thread() callbacks allow safe
handover/takeover per byte and add a preceding newline if they
take over from another context mid-line.
For the ->write_atomic() callback, a new irq_work is used to defer
modem control since it may be called from a context that does not
allow waking up tasks.
Note: A new __serial8250_clear_IER() is introduced for direct
clearing of UART_IER. This will allow to restore the lockdep
check to serial8250_clear_IER() in a follow-up commit.
Signed-off-by: John Ogness <john.ogness@linutronix.de>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Tested-by: Petr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/20250107212702.169493-6-john.ogness@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions