]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
drm/i915/gt: Hold rpm wakeref before taking ggtt->vm.mutex
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 10 Jan 2020 14:44:18 +0000 (14:44 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 10 Jan 2020 20:30:40 +0000 (20:30 +0000)
commitc0e60347d44d5e06869a253de326373e976be1c7
tree9ec946219384465103acd8cb75f8ecb97649e394
parent8cbf89db294166cc13d90a89422605e0c9f8bbc2
drm/i915/gt: Hold rpm wakeref before taking ggtt->vm.mutex

We need to hold the runtime-pm wakeref to update the global PTEs (as
they exist behind a PCI BAR). However, some systems invoke ACPI during
runtime resume and so require allocations, which is verboten inside the
vm->mutex. Ergo, we must not use intel_runtime_pm_get() inside the
mutex, but lift the call outside.

Closes: https://gitlab.freedesktop.org/drm/intel/issues/958
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Matthew Auld <matthew.auld@intel.com>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200110144418.1415639-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gt/intel_ggtt.c
drivers/gpu/drm/i915/i915_vma.c