This is a note to let you know that I've just added the patch titled USB: serial: xr: fix CSIZE handling to the 5.12-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: usb-serial-xr-fix-csize-handling.patch and it can be found in the queue-5.12 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From ea7ada4de2f7406150dd35ecd0302842587a464e Mon Sep 17 00:00:00 2001 From: Johan Hovold <johan@xxxxxxxxxx> Date: Tue, 30 Mar 2021 16:37:16 +0200 Subject: USB: serial: xr: fix CSIZE handling From: Johan Hovold <johan@xxxxxxxxxx> commit ea7ada4de2f7406150dd35ecd0302842587a464e upstream. The XR21V141X does not have a 5- or 6-bit mode, but the current implementation failed to properly restore the old setting when CS5 or CS6 was requested. Instead an invalid request would be sent to the device. Fixes: c2d405aa86b4 ("USB: serial: add MaxLinear/Exar USB to Serial driver") Reviewed-by: Manivannan Sadhasivam <mani@xxxxxxxxxx> Cc: stable@xxxxxxxxxxxxxxx # 5.12 Signed-off-by: Johan Hovold <johan@xxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- drivers/usb/serial/xr_serial.c | 5 +++++ 1 file changed, 5 insertions(+) --- a/drivers/usb/serial/xr_serial.c +++ b/drivers/usb/serial/xr_serial.c @@ -468,6 +468,11 @@ static void xr_set_termios(struct tty_st if (old_termios) termios->c_cflag |= old_termios->c_cflag & CSIZE; else + termios->c_cflag |= CS8; + + if (C_CSIZE(tty) == CS7) + bits |= XR21V141X_UART_DATA_7; + else bits |= XR21V141X_UART_DATA_8; break; case CS7: Patches currently in stable-queue which might be from johan@xxxxxxxxxx are queue-5.12/staging-greybus-uart-fix-tiocsserial-jiffies-conversions.patch queue-5.12/tty-mxser-fix-tiocsserial-jiffies-conversions.patch queue-5.12/tty-amiserial-fix-tiocsserial-permission-check.patch queue-5.12/staging-fwserial-fix-tiocsserial-permission-check.patch queue-5.12/usb-serial-xr-fix-csize-handling.patch queue-5.12/usb-serial-ti_usb_3410_5052-fix-tiocsserial-permission-check.patch queue-5.12/tty-moxa-fix-tiocsserial-permission-check.patch queue-5.12/tty-moxa-fix-tiocsserial-jiffies-conversions.patch queue-5.12/staging-fwserial-fix-tiocsserial-jiffies-conversions.patch queue-5.12/revert-usb-cdc-acm-fix-rounding-error-in-tiocsserial.patch queue-5.12/tty-mxser-fix-tiocsserial-permission-check.patch queue-5.12/usb-serial-usb_wwan-fix-tiocsserial-jiffies-conversions.patch