aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial/ifx6x60.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/tty/serial/ifx6x60.c')
-rw-r--r--drivers/tty/serial/ifx6x60.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/drivers/tty/serial/ifx6x60.c b/drivers/tty/serial/ifx6x60.c
index 8cb6d8d66a13..68d7ce997ede 100644
--- a/drivers/tty/serial/ifx6x60.c
+++ b/drivers/tty/serial/ifx6x60.c
@@ -481,7 +481,6 @@ static int ifx_spi_prepare_tx_buffer(struct ifx_spi_device *ifx_dev)
481 unsigned char *tx_buffer; 481 unsigned char *tx_buffer;
482 482
483 tx_buffer = ifx_dev->tx_buffer; 483 tx_buffer = ifx_dev->tx_buffer;
484 memset(tx_buffer, 0, IFX_SPI_TRANSFER_SIZE);
485 484
486 /* make room for required SPI header */ 485 /* make room for required SPI header */
487 tx_buffer += IFX_SPI_HEADER_OVERHEAD; 486 tx_buffer += IFX_SPI_HEADER_OVERHEAD;
@@ -615,7 +614,7 @@ static int ifx_port_activate(struct tty_port *port, struct tty_struct *tty)
615 tty->driver_data = ifx_dev; 614 tty->driver_data = ifx_dev;
616 615
617 /* allows flip string push from int context */ 616 /* allows flip string push from int context */
618 tty->low_latency = 1; 617 port->low_latency = 1;
619 618
620 /* set flag to allows data transfer */ 619 /* set flag to allows data transfer */
621 set_bit(IFX_SPI_STATE_IO_AVAILABLE, &ifx_dev->flags); 620 set_bit(IFX_SPI_STATE_IO_AVAILABLE, &ifx_dev->flags);
@@ -670,12 +669,8 @@ static const struct tty_operations ifx_spi_serial_ops = {
670static void ifx_spi_insert_flip_string(struct ifx_spi_device *ifx_dev, 669static void ifx_spi_insert_flip_string(struct ifx_spi_device *ifx_dev,
671 unsigned char *chars, size_t size) 670 unsigned char *chars, size_t size)
672{ 671{
673 struct tty_struct *tty = tty_port_tty_get(&ifx_dev->tty_port); 672 tty_insert_flip_string(&ifx_dev->tty_port, chars, size);
674 if (!tty) 673 tty_flip_buffer_push(&ifx_dev->tty_port);
675 return;
676 tty_insert_flip_string(tty, chars, size);
677 tty_flip_buffer_push(tty);
678 tty_kref_put(tty);
679} 674}
680 675
681/** 676/**