{
SPRD_RETURN_VAL_IF_FAIL(bo != NULL, 0);
- tbm_bo_sprd bo_sprd;
tbm_bufmgr_sprd bufmgr_sprd;
+ tbm_bo_sprd bo_sprd;
bufmgr_sprd = (tbm_bufmgr_sprd)tbm_backend_get_bufmgr_priv(bo);
SPRD_RETURN_VAL_IF_FAIL(bufmgr_sprd != NULL, 0);
int ret = 0;
if (bufmgr_sprd->use_dma_fence) {
-
struct dma_buf_fence fence;
memset(&fence, 0, sizeof(struct dma_buf_fence));
return 0;
}
- /* Check if the tbm manager supports dma fence or not. */
- if (!bufmgr_sprd->use_dma_fence) {
- TBM_SPRD_LOG("[libtbm-sprd:%d] "
- "error %s:%d Not support DMA FENCE(%s)\n",
- getpid(), __FUNCTION__, __LINE__, strerror(errno));
- return 0;
-
- }
-
ret = ioctl(bo_sprd->dmabuf, DMABUF_IOCTL_GET_FENCE, &fence);
if (ret < 0) {
TBM_SPRD_LOG("[libtbm-sprd:%d] "
getpid(),
__FUNCTION__, bo_sprd->name, bo_sprd->dmabuf);
} else {
-
ret = _tgl_lock(bufmgr_sprd->tgl_fd, bo_sprd->name);
DBG("[libtbm-sprd:%d] lock tgl flink_id:%d\n",