}
static void tegra_uart_handle_rx_pio(struct tegra_uart_port *tup,
- struct tty_struct *tty)
+ struct tty_port *tty)
{
do {
char flag = TTY_NORMAL;
}
static void tegra_uart_copy_rx_to_tty(struct tegra_uart_port *tup,
- struct tty_struct *tty, int count)
+ struct tty_port *tty, int count)
{
int copied;
struct uart_port *u = &tup->uport;
int count = tup->rx_bytes_requested;
struct tty_struct *tty = tty_port_tty_get(&tup->uport.state->port);
+ struct tty_port *port = &u->state->port;
unsigned long flags;
async_tx_ack(tup->rx_dma_desc);
/* If we are here, DMA is stopped */
if (count)
- tegra_uart_copy_rx_to_tty(tup, tty, count);
+ tegra_uart_copy_rx_to_tty(tup, port, count);
- tegra_uart_handle_rx_pio(tup, tty);
+ tegra_uart_handle_rx_pio(tup, port);
if (tty) {
- tty_flip_buffer_push(tty);
+ tty_flip_buffer_push(port);
tty_kref_put(tty);
}
tegra_uart_start_rx_dma(tup);
{
struct dma_tx_state state;
struct tty_struct *tty = tty_port_tty_get(&tup->uport.state->port);
+ struct tty_port *port = &tup->uport.state->port;
int count;
/* Deactivate flow control to stop sender */
/* If we are here, DMA is stopped */
if (count)
- tegra_uart_copy_rx_to_tty(tup, tty, count);
+ tegra_uart_copy_rx_to_tty(tup, port, count);
- tegra_uart_handle_rx_pio(tup, tty);
+ tegra_uart_handle_rx_pio(tup, port);
if (tty) {
- tty_flip_buffer_push(tty);
+ tty_flip_buffer_push(port);
tty_kref_put(tty);
}
tegra_uart_start_rx_dma(tup);
{
struct tegra_uart_port *tup = to_tegra_uport(u);
struct tty_struct *tty = tty_port_tty_get(&tup->uport.state->port);
+ struct tty_port *port = &u->state->port;
struct dma_tx_state state;
unsigned long ier;
int count;
dmaengine_tx_status(tup->rx_dma_chan, tup->rx_cookie, &state);
async_tx_ack(tup->rx_dma_desc);
count = tup->rx_bytes_requested - state.residue;
- tegra_uart_copy_rx_to_tty(tup, tty, count);
- tegra_uart_handle_rx_pio(tup, tty);
+ tegra_uart_copy_rx_to_tty(tup, port, count);
+ tegra_uart_handle_rx_pio(tup, port);
} else {
- tegra_uart_handle_rx_pio(tup, tty);
+ tegra_uart_handle_rx_pio(tup, port);
}
if (tty) {
- tty_flip_buffer_push(tty);
+ tty_flip_buffer_push(port);
tty_kref_put(tty);
}
return;