aboutsummaryrefslogtreecommitdiff
path: root/drivers/tty/serial
diff options
context:
space:
mode:
authorSan Mehat <san@google.com>2009-07-29 20:21:28 -0700
committerColin Cross <ccross@android.com>2014-03-19 13:07:50 -0700
commit4eac1df4fe521eeb999c91bc3539d97cefc17273 (patch)
tree6f16e1bf194a1e7ad30f4bdcd918e77faca09d7c /drivers/tty/serial
parenteb503b324210115388fc5c6096da2bcea610796f (diff)
serial_core: Add wake_peer uart operation
Add wake_peer which is called before starting UART TX. The idea here is to provide a mechanism where we can wakeup our peer before sending data. Change-Id: I42e0779b635f64ca99184b45d5b028de80197491 Signed-off-by: San Mehat <san@google.com>
Diffstat (limited to 'drivers/tty/serial')
-rw-r--r--drivers/tty/serial/serial_core.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/tty/serial/serial_core.c b/drivers/tty/serial/serial_core.c
index ece2049bd27..7f3d7a3564a 100644
--- a/drivers/tty/serial/serial_core.c
+++ b/drivers/tty/serial/serial_core.c
@@ -89,6 +89,9 @@ static void __uart_start(struct tty_struct *tty)
struct uart_state *state = tty->driver_data;
struct uart_port *port = state->uart_port;
+ if (port->ops->wake_peer)
+ port->ops->wake_peer(port);
+
if (!uart_circ_empty(&state->xmit) && state->xmit.buf &&
!tty->stopped && !tty->hw_stopped)
port->ops->start_tx(port);