On Wed, Jul 06, 2016 at 11:52:11AM +0100, Tvrtko Ursulin wrote: > From: Tvrtko Ursulin <tvrtko.ursulin@xxxxxxxxx> > > Engine contains dev_priv so need to pass it in. > > Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@xxxxxxxxx> > --- > drivers/gpu/drm/i915/intel_ringbuffer.c | 18 ++++++++---------- > 1 file changed, 8 insertions(+), 10 deletions(-) > > diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.c b/drivers/gpu/drm/i915/intel_ringbuffer.c > index 6b24c1642d84..26fe312005d1 100644 > --- a/drivers/gpu/drm/i915/intel_ringbuffer.c > +++ b/drivers/gpu/drm/i915/intel_ringbuffer.c > @@ -2167,21 +2167,19 @@ static void intel_ring_context_unpin(struct i915_gem_context *ctx, > i915_gem_context_unreference(ctx); > } > > -static int intel_init_ring_buffer(struct drm_device *dev, > - struct intel_engine_cs *engine) > +static int intel_init_ring_buffer(struct intel_engine_cs *engine) > { > - struct drm_i915_private *dev_priv = to_i915(dev); > + struct drm_i915_private *dev_priv = engine->i915; > struct intel_ringbuffer *ringbuf; > int ret; > > WARN_ON(engine->buffer); > > - engine->i915 = dev_priv; > INIT_LIST_HEAD(&engine->active_list); > INIT_LIST_HEAD(&engine->request_list); > INIT_LIST_HEAD(&engine->execlist_queue); > INIT_LIST_HEAD(&engine->buffers); Patch 6/5, Move all the common init code to the dispatch? -Chris -- Chris Wilson, Intel Open Source Technology Centre _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx