diff options
| author | Hugo Villeneuve <hvilleneuve@dimonoff.com> | 2026-05-21 14:16:50 -0400 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2026-07-10 14:50:12 +0200 |
| commit | 86305190f307c05bc2e0660f4ce16b7aeca6711b (patch) | |
| tree | 063f8cb3f1a97465d4e847a2b6df7f8192eadffc /include/linux/console_struct.h | |
| parent | 11f1d49122ec2227b050f4596a7422606237347e (diff) | |
serial: uniformize serial port I/O infos display
Uniformize serial port I/O infos display from three different functions
that display mostly the same information, but with some variations, by
adding a common function.
This make use of new functions uart_iotype_mmio() and
uart_iotype_legacy_io() to simplify and improve code readability.
This will prevent displaying irrelevant information for future IO types
(ex: UPIO_BUS), while also addressing the (eventually) invalid check for
"iotype >= UPIO_MEM".
This also allows us to remove the confusing cast to (unsigned long long)
for iobase which is defined as an unsigned long, and use %pa to display the
mapbase pointer, as it is done in earlycon_print_info().
Replace snprintf with more robust scnprintf so we could perhaps one day get
rid of snprintf() entirely.
Signed-off-by: Hugo Villeneuve <hvilleneuve@dimonoff.com>
Link: https://patch.msgid.link/20260521-tty-upio-v3-4-bf74567994a0@dimonoff.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/console_struct.h')
0 files changed, 0 insertions, 0 deletions
