Lines Matching defs:dmabuf

1317 	struct dma_buf *dmabuf = attach->dmabuf;
1320 dma_resv_lock(dmabuf->resv, NULL);
1322 dma_resv_unlock(dmabuf->resv);
1324 dma_buf_detach(attach->dmabuf, attach);
1325 dma_buf_put(dmabuf);
1436 static int ffs_dma_resv_lock(struct dma_buf *dmabuf, bool nonblock)
1439 return dma_resv_lock_interruptible(dmabuf->resv, NULL);
1441 if (!dma_resv_trylock(dmabuf->resv))
1448 ffs_dmabuf_find_attachment(struct ffs_epfile *epfile, struct dma_buf *dmabuf)
1458 && priv->attach->dmabuf == dmabuf) {
1481 struct dma_buf *dmabuf;
1487 dmabuf = dma_buf_get(fd);
1488 if (IS_ERR(dmabuf))
1489 return PTR_ERR(dmabuf);
1491 attach = dma_buf_attach(dmabuf, gadget->dev.parent);
1505 err = ffs_dma_resv_lock(dmabuf, nonblock);
1510 dma_resv_unlock(dmabuf->resv);
1536 dma_buf_detach(dmabuf, attach);
1538 dma_buf_put(dmabuf);
1549 struct dma_buf *dmabuf;
1552 dmabuf = dma_buf_get(fd);
1553 if (IS_ERR(dmabuf))
1554 return PTR_ERR(dmabuf);
1560 && priv->attach->dmabuf == dmabuf) {
1577 dma_buf_put(dmabuf);
1592 struct dma_buf *dmabuf;
1603 dmabuf = dma_buf_get(req->fd);
1604 if (IS_ERR(dmabuf))
1605 return PTR_ERR(dmabuf);
1607 if (req->length > dmabuf->size || req->length == 0) {
1612 attach = ffs_dmabuf_find_attachment(epfile, dmabuf);
1626 ret = ffs_dma_resv_lock(dmabuf, nonblock);
1632 retl = dma_resv_wait_timeout(dmabuf->resv,
1642 ret = dma_resv_reserve_fences(dmabuf->resv, 1);
1680 dma_resv_add_fence(dmabuf->resv, &fence->base, resv_dir);
1681 dma_resv_unlock(dmabuf->resv);
1706 dma_buf_put(dmabuf);
1714 dma_resv_unlock(dmabuf->resv);
1718 dma_buf_put(dmabuf);