Lines Matching refs:chan

22 static struct txx9dmac_chan *to_txx9dmac_chan(struct dma_chan *chan)  in to_txx9dmac_chan()  argument
24 return container_of(chan, struct txx9dmac_chan, chan); in to_txx9dmac_chan()
132 static struct device *chan2dev(struct dma_chan *chan) in chan2dev() argument
134 return &chan->dev->device; in chan2dev()
136 static struct device *chan2parent(struct dma_chan *chan) in chan2parent() argument
138 return chan->dev->device.parent; in chan2parent()
202 dma_async_tx_descriptor_init(&desc->txd, &dc->chan); in txx9dmac_desc_alloc()
206 desc->txd.phys = dma_map_single(chan2parent(&dc->chan), &desc->hwdesc, in txx9dmac_desc_alloc()
224 dev_dbg(chan2dev(&dc->chan), "desc %p not ACKed\n", desc); in txx9dmac_desc_get()
229 dev_vdbg(chan2dev(&dc->chan), "scanned %u descriptors on freelist\n", in txx9dmac_desc_get()
238 dev_err(chan2dev(&dc->chan), in txx9dmac_desc_get()
251 dma_sync_single_for_cpu(chan2parent(&dc->chan), in txx9dmac_sync_desc_for_cpu()
254 dma_sync_single_for_cpu(chan2parent(&dc->chan), in txx9dmac_sync_desc_for_cpu()
273 dev_vdbg(chan2dev(&dc->chan), in txx9dmac_desc_put()
277 dev_vdbg(chan2dev(&dc->chan), "moving desc %p to freelist\n", in txx9dmac_desc_put()
289 dev_err(chan2dev(&dc->chan), in txx9dmac_dump_regs()
301 dev_err(chan2dev(&dc->chan), in txx9dmac_dump_regs()
337 struct txx9dmac_slave *ds = dc->chan.private; in txx9dmac_dostart()
340 dev_vdbg(chan2dev(&dc->chan), "dostart %u %p\n", in txx9dmac_dostart()
344 dev_err(chan2dev(&dc->chan), in txx9dmac_dostart()
410 dev_vdbg(chan2dev(&dc->chan), "descriptor %u %p complete\n", in txx9dmac_descriptor_complete()
442 dma_sync_single_for_device(chan2parent(&dc->chan), in txx9dmac_dequeue()
479 dev_crit(chan2dev(&dc->chan), in txx9dmac_dump_desc()
483 dev_crit(chan2dev(&dc->chan), in txx9dmac_dump_desc()
492 dev_crit(chan2dev(&dc->chan), in txx9dmac_dump_desc()
496 dev_crit(chan2dev(&dc->chan), in txx9dmac_dump_desc()
516 dev_crit(chan2dev(&dc->chan), "Abnormal Chain Completion\n"); in txx9dmac_handle_error()
533 dev_crit(chan2dev(&dc->chan), in txx9dmac_handle_error()
568 dev_vdbg(chan2dev(&dc->chan), "scan_descriptors: char=%#llx\n", in txx9dmac_scan_descriptors()
599 dev_err(chan2dev(&dc->chan), in txx9dmac_scan_descriptors()
619 dev_vdbg(chan2dev(&dc->chan), "tasklet: status=%x\n", csr); in txx9dmac_chan_tasklet()
635 dev_vdbg(chan2dev(&dc->chan), "interrupt: status=%#x\n", in txx9dmac_chan_interrupt()
659 dev_vdbg(ddev->chan[0]->dma.dev, "tasklet: mcr=%x\n", mcr); in txx9dmac_tasklet()
662 dc = ddev->chan[i]; in txx9dmac_tasklet()
664 dev_vdbg(chan2dev(&dc->chan), "tasklet: status=%x\n", in txx9dmac_tasklet()
682 dev_vdbg(ddev->chan[0]->dma.dev, "interrupt: status=%#x\n", in txx9dmac_interrupt()
700 struct txx9dmac_chan *dc = to_txx9dmac_chan(tx->chan); in txx9dmac_tx_submit()
706 dev_vdbg(chan2dev(tx->chan), "tx_submit: queued %u %p\n", in txx9dmac_tx_submit()
716 txx9dmac_prep_dma_memcpy(struct dma_chan *chan, dma_addr_t dest, dma_addr_t src, in txx9dmac_prep_dma_memcpy() argument
719 struct txx9dmac_chan *dc = to_txx9dmac_chan(chan); in txx9dmac_prep_dma_memcpy()
727 dev_vdbg(chan2dev(chan), "prep_dma_memcpy d%#llx s%#llx l%#zx f%#lx\n", in txx9dmac_prep_dma_memcpy()
731 dev_dbg(chan2dev(chan), "prep_dma_memcpy: length is zero!\n"); in txx9dmac_prep_dma_memcpy()
786 dma_sync_single_for_device(chan2parent(&dc->chan), in txx9dmac_prep_dma_memcpy()
799 dma_sync_single_for_device(chan2parent(&dc->chan), in txx9dmac_prep_dma_memcpy()
810 txx9dmac_prep_slave_sg(struct dma_chan *chan, struct scatterlist *sgl, in txx9dmac_prep_slave_sg() argument
814 struct txx9dmac_chan *dc = to_txx9dmac_chan(chan); in txx9dmac_prep_slave_sg()
816 struct txx9dmac_slave *ds = chan->private; in txx9dmac_prep_slave_sg()
822 dev_vdbg(chan2dev(chan), "prep_dma_slave\n"); in txx9dmac_prep_slave_sg()
880 dma_sync_single_for_device(chan2parent(&dc->chan), in txx9dmac_prep_slave_sg()
894 dma_sync_single_for_device(chan2parent(&dc->chan), in txx9dmac_prep_slave_sg()
904 static int txx9dmac_terminate_all(struct dma_chan *chan) in txx9dmac_terminate_all() argument
906 struct txx9dmac_chan *dc = to_txx9dmac_chan(chan); in txx9dmac_terminate_all()
910 dev_vdbg(chan2dev(chan), "terminate_all\n"); in txx9dmac_terminate_all()
929 txx9dmac_tx_status(struct dma_chan *chan, dma_cookie_t cookie, in txx9dmac_tx_status() argument
932 struct txx9dmac_chan *dc = to_txx9dmac_chan(chan); in txx9dmac_tx_status()
935 ret = dma_cookie_status(chan, cookie, txstate); in txx9dmac_tx_status()
943 return dma_cookie_status(chan, cookie, txstate); in txx9dmac_tx_status()
957 dma_sync_single_for_device(chan2parent(&dc->chan), in txx9dmac_chain_dynamic()
968 static void txx9dmac_issue_pending(struct dma_chan *chan) in txx9dmac_issue_pending() argument
970 struct txx9dmac_chan *dc = to_txx9dmac_chan(chan); in txx9dmac_issue_pending()
992 static int txx9dmac_alloc_chan_resources(struct dma_chan *chan) in txx9dmac_alloc_chan_resources() argument
994 struct txx9dmac_chan *dc = to_txx9dmac_chan(chan); in txx9dmac_alloc_chan_resources()
995 struct txx9dmac_slave *ds = chan->private; in txx9dmac_alloc_chan_resources()
999 dev_vdbg(chan2dev(chan), "alloc_chan_resources\n"); in txx9dmac_alloc_chan_resources()
1003 dev_dbg(chan2dev(chan), "DMA channel not idle?\n"); in txx9dmac_alloc_chan_resources()
1007 dma_cookie_init(chan); in txx9dmac_alloc_chan_resources()
1013 if (chan->device->device_prep_dma_memcpy) { in txx9dmac_alloc_chan_resources()
1033 dev_info(chan2dev(chan), in txx9dmac_alloc_chan_resources()
1045 dev_dbg(chan2dev(chan), in txx9dmac_alloc_chan_resources()
1051 static void txx9dmac_free_chan_resources(struct dma_chan *chan) in txx9dmac_free_chan_resources() argument
1053 struct txx9dmac_chan *dc = to_txx9dmac_chan(chan); in txx9dmac_free_chan_resources()
1058 dev_dbg(chan2dev(chan), "free_chan_resources (descs allocated=%u)\n", in txx9dmac_free_chan_resources()
1072 dev_vdbg(chan2dev(chan), " freeing descriptor %p\n", desc); in txx9dmac_free_chan_resources()
1073 dma_unmap_single(chan2parent(chan), desc->txd.phys, in txx9dmac_free_chan_resources()
1078 dev_vdbg(chan2dev(chan), "free_chan_resources done\n"); in txx9dmac_free_chan_resources()
1134 dc->ddev->chan[ch] = dc; in txx9dmac_chan_probe()
1135 dc->chan.device = &dc->dma; in txx9dmac_chan_probe()
1136 list_add_tail(&dc->chan.device_node, &dc->chan.device->channels); in txx9dmac_chan_probe()
1137 dma_cookie_init(&dc->chan); in txx9dmac_chan_probe()
1171 dc->ddev->chan[pdev->id % TXX9_DMA_MAX_NR_CHANNELS] = NULL; in txx9dmac_chan_remove()