From 596c0a68709a93bb376647c1b566e9df4f23b35d Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Tue, 15 May 2012 18:53:39 +0100 Subject: [PATCH] sna: Assign GCops after checking for fallback to pass sanity checks We assert that prior to installing the fallback GCops the current ops are the default set. This is broken if we point GCops to our GPU ops, but then fallback. So check for the fallback first. Reported-by: Jiri Slaby References: https://bugs.freedesktop.org/show_bug.cgi?id=47597 Signed-off-by: Chris Wilson --- src/sna/sna_accel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c index ab26dd08..8915724e 100644 --- a/src/sna/sna_accel.c +++ b/src/sna/sna_accel.c @@ -6751,13 +6751,13 @@ spans_fallback: } assert(gc->miTranslate); - gc->ops = &sna_gc_ops__tmp; DBG(("%s: miZeroLine (solid dash)\n", __FUNCTION__)); if (!sna_fill_init_blt(&fill, data.sna, data.pixmap, data.bo, gc->alu, color)) goto fallback; + gc->ops = &sna_gc_ops__tmp; miZeroDashLine(drawable, gc, mode, n, pt); fill.done(data.sna, &fill);