drm/i915: Fix semaphore emission for BDW+ RCS ringbuffer emission
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 24 Mar 2017 15:17:24 +0000 (15:17 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 24 Mar 2017 17:10:27 +0000 (17:10 +0000)
The required number of dwords for semaphore emission on BDW RCS is 8,
not 6 - leading to ring buffer corruption and immediate GPU hangs when
using ringbuffer submission.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: http://patchwork.freedesktop.org/patch/msgid/20170324151724.32640-2-chris@chris-wilson.co.uk
Reviewed-by: MichaƂ Winiarski <michal.winiarski@intel.com>
drivers/gpu/drm/i915/intel_ringbuffer.c

index 62756eb2bd4ab8054e01fa3e6c166b98dc74c202..4729ac7ac12215212c6049ae514f6d392e9a0e1f 100644 (file)
@@ -2117,7 +2117,7 @@ int intel_init_render_ring_buffer(struct intel_engine_cs *engine)
 
                        num_rings =
                                hweight32(INTEL_INFO(dev_priv)->ring_mask) - 1;
-                       engine->emit_breadcrumb_sz += num_rings * 6;
+                       engine->emit_breadcrumb_sz += num_rings * 8;
                }
        } else if (INTEL_GEN(dev_priv) >= 6) {
                engine->init_context = intel_rcs_ctx_init;