summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2010-03-03 10:07:27 -0800
committerEric Anholt <eric@anholt.net>2010-03-03 10:08:44 -0800
commit47102863eddee2fa6e28a922c072d0243ece6afd (patch)
treee72ea999e755e54370b01362450648674550ade4
parent766fa7909f3a1af27e60f3529a6a3318cc406f67 (diff)
intel: Update the needs_fence flag of buffers on the validate list.
Fixes fbo-copyteximage on i915 with texture tiling and execbuf2 fenced relocs.
-rw-r--r--intel/intel_bufmgr_gem.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/intel/intel_bufmgr_gem.c b/intel/intel_bufmgr_gem.c
index d40e95b6..7ccadd2f 100644
--- a/intel/intel_bufmgr_gem.c
+++ b/intel/intel_bufmgr_gem.c
@@ -383,8 +383,12 @@ drm_intel_add_validate_buffer2(drm_intel_bo *bo, int need_fence)
drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *)bo;
int index;
- if (bo_gem->validate_index != -1)
+ if (bo_gem->validate_index != -1) {
+ if (need_fence)
+ bufmgr_gem->exec2_objects[bo_gem->validate_index].flags |=
+ EXEC_OBJECT_NEEDS_FENCE;
return;
+ }
/* Extend the array of validation entries as necessary. */
if (bufmgr_gem->exec_count == bufmgr_gem->exec_size) {