diff options
author | Sonic Zhang <sonic.zhang@analog.com> | 2012-05-16 02:22:24 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-05-17 16:25:56 -0400 |
commit | 239c25b1a03cf57193b9a52623deb918adf6132e (patch) | |
tree | 8ac6c54d5b5a15d8efef65c4f40caaa8bed18fdb /drivers/tty/serial/bfin_uart.c | |
parent | b06d2f20cdf57841b309d30d895b1fd502655e48 (diff) |
serial: bfin_uart: narrow the reboot condition in DMA tx interrupt
Check if xmit buffer pointers are set to zero.
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial/bfin_uart.c')
-rw-r--r-- | drivers/tty/serial/bfin_uart.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/serial/bfin_uart.c b/drivers/tty/serial/bfin_uart.c index 9acab114d804..56b95b0447d9 100644 --- a/drivers/tty/serial/bfin_uart.c +++ b/drivers/tty/serial/bfin_uart.c | |||
@@ -532,7 +532,7 @@ static irqreturn_t bfin_serial_dma_tx_int(int irq, void *dev_id) | |||
532 | */ | 532 | */ |
533 | UART_CLEAR_IER(uart, ETBEI); | 533 | UART_CLEAR_IER(uart, ETBEI); |
534 | uart->port.icount.tx += uart->tx_count; | 534 | uart->port.icount.tx += uart->tx_count; |
535 | if (!uart_circ_empty(xmit)) { | 535 | if (!(xmit->tail == 0 && xmit->head == 0)) { |
536 | xmit->tail = (xmit->tail + uart->tx_count) & (UART_XMIT_SIZE - 1); | 536 | xmit->tail = (xmit->tail + uart->tx_count) & (UART_XMIT_SIZE - 1); |
537 | 537 | ||
538 | if (uart_circ_chars_pending(xmit) < WAKEUP_CHARS) | 538 | if (uart_circ_chars_pending(xmit) < WAKEUP_CHARS) |