diff options
-rw-r--r-- | src/sna/gen3_render.c | 4 | ||||
-rw-r--r-- | src/sna/kgem.c | 3 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/sna/gen3_render.c b/src/sna/gen3_render.c index a6add062..c3134f44 100644 --- a/src/sna/gen3_render.c +++ b/src/sna/gen3_render.c @@ -2251,7 +2251,7 @@ static int gen3_vertex_finish(struct sna *sna) if (sna->render.vertex_reloc[0]) { sna->kgem.batch[sna->render.vertex_reloc[0]] = kgem_add_reloc(&sna->kgem, sna->render.vertex_reloc[0], - bo, I915_GEM_DOMAIN_VERTEX << 16, 0); + bo, I915_GEM_DOMAIN_VERTEX << 16 | KGEM_RELOC_FENCED, 0); sna->render.vertex_reloc[0] = 0; } @@ -2345,7 +2345,7 @@ static void gen3_vertex_close(struct sna *sna) DBG(("%s: reloc = %d\n", __FUNCTION__, sna->render.vertex_reloc[0])); sna->kgem.batch[sna->render.vertex_reloc[0]] = kgem_add_reloc(&sna->kgem, sna->render.vertex_reloc[0], - bo, I915_GEM_DOMAIN_VERTEX << 16, delta); + bo, I915_GEM_DOMAIN_VERTEX << 16 | KGEM_RELOC_FENCED, delta); sna->render.vertex_reloc[0] = 0; if (sna->render.vbo == NULL) { diff --git a/src/sna/kgem.c b/src/sna/kgem.c index c5126450..1ff092cc 100644 --- a/src/sna/kgem.c +++ b/src/sna/kgem.c @@ -3648,7 +3648,8 @@ void _kgem_submit(struct kgem *kgem) kgem->exec[i].relocs_ptr = (uintptr_t)kgem->reloc; kgem->exec[i].alignment = 0; kgem->exec[i].offset = rq->bo->presumed_offset; - kgem->exec[i].flags = 0; + /* Make sure the kernel releases any fence, ignored if gen4+ */ + kgem->exec[i].flags = EXEC_OBJECT_NEEDS_FENCE; kgem->exec[i].rsvd1 = 0; kgem->exec[i].rsvd2 = 0; |