drm/i915: Queue the idling context switch after all other timelines
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 28 Oct 2016 12:58:47 +0000 (13:58 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 28 Oct 2016 19:53:52 +0000 (20:53 +0100)
commit3033acab07f95c089fb871896406657ad4000ed6
tree4c7ad639e37a79f10887f1c68059b214c064ff10
parent73cb97010d4fdd2a29f00cac14d206c7641c23d2
drm/i915: Queue the idling context switch after all other timelines

Before suspend, we wait for the switch to the kernel context. In order
for all the other context images to be complete upon suspend, that
switch must be the last operation by the GPU (i.e. this idling request
must not overtake any pending requests). To make this request execute last,
we make it depend on every other inflight request.

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/20161028125858.23563-24-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_gem.c
drivers/gpu/drm/i915/i915_gem_context.c