aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2018-03-27 11:48:24 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-04-23 10:16:50 +0200
commitc5f78b1fe4e5baf4c4ca30377c2d7e06e2e391ec (patch)
tree7aa24241fd71460d638053895d3585660e10881e /drivers/tty/serial
parentserial: Remove depends on HAS_DMA in case of platform dependency (diff)
downloadlinux-dev-c5f78b1fe4e5baf4c4ca30377c2d7e06e2e391ec.tar.xz
linux-dev-c5f78b1fe4e5baf4c4ca30377c2d7e06e2e391ec.zip
serial: Introduce UPSTAT_SYNC_FIFO for synchronised FIFOs
This change adds a flag to indicate that a UART is has an external means of synchronising its FIFO, without needing CTSRTS or XON/XOFF. This allows us to use the throttle/unthrottle callbacks, without having to claim other methods of flow control. Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Tested-by: Eddie James <eajames@linux.vnet.ibm.com> Tested-by: Joel Stanley <joel@jms.id.au> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial')
-rw-r--r--drivers/tty/serial/serial_core.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/tty/serial/serial_core.c b/drivers/tty/serial/serial_core.c
index 0466f9f08a91..c47158c93202 100644
--- a/drivers/tty/serial/serial_core.c
+++ b/drivers/tty/serial/serial_core.c
@@ -674,8 +674,8 @@ static void uart_send_xchar(struct tty_struct *tty, char ch)
static void uart_throttle(struct tty_struct *tty)
{
struct uart_state *state = tty->driver_data;
+ upstat_t mask = UPSTAT_SYNC_FIFO;
struct uart_port *port;
- upstat_t mask = 0;
port = uart_port_ref(state);
if (!port)
@@ -703,8 +703,8 @@ static void uart_throttle(struct tty_struct *tty)
static void uart_unthrottle(struct tty_struct *tty)
{
struct uart_state *state = tty->driver_data;
+ upstat_t mask = UPSTAT_SYNC_FIFO;
struct uart_port *port;
- upstat_t mask = 0;
port = uart_port_ref(state);
if (!port)