Lines Matching refs:attach
227 struct vb2_vmalloc_attachment *attach; in vb2_vmalloc_dmabuf_ops_attach() local
236 attach = kzalloc(sizeof(*attach), GFP_KERNEL); in vb2_vmalloc_dmabuf_ops_attach()
237 if (!attach) in vb2_vmalloc_dmabuf_ops_attach()
240 sgt = &attach->sgt; in vb2_vmalloc_dmabuf_ops_attach()
243 kfree(attach); in vb2_vmalloc_dmabuf_ops_attach()
251 kfree(attach); in vb2_vmalloc_dmabuf_ops_attach()
258 attach->dma_dir = DMA_NONE; in vb2_vmalloc_dmabuf_ops_attach()
259 dbuf_attach->priv = attach; in vb2_vmalloc_dmabuf_ops_attach()
266 struct vb2_vmalloc_attachment *attach = db_attach->priv; in vb2_vmalloc_dmabuf_ops_detach() local
269 if (!attach) in vb2_vmalloc_dmabuf_ops_detach()
272 sgt = &attach->sgt; in vb2_vmalloc_dmabuf_ops_detach()
275 if (attach->dma_dir != DMA_NONE) in vb2_vmalloc_dmabuf_ops_detach()
277 attach->dma_dir); in vb2_vmalloc_dmabuf_ops_detach()
279 kfree(attach); in vb2_vmalloc_dmabuf_ops_detach()
286 struct vb2_vmalloc_attachment *attach = db_attach->priv; in vb2_vmalloc_dmabuf_ops_map() local
294 sgt = &attach->sgt; in vb2_vmalloc_dmabuf_ops_map()
296 if (attach->dma_dir == dma_dir) { in vb2_vmalloc_dmabuf_ops_map()
302 if (attach->dma_dir != DMA_NONE) { in vb2_vmalloc_dmabuf_ops_map()
304 attach->dma_dir); in vb2_vmalloc_dmabuf_ops_map()
305 attach->dma_dir = DMA_NONE; in vb2_vmalloc_dmabuf_ops_map()
316 attach->dma_dir = dma_dir; in vb2_vmalloc_dmabuf_ops_map()
356 .attach = vb2_vmalloc_dmabuf_ops_attach,