mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
serial: imx: simplify check that prevents starting PIO when DMA is in use
The original code looks as follows:
if (sport->dma_is_enabled) {
... make sure TX DMA is running, i.e. .dma_is_txing = 1
}
if (sport->dma_is_txing)
return;
As .dma_is_txing can only be true if .dma_is_enabled is, the return can
go at the end of the first if body without an additional check.
Signed-off-by: Uwe Kleine-König <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
686351f342
commit
0c54922384
1 changed files with 1 additions and 2 deletions
|
|
@ -504,10 +504,9 @@ static inline void imx_transmit_buffer(struct imx_port *sport)
|
|||
imx_uart_writel(sport, temp, UCR1);
|
||||
imx_dma_tx(sport);
|
||||
}
|
||||
}
|
||||
|
||||
if (sport->dma_is_txing)
|
||||
return;
|
||||
}
|
||||
|
||||
while (!uart_circ_empty(xmit) &&
|
||||
!(imx_uart_readl(sport, uts_reg(sport)) & UTS_TXFULL)) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue