aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/mxser_new.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/char/mxser_new.c')
-rw-r--r--drivers/char/mxser_new.c20
1 files changed, 7 insertions, 13 deletions
diff --git a/drivers/char/mxser_new.c b/drivers/char/mxser_new.c
index 71b965705177..6a563932ba19 100644
--- a/drivers/char/mxser_new.c
+++ b/drivers/char/mxser_new.c
@@ -72,8 +72,6 @@
72#define UART_MCR_AFE 0x20 72#define UART_MCR_AFE 0x20
73#define UART_LSR_SPECIAL 0x1E 73#define UART_LSR_SPECIAL 0x1E
74 74
75#define RELEVANT_IFLAG(iflag) (iflag & (IGNBRK|BRKINT|IGNPAR|PARMRK|INPCK|\
76 IXON|IXOFF))
77 75
78#define C168_ASIC_ID 1 76#define C168_ASIC_ID 1
79#define C104_ASIC_ID 2 77#define C104_ASIC_ID 2
@@ -1990,18 +1988,14 @@ static void mxser_set_termios(struct tty_struct *tty, struct ktermios *old_termi
1990 struct mxser_port *info = tty->driver_data; 1988 struct mxser_port *info = tty->driver_data;
1991 unsigned long flags; 1989 unsigned long flags;
1992 1990
1993 if ((tty->termios->c_cflag != old_termios->c_cflag) || 1991 spin_lock_irqsave(&info->slock, flags);
1994 (RELEVANT_IFLAG(tty->termios->c_iflag) != RELEVANT_IFLAG(old_termios->c_iflag))) { 1992 mxser_change_speed(info, old_termios);
1995 1993 spin_unlock_irqrestore(&info->slock, flags);
1996 spin_lock_irqsave(&info->slock, flags);
1997 mxser_change_speed(info, old_termios);
1998 spin_unlock_irqrestore(&info->slock, flags);
1999 1994
2000 if ((old_termios->c_cflag & CRTSCTS) && 1995 if ((old_termios->c_cflag & CRTSCTS) &&
2001 !(tty->termios->c_cflag & CRTSCTS)) { 1996 !(tty->termios->c_cflag & CRTSCTS)) {
2002 tty->hw_stopped = 0; 1997 tty->hw_stopped = 0;
2003 mxser_start(tty); 1998 mxser_start(tty);
2004 }
2005 } 1999 }
2006 2000
2007 /* Handle sw stopped */ 2001 /* Handle sw stopped */