summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_drv.h
diff options
context:
space:
mode:
authorChris Wilson2019-01-28 11:23:56 +0100
committerChris Wilson2019-01-28 17:24:22 +0100
commit1e345568e3b541e19202caadae8d2cb2237e7ed8 (patch)
treeb48938fe29b0fea0391f5a9d31feb248912dd4c3 /drivers/gpu/drm/i915/i915_drv.h
parentdrm/i915: Always allocate an object/vma for the HWSP (diff)
downloadkernel-qcow2-linux-1e345568e3b541e19202caadae8d2cb2237e7ed8.tar.gz
kernel-qcow2-linux-1e345568e3b541e19202caadae8d2cb2237e7ed8.tar.xz
kernel-qcow2-linux-1e345568e3b541e19202caadae8d2cb2237e7ed8.zip
drm/i915: Move list of timelines under its own lock
Currently, the list of timelines is serialised by the struct_mutex, but to alleviate difficulties with using that mutex in future, move the list management under its own dedicated mutex. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20190128102356.15037-5-chris@chris-wilson.co.uk
Diffstat (limited to 'drivers/gpu/drm/i915/i915_drv.h')
-rw-r--r--drivers/gpu/drm/i915/i915_drv.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
index 0133d1da3d3c..8a181b455197 100644
--- a/drivers/gpu/drm/i915/i915_drv.h
+++ b/drivers/gpu/drm/i915/i915_drv.h
@@ -1975,7 +1975,10 @@ struct drm_i915_private {
void (*resume)(struct drm_i915_private *);
void (*cleanup_engine)(struct intel_engine_cs *engine);
- struct list_head timelines;
+ struct i915_gt_timelines {
+ struct mutex mutex; /* protects list, tainted by GPU */
+ struct list_head list;
+ } timelines;
struct list_head active_rings;
struct list_head closed_vma;