Qipan Li 8316d04c42 serial: sirf: add DMA support using dmaengine APIs
if we get the valid dma channels from dts, move to use dmaengine to do
rx/tx. because the dma hardware requires dma address and length to be
4bytes aligned, in this driver, we will still use PIO for non-aligned
bytes, and use dma for aligned bytes.

for rx, to keep the dmaengine always active, we use double-buffer, so
we issue two dma_desc at first, and maintain the status of both
1. dma transfer done: update in rx dma finish callback
2. dma buffer is inserted into tty: update in rx dma finish tasklet and
   rx timeout tasklet
so we re-issue the dma_desc only if both 1&2 are finished.

for tx, as we know the actual length for every transfer, we don't need
the above double buffering.

Signed-off-by: Qipan Li <Qipan.Li@csr.com>
Signed-off-by: Barry Song <Baohua.Song@csr.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-08-19 17:13:22 -07:00
..
2013-03-18 16:24:29 -07:00
2013-01-15 22:30:15 -08:00
2013-02-06 11:10:17 -08:00
2013-03-18 16:24:29 -07:00
2011-03-31 11:26:23 -03:00
2012-08-10 12:55:47 -07:00
2013-03-18 16:24:29 -07:00
2013-07-24 15:12:53 -07:00
2013-05-20 12:15:59 -07:00
2013-08-02 11:47:42 +08:00