Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 00f4db9e authored by Johan Hovold's avatar Johan Hovold Committed by alexax66
Browse files

USB: serial: ftdi_sio: fix line-status over-reporting



commit a6bb1e17a39818b01b55d8e6238b4b5f06d55038 upstream.

FTDI devices use a receive latency timer to periodically empty the
receive buffer and report modem and line status (also when the buffer is
empty).

When a break or error condition is detected the corresponding status
flags will be set on a packet with nonzero data payload and the flags
are not updated until the break is over or further characters are
received.

In order to avoid over-reporting break and error conditions, these flags
must therefore only be processed for packets with payload.

This specifically fixes the case where after an overrun, the error
condition is continuously reported and NULL-characters inserted until
further data is received.

Reported-by: default avatarMichael Walle <michael@walle.cc>
Fixes: 72fda3ca ("USB: serial: ftd_sio: implement sysrq handling on
break")
Fixes: 166ceb69 ("USB: ftdi_sio: clean up line-status handling")
Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
Signed-off-by: default avatarWilly Tarreau <w@1wt.eu>

Signed-off-by: default avatarCorey Edwards <ensabahnur16@gmail.com>
parent 1e0aec7a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment