From: Greg Kroah-Hartman Date: Sun, 13 Jul 2014 22:52:12 +0000 (-0700) Subject: Merge 3.16-rc5 into tty-next. X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=ca17749259d26f7ddbb0678790d5d534018d0a6b;p=linux-beck.git Merge 3.16-rc5 into tty-next. We want those fixes in here as well. Signed-off-by: Greg Kroah-Hartman --- ca17749259d26f7ddbb0678790d5d534018d0a6b diff --cc drivers/tty/serial/arc_uart.c index f8dc7d381956,008c223eaf26..a59d1d77e750 --- a/drivers/tty/serial/arc_uart.c +++ b/drivers/tty/serial/arc_uart.c @@@ -166,18 -172,18 +166,18 @@@ static void arc_serial_tx_chars(struct int sent = 0; unsigned char ch; - if (unlikely(uart->port.x_char)) { - UART_SET_DATA(uart, uart->port.x_char); - uart->port.icount.tx++; - uart->port.x_char = 0; + if (unlikely(port->x_char)) { + UART_SET_DATA(port, port->x_char); + port->icount.tx++; + port->x_char = 0; sent = 1; - } else if (xmit->tail != xmit->head) { /* TODO: uart_circ_empty */ + } else if (!uart_circ_empty(xmit)) { ch = xmit->buf[xmit->tail]; xmit->tail = (xmit->tail + 1) & (UART_XMIT_SIZE - 1); - uart->port.icount.tx++; - while (!(UART_GET_STATUS(uart) & TXEMPTY)) + port->icount.tx++; + while (!(UART_GET_STATUS(port) & TXEMPTY)) cpu_relax(); - UART_SET_DATA(uart, ch); + UART_SET_DATA(port, ch); sent = 1; }