[Intel-gfx] [PATCH 6/6] drm/i915: Kick start the rings

Daniel Vetter daniel at ffwll.ch
Tue Apr 22 21:25:20 CEST 2014


On Tue, Apr 22, 2014 at 01:06:45PM +0000, Mateo Lozano, Oscar wrote:
> > Subject: [Intel-gfx] [PATCH 6/6] drm/i915: Kick start the rings
> > 
> > On g4x, we have an issue where the register write to setup the rings do not
> > always take. However, it appears that the current check also passes only by
> > chance, a second reading of the register returns a different broekn value - but
> > the GPU appears to function. Based on that observation, lets try feeding a nop
> > into the ring and seeing if it advances as part of our startup sanity checks.
> > 
> > References: https://bugs.freedesktop.org/show_bug.cgi?id=76554
> > Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
> > ---
> >  drivers/gpu/drm/i915/intel_ringbuffer.c | 6 +++++-
> >  1 file changed, 5 insertions(+), 1 deletion(-)
> > 
> > diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.c
> > b/drivers/gpu/drm/i915/intel_ringbuffer.c
> > index a8c73a0d935d..bc52645fa8d5 100644
> > --- a/drivers/gpu/drm/i915/intel_ringbuffer.c
> > +++ b/drivers/gpu/drm/i915/intel_ringbuffer.c
> > @@ -514,10 +514,14 @@ static int init_ring_common(struct intel_ring_buffer
> > *ring)
> >  			((ring->size - PAGE_SIZE) & RING_NR_PAGES)
> >  			| RING_VALID);
> > 
> > +	iowrite32(MI_NOOP, ring->virtual_start + 0);
> > +	iowrite32(MI_NOOP, ring->virtual_start + 4);
> > +	ring->write_tail(ring, 8);
> 
> Maybe add a comment in the code about why we are doing this? (otherwise, it looks a bit magical)

Yeah, this is a bit too much magic. Also it looks like it doesn't really
help the bug report with his gm45, so I think I'll punt on this one for
now.

All other patches merged with the 2 small suggestions from Oscar applied
while merging. Thanks for patches&review.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch



More information about the Intel-gfx mailing list