drm/i915: Allow contexts to be unreferenced locklessly
If we move the actual cleanup of the context to a worker, we can allow the final free to be called from any context and avoid undue latency in the caller. v2: Negotiate handling the delayed contexts free by flushing the workqueue before calling i915_gem_context_fini() and performing the final free of the kernel context directly v3: Flush deferred frees before new context allocations Signed-off-by:Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by:
Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/20170620110547.15947-2-chris@chris-wilson.co.uk
Showing
- drivers/gpu/drm/i915/gvt/scheduler.c 1 addition, 1 deletiondrivers/gpu/drm/i915/gvt/scheduler.c
- drivers/gpu/drm/i915/i915_drv.c 2 additions, 0 deletionsdrivers/gpu/drm/i915/i915_drv.c
- drivers/gpu/drm/i915/i915_drv.h 2 additions, 21 deletionsdrivers/gpu/drm/i915/i915_drv.h
- drivers/gpu/drm/i915/i915_gem_context.c 48 additions, 11 deletionsdrivers/gpu/drm/i915/i915_gem_context.c
- drivers/gpu/drm/i915/i915_gem_context.h 14 additions, 1 deletiondrivers/gpu/drm/i915/i915_gem_context.h
- drivers/gpu/drm/i915/i915_perf.c 2 additions, 2 deletionsdrivers/gpu/drm/i915/i915_perf.c
- drivers/gpu/drm/i915/selftests/i915_vma.c 6 additions, 2 deletionsdrivers/gpu/drm/i915/selftests/i915_vma.c
- drivers/gpu/drm/i915/selftests/mock_context.c 9 additions, 0 deletionsdrivers/gpu/drm/i915/selftests/mock_context.c
- drivers/gpu/drm/i915/selftests/mock_context.h 2 additions, 0 deletionsdrivers/gpu/drm/i915/selftests/mock_context.h
- drivers/gpu/drm/i915/selftests/mock_gem_device.c 2 additions, 1 deletiondrivers/gpu/drm/i915/selftests/mock_gem_device.c
Loading
Please register or sign in to comment