]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
drm/i915/ringbuffer: Exclude last 2 cachlines of ring on 845g
authorChris Wilson <chris@chris-wilson.co.uk>
Mon, 9 Apr 2012 12:59:46 +0000 (13:59 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 22 Apr 2012 22:38:53 +0000 (15:38 -0700)
commit 27c1cbd06a7620b354cbb363834f3bb8df4f410d upstream.

The 845g shares the errata with i830 whereby executing a command
within 2 cachelines of the end of the ringbuffer may cause a GPU hang.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/i915/intel_ringbuffer.c

index 536191540b0399bf8aa04f7c05f5129bb9a13d03..cbc3c049611ecb6cd6978f3deebf54616912ee36 100644 (file)
@@ -1057,7 +1057,7 @@ int intel_init_ring_buffer(struct drm_device *dev,
         * of the buffer.
         */
        ring->effective_size = ring->size;
-       if (IS_I830(ring->dev))
+       if (IS_I830(ring->dev) || IS_845G(ring->dev))
                ring->effective_size -= 128;
 
        return 0;