diff options
Diffstat (limited to 'src/gallium/winsys/drm/intel/gem')
-rw-r--r-- | src/gallium/winsys/drm/intel/gem/intel_be_batchbuffer.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/gallium/winsys/drm/intel/gem/intel_be_batchbuffer.c b/src/gallium/winsys/drm/intel/gem/intel_be_batchbuffer.c index e83a4c42cd..b7bc3ee1c9 100644 --- a/src/gallium/winsys/drm/intel/gem/intel_be_batchbuffer.c +++ b/src/gallium/winsys/drm/intel/gem/intel_be_batchbuffer.c @@ -66,13 +66,15 @@ intel_be_offset_relocation(struct intel_be_batchbuffer *batch, assert(batch->base.relocs < batch->base.max_relocs); offset = (unsigned)(batch->base.ptr - batch->base.map); - batch->base.ptr += 4; - ret = drm_intel_bo_emit_reloc(bo, pre_add, - batch->bo, offset, + ret = drm_intel_bo_emit_reloc(batch->bo, offset, + bo, pre_add, read_domains, write_domain); + ((uint32_t*)batch->base.ptr)[0] = bo->offset = pre_add; + batch->base.ptr += 4; + if (!ret) batch->base.relocs++; |