Skip to content

USB: serial: cp210x: clean up termios handling

Johan Hovold linux-usb lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest6 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6USB: serial: cp210x: return early on unchanged termiosdrivers/usb/serial/cp210x.c+12 -00 replies
2/6USB: serial: cp210x: clean up line-control handlingdrivers/usb/serial/cp210x.c+41 -600 replies
3/6USB: serial: cp210x: set terminal settings on opendrivers/usb/serial/cp210x.c+6 -2830 replies
4/6USB: serial: cp210x: drop flow-control debuggingdrivers/usb/serial/cp210x.c+1 -50 replies
5/6USB: serial: cp210x: refactor flow-control handlingdrivers/usb/serial/cp210x.c+47 -500 replies
6/6USB: serial: cp210x: clean up dts_rtsdrivers/usb/serial/cp210x.c+4 -40 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/6] USB: serial: cp210x: clean up termios handling

Unlike other drivers cp210x have been retrieving the current terminal settings from the device on open and reflecting those in termios.

Due to how set_termios() was implemented this saved a few control requests on open but has instead caused problems like broken flow control and has required adding workarounds for swapped line-control in cp2108 and line-speed initialisation on cp2104.

This unusual implementation also complicates adding new features for no good reason.

Rip out the corresponding code and the above mentioned workarounds and instead initialise the terminal settings unconditionally on open.

Johan

Johan Hovold (6):
USB: serial: cp210x: return early on unchanged termios
USB: serial: cp210x: clean up line-control handling
USB: serial: cp210x: set terminal settings on open
USB: serial: cp210x: drop flow-control debugging
USB: serial: cp210x: refactor flow-control handling
USB: serial: cp210x: clean up dts_rts

 drivers/usb/serial/cp210x.c | 499 ++++++++----------------------------
 1 file changed, 104 insertions(+), 395 deletions(-)
Signature · 1 line
2.26.2