This fixes a missing bo->reusable = false in iris_bo_export_gem_handle.
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
if (!bo->external) {
_mesa_hash_table_insert(bo->bufmgr->handle_table, &bo->gem_handle, bo);
bo->external = true;
+ bo->reusable = false;
}
}
{
struct iris_bufmgr *bufmgr = bo->bufmgr;
- if (bo->external)
+ if (bo->external) {
+ assert(!bo->reusable);
return;
+ }
mtx_lock(&bufmgr->lock);
iris_bo_make_external_locked(bo);
DRM_CLOEXEC, prime_fd) != 0)
return -errno;
- bo->reusable = false;
-
return 0;
}
_mesa_hash_table_insert(bufmgr->name_table, &bo->global_name, bo);
}
mtx_unlock(&bufmgr->lock);
-
- bo->reusable = false;
}
*name = bo->global_name;