summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/i915/i915_vma.c
diff options
context:
space:
mode:
authorNiranjana Vishwanathapura <niranjana.vishwanathapura@intel.com>2022-07-01 15:50:49 -0700
committerAndi Shyti <andi.shyti@linux.intel.com>2022-07-27 14:01:44 +0000
commit16c35db52c7e1018eb17f09dc3ca9b6422bd0376 (patch)
tree16228c69ba58d1fa21b057914083877c79d691b0 /drivers/gpu/drm/i915/i915_vma.c
parent6d4a81033fc07aef3ef210eff4f54243479d109c (diff)
drm/i915/vm_bind: Add out fence support
Add support for handling out fence of vm_bind call. Signed-off-by: Niranjana Vishwanathapura <niranjana.vishwanathapura@intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_vma.c')
-rw-r--r--drivers/gpu/drm/i915/i915_vma.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_vma.c b/drivers/gpu/drm/i915/i915_vma.c
index c669aff143f0..8243818b1c6c 100644
--- a/drivers/gpu/drm/i915/i915_vma.c
+++ b/drivers/gpu/drm/i915/i915_vma.c
@@ -1510,8 +1510,12 @@ err_unlock:
err_vma_res:
i915_vma_resource_free(vma_res);
err_fence:
- if (work)
+ if (work) {
+ if (i915_vma_is_persistent(vma))
+ i915_vm_bind_signal_fence(vma, &work->base.dma);
+
dma_fence_work_commit_imm(&work->base);
+ }
err_rpm:
if (wakeref)
intel_runtime_pm_put(&vma->vm->i915->runtime_pm, wakeref);