[Intel-gfx] [PATCH v2 01/11] drm/i915: Create distinct lockclasses for execution vs user timelines

Chris Wilson chris at chris-wilson.co.uk
Tue Nov 8 08:50:44 UTC 2016


On Tue, Nov 08, 2016 at 09:43:21AM +0200, Joonas Lahtinen wrote:
> On ma, 2016-11-07 at 13:59 +0000, Chris Wilson wrote:
> > @@ -56,6 +61,24 @@ int i915_gem_timeline_init(struct drm_i915_private *i915,
> >  	return 0;
> >  }
> >  
> > +int i915_gem_timeline_init(struct drm_i915_private *i915,
> > +			   struct i915_gem_timeline *timeline,
> > +			   const char *name)
> > +{
> > +	static struct lock_class_key class;
> > +	return __i915_gem_timeline_init(i915, timeline, name,
> > +					&class, "timeline");
> > +}
> > +
> > +int i915_gem_timeline_init__global(struct drm_i915_private *i915)
> > +{
> > +	static struct lock_class_key class;
> > +	return __i915_gem_timeline_init(i915,
> > +					&i915->gt.global_timeline,
> > +					"[execution]",
> > +					&class, "global-timeline");
> > +}
> > +
> 
> These names might have potential to be confusing in lockdep splat,
> don't you think?

Urm, I lost a fixup. They are meant to be &timeline->lock and
&global_timeline->lock.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre


More information about the Intel-gfx mailing list