diff options
Diffstat (limited to 'drivers/tty/serial/bfin_uart.c')
-rw-r--r-- | drivers/tty/serial/bfin_uart.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/tty/serial/bfin_uart.c b/drivers/tty/serial/bfin_uart.c index 2e2b2c1cb722..12dceda9db33 100644 --- a/drivers/tty/serial/bfin_uart.c +++ b/drivers/tty/serial/bfin_uart.c | |||
@@ -223,7 +223,6 @@ static void bfin_serial_enable_ms(struct uart_port *port) | |||
223 | #ifdef CONFIG_SERIAL_BFIN_PIO | 223 | #ifdef CONFIG_SERIAL_BFIN_PIO |
224 | static void bfin_serial_rx_chars(struct bfin_serial_port *uart) | 224 | static void bfin_serial_rx_chars(struct bfin_serial_port *uart) |
225 | { | 225 | { |
226 | struct tty_struct *tty = NULL; | ||
227 | unsigned int status, ch, flg; | 226 | unsigned int status, ch, flg; |
228 | static struct timeval anomaly_start = { .tv_sec = 0 }; | 227 | static struct timeval anomaly_start = { .tv_sec = 0 }; |
229 | 228 | ||
@@ -242,11 +241,9 @@ static void bfin_serial_rx_chars(struct bfin_serial_port *uart) | |||
242 | return; | 241 | return; |
243 | } | 242 | } |
244 | 243 | ||
245 | if (!uart->port.state || !uart->port.state->port.tty) | 244 | if (!uart->port.state) |
246 | return; | 245 | return; |
247 | #endif | 246 | #endif |
248 | tty = uart->port.state->port.tty; | ||
249 | |||
250 | if (ANOMALY_05000363) { | 247 | if (ANOMALY_05000363) { |
251 | /* The BF533 (and BF561) family of processors have a nice anomaly | 248 | /* The BF533 (and BF561) family of processors have a nice anomaly |
252 | * where they continuously generate characters for a "single" break. | 249 | * where they continuously generate characters for a "single" break. |
@@ -325,7 +322,7 @@ static void bfin_serial_rx_chars(struct bfin_serial_port *uart) | |||
325 | uart_insert_char(&uart->port, status, OE, ch, flg); | 322 | uart_insert_char(&uart->port, status, OE, ch, flg); |
326 | 323 | ||
327 | ignore_char: | 324 | ignore_char: |
328 | tty_flip_buffer_push(tty); | 325 | tty_flip_buffer_push(&uart->port.state->port); |
329 | } | 326 | } |
330 | 327 | ||
331 | static void bfin_serial_tx_chars(struct bfin_serial_port *uart) | 328 | static void bfin_serial_tx_chars(struct bfin_serial_port *uart) |
@@ -426,7 +423,6 @@ static void bfin_serial_dma_tx_chars(struct bfin_serial_port *uart) | |||
426 | 423 | ||
427 | static void bfin_serial_dma_rx_chars(struct bfin_serial_port *uart) | 424 | static void bfin_serial_dma_rx_chars(struct bfin_serial_port *uart) |
428 | { | 425 | { |
429 | struct tty_struct *tty = uart->port.state->port.tty; | ||
430 | int i, flg, status; | 426 | int i, flg, status; |
431 | 427 | ||
432 | status = UART_GET_LSR(uart); | 428 | status = UART_GET_LSR(uart); |
@@ -471,7 +467,7 @@ static void bfin_serial_dma_rx_chars(struct bfin_serial_port *uart) | |||
471 | } | 467 | } |
472 | 468 | ||
473 | dma_ignore_char: | 469 | dma_ignore_char: |
474 | tty_flip_buffer_push(tty); | 470 | tty_flip_buffer_push(&uart->port.state->port); |
475 | } | 471 | } |
476 | 472 | ||
477 | void bfin_serial_rx_dma_timeout(struct bfin_serial_port *uart) | 473 | void bfin_serial_rx_dma_timeout(struct bfin_serial_port *uart) |