USB: serial: ftdi_sio: clean up baudrate request
authorJohan Hovold <johan@kernel.org>
Sun, 11 Sep 2022 14:02:13 +0000 (16:02 +0200)
committerJohan Hovold <johan@kernel.org>
Thu, 15 Sep 2022 06:06:01 +0000 (08:06 +0200)
commita146cc4d4671e938bbfee414c29f589d4a148cbe
tree77e302ff1c9fa41e89a4d4c5632561f43adaab82
parent4d045b98fb7460026ac7aefe5418fff3b9d04f14
USB: serial: ftdi_sio: clean up baudrate request

Multi-channel devices need to encode the channel selector in their
control requests and newer single-channel chip types use the same
request format.

Set the channel index also for these single-channel types so that the
index can be used to determine the baudrate request format instead of
listing types explicitly.

Note that FT232H and FTX accept either 0 or 1 as selector for their
single channel, presumably for backward compatibility reasons.

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