diff options
author | Jiri Slaby <jslaby@suse.cz> | 2013-01-03 09:53:04 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-01-16 01:22:35 -0500 |
commit | 05c7cd39907184328f48d3e7899f9cdd653ad336 (patch) | |
tree | 9d1ed5c757426aa20b7eccd853faa6b519a4aa7b /drivers/tty/serial/amba-pl011.c | |
parent | 92a19f9cec9a80ad93c06e115822deb729e2c6ad (diff) |
TTY: switch tty_insert_flip_string
Now, we start converting tty buffer functions to actually use
tty_port. This will allow us to get rid of the need of tty in many
call sites. Only tty_port will needed and hence no more
tty_port_tty_get in those paths.
tty_insert_flip_string this time.
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial/amba-pl011.c')
-rw-r--r-- | drivers/tty/serial/amba-pl011.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/tty/serial/amba-pl011.c b/drivers/tty/serial/amba-pl011.c index 7fca4022a8b2..e1257d17f5f0 100644 --- a/drivers/tty/serial/amba-pl011.c +++ b/drivers/tty/serial/amba-pl011.c | |||
@@ -698,7 +698,8 @@ static void pl011_dma_rx_chars(struct uart_amba_port *uap, | |||
698 | u32 pending, bool use_buf_b, | 698 | u32 pending, bool use_buf_b, |
699 | bool readfifo) | 699 | bool readfifo) |
700 | { | 700 | { |
701 | struct tty_struct *tty = uap->port.state->port.tty; | 701 | struct tty_port *port = &uap->port.state->port; |
702 | struct tty_struct *tty = port->tty; | ||
702 | struct pl011_sgbuf *sgbuf = use_buf_b ? | 703 | struct pl011_sgbuf *sgbuf = use_buf_b ? |
703 | &uap->dmarx.sgbuf_b : &uap->dmarx.sgbuf_a; | 704 | &uap->dmarx.sgbuf_b : &uap->dmarx.sgbuf_a; |
704 | struct device *dev = uap->dmarx.chan->device->dev; | 705 | struct device *dev = uap->dmarx.chan->device->dev; |
@@ -715,8 +716,7 @@ static void pl011_dma_rx_chars(struct uart_amba_port *uap, | |||
715 | * Note that tty_insert_flip_buf() tries to take as many chars | 716 | * Note that tty_insert_flip_buf() tries to take as many chars |
716 | * as it can. | 717 | * as it can. |
717 | */ | 718 | */ |
718 | dma_count = tty_insert_flip_string(uap->port.state->port.tty, | 719 | dma_count = tty_insert_flip_string(port, sgbuf->buf, pending); |
719 | sgbuf->buf, pending); | ||
720 | 720 | ||
721 | /* Return buffer to device */ | 721 | /* Return buffer to device */ |
722 | dma_sync_sg_for_device(dev, &sgbuf->sg, 1, DMA_FROM_DEVICE); | 722 | dma_sync_sg_for_device(dev, &sgbuf->sg, 1, DMA_FROM_DEVICE); |