• Johan Hovold's avatar
    USB: serial: stop reporting legacy UART types · f64d74a5
    Johan Hovold authored
    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: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
    f64d74a5
mos7720.c 47.9 KB