Lines Matching refs:tcd

227 		dma_pool_free(fsl_desc->echan->tcd_pool, fsl_desc->tcd[i].vtcd,  in fsl_edma_free_desc()
228 fsl_desc->tcd[i].ptcd); in fsl_edma_free_desc()
352 nbytes = fsl_edma_get_tcd_to_cpu(fsl_chan, edesc->tcd[i].vtcd, nbytes); in fsl_edma_desc_residue()
355 len += nbytes * fsl_edma_get_tcd_to_cpu(fsl_chan, edesc->tcd[i].vtcd, biter); in fsl_edma_desc_residue()
374 nbytes = fsl_edma_get_tcd_to_cpu(fsl_chan, edesc->tcd[i].vtcd, nbytes); in fsl_edma_desc_residue()
378 size = nbytes * fsl_edma_get_tcd_to_cpu(fsl_chan, edesc->tcd[i].vtcd, biter); in fsl_edma_desc_residue()
381 dma_addr = fsl_edma_get_tcd_to_cpu(fsl_chan, edesc->tcd[i].vtcd, saddr); in fsl_edma_desc_residue()
383 dma_addr = fsl_edma_get_tcd_to_cpu(fsl_chan, edesc->tcd[i].vtcd, daddr); in fsl_edma_desc_residue()
426 static void fsl_edma_set_tcd_regs(struct fsl_edma_chan *fsl_chan, void *tcd) in fsl_edma_set_tcd_regs() argument
438 edma_cp_tcd_to_reg(fsl_chan, tcd, saddr); in fsl_edma_set_tcd_regs()
439 edma_cp_tcd_to_reg(fsl_chan, tcd, daddr); in fsl_edma_set_tcd_regs()
441 edma_cp_tcd_to_reg(fsl_chan, tcd, attr); in fsl_edma_set_tcd_regs()
442 edma_cp_tcd_to_reg(fsl_chan, tcd, soff); in fsl_edma_set_tcd_regs()
444 edma_cp_tcd_to_reg(fsl_chan, tcd, nbytes); in fsl_edma_set_tcd_regs()
445 edma_cp_tcd_to_reg(fsl_chan, tcd, slast); in fsl_edma_set_tcd_regs()
447 edma_cp_tcd_to_reg(fsl_chan, tcd, citer); in fsl_edma_set_tcd_regs()
448 edma_cp_tcd_to_reg(fsl_chan, tcd, biter); in fsl_edma_set_tcd_regs()
449 edma_cp_tcd_to_reg(fsl_chan, tcd, doff); in fsl_edma_set_tcd_regs()
451 edma_cp_tcd_to_reg(fsl_chan, tcd, dlast_sga); in fsl_edma_set_tcd_regs()
453 csr = fsl_edma_get_tcd_to_cpu(fsl_chan, tcd, csr); in fsl_edma_set_tcd_regs()
457 fsl_edma_set_tcd_to_le(fsl_chan, tcd, csr, csr); in fsl_edma_set_tcd_regs()
472 edma_cp_tcd_to_reg(fsl_chan, tcd, csr); in fsl_edma_set_tcd_regs()
477 struct fsl_edma_hw_tcd *tcd, dma_addr_t src, dma_addr_t dst, in fsl_edma_fill_tcd() argument
492 fsl_edma_set_tcd_to_le(fsl_chan, tcd, src, saddr); in fsl_edma_fill_tcd()
493 fsl_edma_set_tcd_to_le(fsl_chan, tcd, dst, daddr); in fsl_edma_fill_tcd()
495 fsl_edma_set_tcd_to_le(fsl_chan, tcd, attr, attr); in fsl_edma_fill_tcd()
497 fsl_edma_set_tcd_to_le(fsl_chan, tcd, soff, soff); in fsl_edma_fill_tcd()
528 fsl_edma_set_tcd_to_le(fsl_chan, tcd, nbytes, nbytes); in fsl_edma_fill_tcd()
529 fsl_edma_set_tcd_to_le(fsl_chan, tcd, slast, slast); in fsl_edma_fill_tcd()
531 fsl_edma_set_tcd_to_le(fsl_chan, tcd, EDMA_TCD_CITER_CITER(citer), citer); in fsl_edma_fill_tcd()
532 fsl_edma_set_tcd_to_le(fsl_chan, tcd, doff, doff); in fsl_edma_fill_tcd()
534 fsl_edma_set_tcd_to_le(fsl_chan, tcd, dlast_sga, dlast_sga); in fsl_edma_fill_tcd()
536 fsl_edma_set_tcd_to_le(fsl_chan, tcd, EDMA_TCD_BITER_BITER(biter), biter); in fsl_edma_fill_tcd()
553 fsl_edma_set_tcd_to_le(fsl_chan, tcd, csr, csr); in fsl_edma_fill_tcd()
555 trace_edma_fill_tcd(fsl_chan, tcd); in fsl_edma_fill_tcd()
564 fsl_desc = kzalloc(struct_size(fsl_desc, tcd, sg_len), GFP_NOWAIT); in fsl_edma_alloc_desc()
571 fsl_desc->tcd[i].vtcd = dma_pool_alloc(fsl_chan->tcd_pool, in fsl_edma_alloc_desc()
572 GFP_NOWAIT, &fsl_desc->tcd[i].ptcd); in fsl_edma_alloc_desc()
573 if (!fsl_desc->tcd[i].vtcd) in fsl_edma_alloc_desc()
580 dma_pool_free(fsl_chan->tcd_pool, fsl_desc->tcd[i].vtcd, in fsl_edma_alloc_desc()
581 fsl_desc->tcd[i].ptcd); in fsl_edma_alloc_desc()
633 last_sg = fsl_desc->tcd[(i + 1) % sg_len].ptcd; in fsl_edma_prep_dma_cyclic()
657 fsl_edma_fill_tcd(fsl_chan, fsl_desc->tcd[i].vtcd, src_addr, dst_addr, in fsl_edma_prep_dma_cyclic()
746 last_sg = fsl_desc->tcd[(i + 1)].ptcd; in fsl_edma_prep_slave_sg()
747 fsl_edma_fill_tcd(fsl_chan, fsl_desc->tcd[i].vtcd, src_addr, in fsl_edma_prep_slave_sg()
753 fsl_edma_fill_tcd(fsl_chan, fsl_desc->tcd[i].vtcd, src_addr, in fsl_edma_prep_slave_sg()
780 fsl_edma_fill_tcd(fsl_chan, fsl_desc->tcd[0].vtcd, dma_src, dma_dst, in fsl_edma_prep_memcpy()
797 fsl_edma_set_tcd_regs(fsl_chan, fsl_chan->edesc->tcd[0].vtcd); in fsl_edma_xfer_desc()