Home
last modified time | relevance | path

Searched hist:"733 fff67941dad64b8a630450b8372b1873edc41" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/drivers/usb/serial/
H A Dftdi_sio.cdiff 733fff67941dad64b8a630450b8372b1873edc41 Wed Jul 08 07:49:53 CDT 2020 Johan Hovold <johan@kernel.org> USB: serial: ftdi_sio: fix break and sysrq handling

Only the last NUL in a packet should be flagged as a break character,
for example, to avoid dropping unrelated characters when IGNBRK is set.

Also make sysrq work by consuming the break character instead of having
it immediately cancel the sysrq request, and by not processing it
prematurely to avoid triggering a sysrq based on an unrelated character
received in the same packet (which was received *before* the break).

Note that the break flag can be left set also for a packet received
immediately following a break and that and an ending NUL in such a
packet will continue to be reported as a break as there's no good way to
tell it apart from an actual break.

Tested on FT232R and FT232H.

Fixes: 72fda3ca6fc1 ("USB: serial: ftd_sio: implement sysrq handling on break")
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Johan Hovold <johan@kernel.org>