USB: serial: cp210x: clean up line-control handling
authorJohan Hovold <johan@kernel.org>
Mon, 16 Nov 2020 16:18:22 +0000 (17:18 +0100)
committerJohan Hovold <johan@kernel.org>
Fri, 4 Dec 2020 13:57:23 +0000 (14:57 +0100)
commitd42976296c3389b556913d249f7c5626b754ec26
tree86099457140c78e10575e0d1978ed257ca5155ee
parent95168d624f3a8dee466525767200391a0fb006b9
USB: serial: cp210x: clean up line-control handling

Update the line-control settings in one request unconditionally instead
of setting the word-length, parity and stop-bit settings separately.

This avoids multiple requests when several settings are changed even if
this scheme could potentially also be used to detect unsupported device
settings. Since all device types but CP2101 appears to support all
settings, let's handle that one specifically and also report back the
unsupported settings properly through termios by clearing the
corresponding bits.

Also drop the related unnecessary debug printks.

Signed-off-by: Johan Hovold <johan@kernel.org>
drivers/usb/serial/cp210x.c