[PATCH v3 0/3] serial: Support a disabled serial port

Simon Glass sjg at chromium.org
Wed Nov 20 16:35:51 CET 2024


This series provides a way to tell a serial UART that it can't actually
work, at runtime. The main motivation is to deal with a coreboot feature
where it does not provide UART details in the sysinfo structure unless
the UART is also enabled in coreboot.

Attempts to introduce a way to enable a silent UART in coreboot have
lead to a large amount of discussion but no result, sadly.

This series reworks a patch sent last year, which was not quite ready to
be applied. A coreboot user (on irc) hit this problem, so it needs to be
resolved.

Link: https://patchwork.ozlabs.org/project/uboot/patch/20231101180447.99361-1-sjg@chromium.org/

Changes in v3:
- Put the feature behind a Kconfig
- Move the feature to the serial uclass, so any serial driver can use it

Changes in v2:
- Drop RFC tag since there were no comments

Simon Glass (3):
  serial: Allow a serial port to be silent disabled
  serial: ns16550: Avoid probing hardware when disabled
  x86: coreboot: Make use of disabled console

 arch/x86/cpu/coreboot/Kconfig    |  1 +
 drivers/serial/Kconfig           |  9 +++++++++
 drivers/serial/ns16550.c         |  3 ++-
 drivers/serial/serial-uclass.c   | 19 ++++++++++++++++++-
 drivers/serial/serial_coreboot.c |  2 ++
 include/serial.h                 | 25 +++++++++++++++++++++++++
 6 files changed, 57 insertions(+), 2 deletions(-)

-- 
2.34.1



More information about the U-Boot mailing list