diff options
author | Johan Hovold <johan@kernel.org> | 2021-04-07 12:39:22 +0200 |
---|---|---|
committer | Johan Hovold <johan@kernel.org> | 2021-04-08 09:46:02 +0200 |
commit | f64d74a59c476df7d5abbddc23011f0d8475c7cc (patch) | |
tree | aaadc42209bad01aade6b89e05e1f9451043d0b5 /drivers/usb/serial/io_edgeport.c | |
parent | 01fd45f676f1b3785b7cdd5d815f9c31ddcd9dd1 (diff) | |
download | linux-f64d74a59c476df7d5abbddc23011f0d8475c7cc.tar.bz2 |
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 <gregkh@linuxfoundation.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
Diffstat (limited to 'drivers/usb/serial/io_edgeport.c')
-rw-r--r-- | drivers/usb/serial/io_edgeport.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/drivers/usb/serial/io_edgeport.c b/drivers/usb/serial/io_edgeport.c index 6b86e68ee2e8..e6fe3882bf69 100644 --- a/drivers/usb/serial/io_edgeport.c +++ b/drivers/usb/serial/io_edgeport.c @@ -1594,12 +1594,6 @@ static int edge_tiocmget(struct tty_struct *tty) return result; } -static void get_serial_info(struct tty_struct *tty, struct serial_struct *ss) -{ - ss->type = PORT_16550A; -} - - /***************************************************************************** * SerialIoctl * this function handles any ioctl calls to the driver @@ -3061,7 +3055,6 @@ static struct usb_serial_driver edgeport_2port_device = { .set_termios = edge_set_termios, .tiocmget = edge_tiocmget, .tiocmset = edge_tiocmset, - .get_serial = get_serial_info, .tiocmiwait = usb_serial_generic_tiocmiwait, .get_icount = usb_serial_generic_get_icount, .write = edge_write, @@ -3097,7 +3090,6 @@ static struct usb_serial_driver edgeport_4port_device = { .set_termios = edge_set_termios, .tiocmget = edge_tiocmget, .tiocmset = edge_tiocmset, - .get_serial = get_serial_info, .tiocmiwait = usb_serial_generic_tiocmiwait, .get_icount = usb_serial_generic_get_icount, .write = edge_write, @@ -3133,7 +3125,6 @@ static struct usb_serial_driver edgeport_8port_device = { .set_termios = edge_set_termios, .tiocmget = edge_tiocmget, .tiocmset = edge_tiocmset, - .get_serial = get_serial_info, .tiocmiwait = usb_serial_generic_tiocmiwait, .get_icount = usb_serial_generic_get_icount, .write = edge_write, @@ -3169,7 +3160,6 @@ static struct usb_serial_driver epic_device = { .set_termios = edge_set_termios, .tiocmget = edge_tiocmget, .tiocmset = edge_tiocmset, - .get_serial = get_serial_info, .tiocmiwait = usb_serial_generic_tiocmiwait, .get_icount = usb_serial_generic_get_icount, .write = edge_write, |