提交 a3b0397f 编写于 作者: H Heikki Krogerus 提交者: Greg Kroah-Hartman

serial: 8250_dma: TX optimisation

Remove one useless wakeup, and do not use DMA with zero byte
transfers.
Signed-off-by: NHeikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 6f3fe3b1
...@@ -67,12 +67,12 @@ int serial8250_tx_dma(struct uart_8250_port *p) ...@@ -67,12 +67,12 @@ int serial8250_tx_dma(struct uart_8250_port *p)
struct circ_buf *xmit = &p->port.state->xmit; struct circ_buf *xmit = &p->port.state->xmit;
struct dma_async_tx_descriptor *desc; struct dma_async_tx_descriptor *desc;
if (dma->tx_running) { if (dma->tx_running)
uart_write_wakeup(&p->port);
return -EBUSY; return -EBUSY;
}
dma->tx_size = CIRC_CNT_TO_END(xmit->head, xmit->tail, UART_XMIT_SIZE); dma->tx_size = CIRC_CNT_TO_END(xmit->head, xmit->tail, UART_XMIT_SIZE);
if (!dma->tx_size)
return -EINVAL;
desc = dmaengine_prep_slave_single(dma->txchan, desc = dmaengine_prep_slave_single(dma->txchan,
dma->tx_addr + xmit->tail, dma->tx_addr + xmit->tail,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册