USB: keyspan: fix tty line-status reporting
authorJohan Hovold <johan@kernel.org>
Tue, 18 Nov 2014 10:25:19 +0000 (11:25 +0100)
committerDanny Wood <danwood76@gmail.com>
Tue, 29 Jan 2019 13:05:16 +0000 (13:05 +0000)
commita7807c8b8d1e5e2b90cf756167d3874409abccb4
tree38cf83963b10886343991f32185a6893f9003def
parent27decc7e5435ed0062efa9398f45e0b379a5c31b
USB: keyspan: fix tty line-status reporting

commit 5d1678a33c731b56e245e888fdae5e88efce0997 upstream.

Fix handling of TTY error flags, which are not bitmasks and must
specifically not be ORed together as this prevents the line discipline
from recognising them.

Also insert null characters when reporting overrun errors as these are
not associated with the received character.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/serial/keyspan.c