drm/i915: Consolidate gen8_emit_pipe_control
authorTvrtko Ursulin <tvrtko.ursulin@intel.com>
Thu, 16 Feb 2017 12:23:25 +0000 (12:23 +0000)
committerTvrtko Ursulin <tvrtko.ursulin@intel.com>
Fri, 17 Feb 2017 11:39:59 +0000 (11:39 +0000)
commit9f235dfa495856ed7b264ee08920601df57333da
treea1df25ddb5b674ac8e111891b176d7713738b556
parent097d4f1c121f324d655d17b9bc5238107f7a1761
drm/i915: Consolidate gen8_emit_pipe_control

We have a few open coded instances in the execlists code and an
almost suitable helper in intel_ringbuf.c

We can consolidate to a single helper if we change the existing
helper to emit directly to ring buffer memory and move the space
reservation outside it.

v2: Drop memcpy for memset. (Chris Wilson)

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: http://patchwork.freedesktop.org/patch/msgid/20170216122325.31391-2-tvrtko.ursulin@linux.intel.com
drivers/gpu/drm/i915/intel_lrc.c
drivers/gpu/drm/i915/intel_ringbuffer.c
drivers/gpu/drm/i915/intel_ringbuffer.h