summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_gem_context.h
diff options
context:
space:
mode:
authorChris Wilson2017-06-20 13:05:47 +0200
committerChris Wilson2017-06-20 18:13:54 +0200
commit1acfc104cdf8a3408f0e83b4115d4419c6315005 (patch)
tree34bb5200d992f514e11e1482f17466a577931bc0 /drivers/gpu/drm/i915/i915_gem_context.h
parentdrm/i915: Allow contexts to be unreferenced locklessly (diff)
downloadkernel-qcow2-linux-1acfc104cdf8a3408f0e83b4115d4419c6315005.tar.gz
kernel-qcow2-linux-1acfc104cdf8a3408f0e83b4115d4419c6315005.tar.xz
kernel-qcow2-linux-1acfc104cdf8a3408f0e83b4115d4419c6315005.zip
drm/i915: Enable rcu-only context lookups
Whilst the contents of the context is still protected by the big struct_mutex, this is not much of an improvement. It is just one tiny step towards reducing our BKL. 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/20170620110547.15947-3-chris@chris-wilson.co.uk
Diffstat (limited to 'drivers/gpu/drm/i915/i915_gem_context.h')
-rw-r--r--drivers/gpu/drm/i915/i915_gem_context.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem_context.h b/drivers/gpu/drm/i915/i915_gem_context.h
index 61146f4aa168..04320f80f9f4 100644
--- a/drivers/gpu/drm/i915/i915_gem_context.h
+++ b/drivers/gpu/drm/i915/i915_gem_context.h
@@ -100,6 +100,11 @@ struct i915_gem_context {
struct kref ref;
/**
+ * @rcu: rcu_head for deferred freeing.
+ */
+ struct rcu_head rcu;
+
+ /**
* @flags: small set of booleans
*/
unsigned long flags;