Lines Matching refs:db_attach

53 	struct dma_buf_attachment	*db_attach;  member
202 if (buf->db_attach) in vb2_dma_sg_prepare()
215 if (buf->db_attach) in vb2_dma_sg_finish()
310 if (buf->db_attach) in vb2_dma_sg_vaddr()
311 buf->vaddr = dma_buf_vmap(buf->db_attach->dmabuf); in vb2_dma_sg_vaddr()
413 struct dma_buf_attachment *db_attach) in vb2_dma_sg_dmabuf_ops_detach() argument
415 struct vb2_dma_sg_attachment *attach = db_attach->priv; in vb2_dma_sg_dmabuf_ops_detach()
425 dma_unmap_sg(db_attach->dev, sgt->sgl, sgt->orig_nents, in vb2_dma_sg_dmabuf_ops_detach()
429 db_attach->priv = NULL; in vb2_dma_sg_dmabuf_ops_detach()
433 struct dma_buf_attachment *db_attach, enum dma_data_direction dma_dir) in vb2_dma_sg_dmabuf_ops_map() argument
435 struct vb2_dma_sg_attachment *attach = db_attach->priv; in vb2_dma_sg_dmabuf_ops_map()
437 struct mutex *lock = &db_attach->dmabuf->lock; in vb2_dma_sg_dmabuf_ops_map()
451 dma_unmap_sg(db_attach->dev, sgt->sgl, sgt->orig_nents, in vb2_dma_sg_dmabuf_ops_map()
457 sgt->nents = dma_map_sg(db_attach->dev, sgt->sgl, sgt->orig_nents, in vb2_dma_sg_dmabuf_ops_map()
472 static void vb2_dma_sg_dmabuf_ops_unmap(struct dma_buf_attachment *db_attach, in vb2_dma_sg_dmabuf_ops_unmap() argument
548 if (WARN_ON(!buf->db_attach)) { in vb2_dma_sg_map_dmabuf()
559 sgt = dma_buf_map_attachment(buf->db_attach, buf->dma_dir); in vb2_dma_sg_map_dmabuf()
576 if (WARN_ON(!buf->db_attach)) { in vb2_dma_sg_unmap_dmabuf()
587 dma_buf_vunmap(buf->db_attach->dmabuf, buf->vaddr); in vb2_dma_sg_unmap_dmabuf()
590 dma_buf_unmap_attachment(buf->db_attach, sgt, buf->dma_dir); in vb2_dma_sg_unmap_dmabuf()
604 dma_buf_detach(buf->db_attach->dmabuf, buf->db_attach); in vb2_dma_sg_detach_dmabuf()
635 buf->db_attach = dba; in vb2_dma_sg_attach_dmabuf()