summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-05-16 10:34:52 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-05-16 10:34:52 -0700
commit768cbfbc5273bad91afe12b81471f563b288118a (patch)
tree954b95e1d1af6c21df7c85f265d218e48908e161 /include
parent2a4a7e02e27b4f542473772d588f81759c209fb3 (diff)
parent05ab3014636ff60a319d37cdf37dca594b015eec (diff)
downloadop-kernel-dev-768cbfbc5273bad91afe12b81471f563b288118a.zip
op-kernel-dev-768cbfbc5273bad91afe12b81471f563b288118a.tar.gz
Automatic merge of master.kernel.org:/home/rmk/linux-2.6-serial.git
Diffstat (limited to 'include')
-rw-r--r--include/linux/serial_core.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/include/linux/serial_core.h b/include/linux/serial_core.h
index c3fb598..d6025af 100644
--- a/include/linux/serial_core.h
+++ b/include/linux/serial_core.h
@@ -479,6 +479,25 @@ uart_handle_cts_change(struct uart_port *port, unsigned int status)
}
}
+#include <linux/tty_flip.h>
+
+static inline void
+uart_insert_char(struct uart_port *port, unsigned int status,
+ unsigned int overrun, unsigned int ch, unsigned int flag)
+{
+ struct tty_struct *tty = port->info->tty;
+
+ if ((status & port->ignore_status_mask & ~overrun) == 0)
+ tty_insert_flip_char(tty, ch, flag);
+
+ /*
+ * Overrun is special. Since it's reported immediately,
+ * it doesn't affect the current character.
+ */
+ if (status & ~port->ignore_status_mask & overrun)
+ tty_insert_flip_char(tty, 0, TTY_OVERRUN);
+}
+
/*
* UART_ENABLE_MS - determine if port should enable modem status irqs
*/
OpenPOWER on IntegriCloud