serial: max3107: introduce a max3107 driver
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / drivers / serial / ioc4_serial.c
index 8ad28fc64926a88e2d5399439f3852d3818f243f..fcfe82653ac8d1edd73f208faf616446bb2a5e9c 100644 (file)
@@ -1685,11 +1685,12 @@ ioc4_change_speed(struct uart_port *the_port,
 {
        struct ioc4_port *port = get_ioc4_port(the_port, 0);
        int baud, bits;
-       unsigned cflag;
+       unsigned cflag, iflag;
        int new_parity = 0, new_parity_enable = 0, new_stop = 0, new_data = 8;
        struct uart_state *state = the_port->state;
 
        cflag = new_termios->c_cflag;
+       iflag = new_termios->c_iflag;
 
        switch (cflag & CSIZE) {
        case CS5:
@@ -1741,12 +1742,12 @@ ioc4_change_speed(struct uart_port *the_port,
 
        state->port.tty->low_latency = 1;
 
-       if (I_IGNPAR(state->port.tty))
+       if (iflag & IGNPAR)
                the_port->ignore_status_mask &= ~(N_PARITY_ERROR
                                                | N_FRAMING_ERROR);
-       if (I_IGNBRK(state->port.tty)) {
+       if (iflag & IGNBRK) {
                the_port->ignore_status_mask &= ~N_BREAK;
-               if (I_IGNPAR(state->port.tty))
+               if (iflag & IGNPAR)
                        the_port->ignore_status_mask &= ~N_OVERRUN_ERROR;
        }
        if (!(cflag & CREAD)) {