]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
drm/i915: Split i915_gem_timeline into individual timelines
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 2 May 2018 16:38:39 +0000 (17:38 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Wed, 2 May 2018 22:57:18 +0000 (23:57 +0100)
commita89d1f921c15932b4c9a70861d134290f1a14a10
treefefd7b7cfb73f00ad6dee8360da6cbcc21ffbccf
parent65fcb8064dd0e54d4674e8e2c6bf6ed7264a29e9
drm/i915: Split i915_gem_timeline into individual timelines

We need to move to a more flexible timeline that doesn't assume one
fence context per engine, and so allow for a single timeline to be used
across a combination of engines. This means that preallocating a fence
context per engine is now a hindrance, and so we want to introduce the
singular timeline. From the code perspective, this has the notable
advantage of clearing up a lot of mirky semantics and some clumsy
pointer chasing.

By splitting the timeline up into a single entity rather than an array
of per-engine timelines, we can realise the goal of the previous patch
of tracking the timeline alongside the ring.

v2: Tweak wait_for_idle to stop the compiling thinking that ret may be
uninitialised.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180502163839.3248-2-chris@chris-wilson.co.uk
26 files changed:
drivers/gpu/drm/i915/Makefile
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/i915_gem.c
drivers/gpu/drm/i915/i915_gem_context.c
drivers/gpu/drm/i915/i915_gem_context.h
drivers/gpu/drm/i915/i915_gem_gtt.h
drivers/gpu/drm/i915/i915_gem_timeline.c [deleted file]
drivers/gpu/drm/i915/i915_gem_timeline.h [deleted file]
drivers/gpu/drm/i915/i915_gpu_error.c
drivers/gpu/drm/i915/i915_perf.c
drivers/gpu/drm/i915/i915_request.c
drivers/gpu/drm/i915/i915_request.h
drivers/gpu/drm/i915/i915_timeline.c [new file with mode: 0644]
drivers/gpu/drm/i915/i915_timeline.h [new file with mode: 0644]
drivers/gpu/drm/i915/intel_engine_cs.c
drivers/gpu/drm/i915/intel_guc_submission.c
drivers/gpu/drm/i915/intel_lrc.c
drivers/gpu/drm/i915/intel_ringbuffer.c
drivers/gpu/drm/i915/intel_ringbuffer.h
drivers/gpu/drm/i915/selftests/i915_gem_context.c
drivers/gpu/drm/i915/selftests/i915_gem_timeline.c [deleted file]
drivers/gpu/drm/i915/selftests/i915_timeline.c [new file with mode: 0644]
drivers/gpu/drm/i915/selftests/mock_engine.c
drivers/gpu/drm/i915/selftests/mock_gem_device.c
drivers/gpu/drm/i915/selftests/mock_timeline.c
drivers/gpu/drm/i915/selftests/mock_timeline.h