diff options
Diffstat (limited to 'src/gallium/winsys/amdgpu/drm/amdgpu_cs.h')
-rw-r--r-- | src/gallium/winsys/amdgpu/drm/amdgpu_cs.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_cs.h b/src/gallium/winsys/amdgpu/drm/amdgpu_cs.h index 1c3d0f0be1c..d023841439a 100644 --- a/src/gallium/winsys/amdgpu/drm/amdgpu_cs.h +++ b/src/gallium/winsys/amdgpu/drm/amdgpu_cs.h @@ -162,6 +162,9 @@ static inline bool amdgpu_fence_is_syncobj(struct amdgpu_fence *fence) static inline void amdgpu_ctx_unref(struct amdgpu_ctx *ctx) { if (p_atomic_dec_zero(&ctx->refcount)) { + if (ctx->ws->reserve_vmid) + amdgpu_vm_unreserve_vmid(ctx->ctx, 0); + amdgpu_cs_ctx_free(ctx->ctx); amdgpu_bo_free(ctx->user_fence_bo); FREE(ctx); |