OSDN Git Service

USB: serial: ir-usb: fix IrLAP framing
authorJohan Hovold <johan@kernel.org>
Wed, 22 Jan 2020 10:15:28 +0000 (11:15 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 5 Feb 2020 13:03:31 +0000 (13:03 +0000)
commit32c4ed0c4ab87049392eed36d7e92e6b22dd46cd
treea04422a1210c3e83d47e6265d391b68d44309c4e
parent39fa352a77dd67cecac212a9ff84369ed7c34de7
USB: serial: ir-usb: fix IrLAP framing

commit 38c0d5bdf4973f9f5a888166e9d3e9ed0d32057a upstream.

Commit f4a4cbb2047e ("USB: ir-usb: reimplement using generic framework")
switched to using the generic write implementation which may combine
multiple write requests into larger transfers. This can break the IrLAP
protocol where end-of-frame is determined using the USB short packet
mechanism, for example, if multiple frames are sent in rapid succession.

Fixes: f4a4cbb2047e ("USB: ir-usb: reimplement using generic framework")
Cc: stable <stable@vger.kernel.org> # 2.6.35
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/serial/ir-usb.c