From f64d74a59c476df7d5abbddc23011f0d8475c7cc Mon Sep 17 00:00:00 2001 From: Johan Hovold Date: Wed, 7 Apr 2021 12:39:22 +0200 Subject: USB: serial: stop reporting legacy UART types The TIOCGSERIAL ioctl can be used to set and retrieve the UART type for legacy UARTs, but some USB serial drivers have been reporting back random types in order to "make user-space happy". Some applications have historically expected TIOCGSERIAL to be implemented, but judging from the Debian sources, the port type not being PORT_UNKNOWN is only used to check for the existence of legacy serial ports (ttySn). Drivers like ftdi_sio have been using PORT_UNKNOWN for twenty years (and option for 10 years) without anyone complaining so let's stop reporting back anything else. In the unlikely event that this do cause problems, this should be fixed tree-wide anyway (e.g. for all USB serial drivers and also CDC-ACM). Reviewed-by: Greg Kroah-Hartman Signed-off-by: Johan Hovold --- drivers/usb/serial/f81534.c | 1 - 1 file changed, 1 deletion(-) (limited to 'drivers/usb/serial/f81534.c') diff --git a/drivers/usb/serial/f81534.c b/drivers/usb/serial/f81534.c index 633de52feaad..c0bca52ef92a 100644 --- a/drivers/usb/serial/f81534.c +++ b/drivers/usb/serial/f81534.c @@ -1147,7 +1147,6 @@ static void f81534_get_serial_info(struct tty_struct *tty, struct serial_struct port_priv = usb_get_serial_port_data(port); - ss->type = PORT_16550A; ss->baud_base = port_priv->baud_base; } -- cgit v1.2.3