Lines Matching refs:vc
21 struct virt_dma_chan *vc = to_virt_chan(tx->chan);
26 spin_lock_irqsave(&vc->lock, flags);
29 list_move_tail(&vd->node, &vc->desc_submitted);
30 spin_unlock_irqrestore(&vc->lock, flags);
32 dev_dbg(vc->chan.device->dev, "vchan %p: txd %p[%x]: submitted\n",
33 vc, vd, cookie);
51 struct virt_dma_chan *vc = to_virt_chan(tx->chan);
55 spin_lock_irqsave(&vc->lock, flags);
57 spin_unlock_irqrestore(&vc->lock, flags);
59 dev_dbg(vc->chan.device->dev, "vchan %p: txd %p[%x]: freeing\n",
60 vc, vd, vd->tx.cookie);
61 vc->desc_free(vd);
66 struct virt_dma_desc *vchan_find_desc(struct virt_dma_chan *vc,
71 list_for_each_entry(vd, &vc->desc_issued, node)
85 struct virt_dma_chan *vc = from_tasklet(vc, t, task);
90 spin_lock_irq(&vc->lock);
91 list_splice_tail_init(&vc->desc_completed, &head);
92 vd = vc->cyclic;
94 vc->cyclic = NULL;
99 spin_unlock_irq(&vc->lock);
112 void vchan_dma_desc_free_list(struct virt_dma_chan *vc, struct list_head *head)
123 void vchan_init(struct virt_dma_chan *vc, struct dma_device *dmadev)
125 dma_cookie_init(&vc->chan);
127 spin_lock_init(&vc->lock);
128 INIT_LIST_HEAD(&vc->desc_allocated);
129 INIT_LIST_HEAD(&vc->desc_submitted);
130 INIT_LIST_HEAD(&vc->desc_issued);
131 INIT_LIST_HEAD(&vc->desc_completed);
132 INIT_LIST_HEAD(&vc->desc_terminated);
134 tasklet_setup(&vc->task, vchan_complete);
136 vc->chan.device = dmadev;
137 list_add_tail(&vc->chan.device_node, &dmadev->channels);