提交 acc80758 编写于 作者: A Alan Cox 提交者: Linus Torvalds

mct_u232: Use flip buffer functions

Signed-off-by: NAlan Cox <alan@redhat.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 e19b2560
......@@ -563,11 +563,9 @@ static void mct_u232_read_int_callback(struct urb *urb)
* Work-a-round: handle the 'usual' bulk-in pipe here
*/
if (urb->transfer_buffer_length > 2) {
int i;
tty = port->port.tty;
if (urb->actual_length) {
for (i = 0; i < urb->actual_length ; ++i)
tty_insert_flip_char(tty, data[i], 0);
tty_insert_flip_string(tty, data, urb->actual_length);
tty_flip_buffer_push(tty);
}
goto exit;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册