]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commit
drm/i915/guc: Restore preempt-context across S3/S4
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 19 Sep 2018 20:54:32 +0000 (21:54 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Thu, 20 Sep 2018 11:51:42 +0000 (12:51 +0100)
commit8fcd86baab7724196ae8605e58c38dd17d598ef9
treee583d6d8740bf2f20e0df2cc94fb9d7e226878e8
parenta47cd45a37c94bb31ccf9bf6ec3d94cbcd57d6ee
drm/i915/guc: Restore preempt-context across S3/S4

Stolen memory is lost across S4 (hibernate) or S3-RST as it is a portion
of ordinary volatile RAM. As we allocate our rings from stolen, this may
include the rings used for our preempt context and their breadcrumb
instructions. In order to allow preemption following hibernation and
loss of stolen memory, we therefore need to repopulate the instructions
inside the lost ring upon resume. To handle both module load and resume,
we simply defer constructing the ring to first use.

Testcase: igt/drv_selftest/live_gem
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Michał Winiarski <michal.winiarski@intel.com>
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
Reviewed-by: Michał Winiarski <michal.winiarski@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180919205432.18394-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/intel_guc_submission.c