lkml.org 
[lkml]   [2021]   [Jan]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH] serial: 8250: add option to disable registration of legacy ISA ports
On Thu, Jan 28, 2021 at 05:22:44PM +0000, Mans Rullgard wrote:
> On systems that do not have the traditional PC ISA serial ports, the
> 8250 driver still creates non-functional device nodes. This change
> makes only ports that actually exist (PCI, DT, ...) get device nodes.
>
> Signed-off-by: Mans Rullgard <mans@mansr.com>
> ---
> drivers/tty/serial/8250/8250_core.c | 26 ++++++++++++++++++++------
> drivers/tty/serial/8250/Kconfig | 5 +++++
> 2 files changed, 25 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
> index cae61d1ebec5..49695dd3677c 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -555,6 +555,7 @@ static void __init serial8250_isa_init_ports(void)
> }
> }
>
> +#ifdef CONFIG_SERIAL_8250_ISA

This is just making a mess of the code. To do this right, pull the isa
code out into a separate file and put the #ifdef in a .h file, so we can
properly maintain and support this code over time. This change as-is is
not going to make that any easier :(

> +config SERIAL_8250_ISA
> + bool "8250/16550 ISA device support" if EXPERT

So, no one will set this?

What userspace visable change will be caused by this? Will ports get
renumbered? What harm is this causing systems today without this
change?

thanks,

greg k-h
\
 
 \ /
  Last update: 2021-01-31 15:11    [W:0.080 / U:4.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site