]> git.ipfire.org Git - thirdparty/linux.git/commit - drivers/gpu/drm/i915/intel_lrc.c
drm/i915: Fix startup failure in LRC mode after recent init changes
authorThomas Daniel <thomas.daniel@intel.com>
Tue, 2 Dec 2014 12:50:48 +0000 (12:50 +0000)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 3 Dec 2014 08:35:30 +0000 (09:35 +0100)
commite7778be1eab918274f79603d7c17b3ec8be77386
tree845a294cb2cd3b37defcae52be62162a322d69a7
parentd972d6ee55102f1acb48c55537fb5989136358b7
drm/i915: Fix startup failure in LRC mode after recent init changes

A previous commit introduced engine init changes:

    commit 372ee59699d9 ("drm/i915: Only init engines once")

This broke execlists as intel_lr_context_render_state_init was trying to emit
commands to the RCS for the default context before the ring->init_hw was called.

Made a new gen8_init_rcs_context function and assign in to render ring
init_context.  Moved call to intel_logical_ring_workarounds_emit into
gen8_init_rcs_context to maintain previous functionality.

Moved call to render_state_init from lr_context_deferred_create into
gen8_init_rcs_context, and modified deferred_create to call ring->init_context
for non-default contexts.

Modified i915_gem_context_enable to call ring->init_context for the default
context.

So init_context will now always be called when the hw is ready - in
i915_gem_context_enable for the default context and in lr_context_deferred_create
for other contexts.

Signed-off-by: Thomas Daniel <thomas.daniel@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_gem_context.c
drivers/gpu/drm/i915/intel_lrc.c