summaryrefslogtreecommitdiff
path: root/drivers/tty/serial
diff options
context:
space:
mode:
authorSan Mehat <san@google.com>2011-10-09 02:19:41 +0100
committerAndy Green <andy.green@linaro.org>2011-10-09 02:19:41 +0100
commita41c02f804470aaa3bf7f5f6034bf8208d4f0171 (patch)
tree6c2d900b624c021206ee327c126712edc9c6251e /drivers/tty/serial
parent30182d42179f1be6187788acddff91cf1743bfc5 (diff)
serial_core: Add wake_peer uart operation which is called before starting UART TX. The idea here is to provide a mechanism where we can wakeup our peer before sending data.
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 a3efbea5dbb..41555ff0977 100644
--- a/drivers/tty/serial/serial_core.c
+++ b/drivers/tty/serial/serial_core.c
@@ -91,6 +91,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);