diff options
author | Peter Hurley <peter@hurleysoftware.com> | 2016-04-09 20:53:21 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-04-30 12:26:55 -0400 |
commit | 5604a98e2f95d6221852960a3363588f40d78e22 (patch) | |
tree | d9573557cf616e8751fbde45ee56d8280e3eebcf /drivers/tty/mxser.c | |
parent | e4d38f334ad24f80229a8ebab26950de8e8f34d7 (diff) |
tty: Replace ASYNC_CTS_FLOW bit and update atomically
Replace ASYNC_CTS_FLOW bit in the tty_port::flags field with
TTY_PORT_CTS_FLOW bit in the tty_port::iflags field. Add
tty_port_set_cts_flow() helper to abstract the atomic bit ops.
Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/mxser.c')
-rw-r--r-- | drivers/tty/mxser.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/tty/mxser.c b/drivers/tty/mxser.c index f23c2a101688..8f3fdad37ac7 100644 --- a/drivers/tty/mxser.c +++ b/drivers/tty/mxser.c | |||
@@ -711,8 +711,8 @@ static int mxser_change_speed(struct tty_struct *tty, | |||
711 | /* CTS flow control flag and modem status interrupts */ | 711 | /* CTS flow control flag and modem status interrupts */ |
712 | info->IER &= ~UART_IER_MSI; | 712 | info->IER &= ~UART_IER_MSI; |
713 | info->MCR &= ~UART_MCR_AFE; | 713 | info->MCR &= ~UART_MCR_AFE; |
714 | tty_port_set_cts_flow(&info->port, cflag & CRTSCTS); | ||
714 | if (cflag & CRTSCTS) { | 715 | if (cflag & CRTSCTS) { |
715 | info->port.flags |= ASYNC_CTS_FLOW; | ||
716 | info->IER |= UART_IER_MSI; | 716 | info->IER |= UART_IER_MSI; |
717 | if ((info->type == PORT_16550A) || (info->board->chip_flag)) { | 717 | if ((info->type == PORT_16550A) || (info->board->chip_flag)) { |
718 | info->MCR |= UART_MCR_AFE; | 718 | info->MCR |= UART_MCR_AFE; |
@@ -744,8 +744,6 @@ static int mxser_change_speed(struct tty_struct *tty, | |||
744 | } | 744 | } |
745 | } | 745 | } |
746 | } | 746 | } |
747 | } else { | ||
748 | info->port.flags &= ~ASYNC_CTS_FLOW; | ||
749 | } | 747 | } |
750 | outb(info->MCR, info->ioaddr + UART_MCR); | 748 | outb(info->MCR, info->ioaddr + UART_MCR); |
751 | if (cflag & CLOCAL) { | 749 | if (cflag & CLOCAL) { |