]> git.karo-electronics.de Git - karo-tx-linux.git/commit
drm/i915: Initialize seqno for VECS too
authorBen Widawsky <benjamin.widawsky@intel.com>
Mon, 12 Aug 2013 23:53:03 +0000 (16:53 -0700)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 13 Aug 2013 21:10:37 +0000 (23:10 +0200)
commitd6fc62c1699f4331c6b05a4b82a7796f8d281af3
treec664456d374be51b00b0f398d1ba8b56121509df
parent7499671cb211b34322085172c2fbb33ba87825eb
drm/i915: Initialize seqno for VECS too

We require n-1 mailboxes for proper semaphore synchronization. All
semaphore synchronization code relies on proper values in these
mailboxes. The fact that we failed to touch the vebox ring by itself
was unlikely to be an issue since the HW should be initializing the
values to 0. However the error framework for testing seqno wrap
introduced by Mika, in addition to the hangcheck via seqno, and
i915_error_first_batchbuffer() combined caused a nice explosion.

The problem is caused by seqno wrap because the wrap condition is not
properly setup. The wrap code attempts to set the sync mailboxes all
to 0, and then set the current seqno to one less than 0. In all cases,
the vebox mailbox wasn't properly being initialized. This caused a
wrap to not occur. When hangcheck kicks in with the bogus seqno
values, the rest just doesn't work. It makes me wonder if we shouldn't
consider a dumber version of hangcheck...

How we messed this up: VECS support was written before the
aforementioned other features. Upon VECS being rebased, these facts
were missed.

Cc: Mika Kuoppala <mika.kuoppala@intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=65387
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=67198
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/intel_ringbuffer.c