Home
last modified time | relevance | path

Searched hist:"6 f602912" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/drivers/usb/serial/
H A Dftdi_sio.ca37025b5 Sun May 05 13:32:30 CDT 2013 Johan Hovold <jhovold@gmail.com> USB: ftdi_sio: fix chars_in_buffer overhead

Use the new generic usb-serial wait_until_sent implementation to wait
for hardware buffers to drain.

This removes the need to check the hardware buffers in chars_in_buffer
and thus removes the overhead introduced by commit 6f602912 ("usb:
serial: ftdi_sio: Add missing chars_in_buffer function") without
breaking tty_wait_until_sent (used by, for example, tcdrain, tcsendbreak
and close).

Reported-by: Stas Sergeev <stsp@list.ru>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6f602912 Wed Oct 10 08:05:06 CDT 2012 Jarkko Huijts <jarkko.huijts@gmail.com> usb: serial: ftdi_sio: Add missing chars_in_buffer function

The driver does not wait until the hardware buffer (for data from the PC to the
UART line) is drained when tcdrain or close is called in an application.
Solution: Implement a chars_in_buffer function that checks both the software
and hardware buffer. If the TEMT (TX empty) bit of the line status register
indicates the hw buffer is not empty, let the function return at least 1. This
has been verified to work correctly with an FT232RL. The check on the hw buffer
can not be done for the original SIO device.

Signed-off-by: Jarkko Huijts <jarkko.huijts@gmail.com>
Acked-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
a37025b5 Sun May 05 13:32:30 CDT 2013 Johan Hovold <jhovold@gmail.com> USB: ftdi_sio: fix chars_in_buffer overhead

Use the new generic usb-serial wait_until_sent implementation to wait
for hardware buffers to drain.

This removes the need to check the hardware buffers in chars_in_buffer
and thus removes the overhead introduced by commit 6f602912 ("usb:
serial: ftdi_sio: Add missing chars_in_buffer function") without
breaking tty_wait_until_sent (used by, for example, tcdrain, tcsendbreak
and close).

Reported-by: Stas Sergeev <stsp@list.ru>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6f602912 Wed Oct 10 08:05:06 CDT 2012 Jarkko Huijts <jarkko.huijts@gmail.com> usb: serial: ftdi_sio: Add missing chars_in_buffer function

The driver does not wait until the hardware buffer (for data from the PC to the
UART line) is drained when tcdrain or close is called in an application.
Solution: Implement a chars_in_buffer function that checks both the software
and hardware buffer. If the TEMT (TX empty) bit of the line status register
indicates the hw buffer is not empty, let the function return at least 1. This
has been verified to work correctly with an FT232RL. The check on the hw buffer
can not be done for the original SIO device.

Signed-off-by: Jarkko Huijts <jarkko.huijts@gmail.com>
Acked-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>