OSDN Git Service

intel: If the command is fenced inform the kernel
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 3 Dec 2010 10:48:12 +0000 (10:48 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 3 Dec 2010 10:51:49 +0000 (10:51 +0000)
... but only account for a fenced used if the object is tiled.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
intel/intel_bufmgr_gem.c

index 20fe075..797dcb3 100644 (file)
@@ -1303,6 +1303,7 @@ do_bo_emit_reloc(drm_intel_bo *bo, uint32_t offset,
        drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr;
        drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo;
        drm_intel_bo_gem *target_bo_gem = (drm_intel_bo_gem *) target_bo;
+       int fenced_command = need_fence;
 
        if (bo_gem->has_error)
                return -ENOMEM;
@@ -1356,7 +1357,7 @@ do_bo_emit_reloc(drm_intel_bo *bo, uint32_t offset,
        bo_gem->reloc_target_info[bo_gem->reloc_count].bo = target_bo;
        if (target_bo != bo)
                drm_intel_gem_bo_reference(target_bo);
-       if (need_fence)
+       if (fenced_command)
                bo_gem->reloc_target_info[bo_gem->reloc_count].flags =
                        DRM_INTEL_RELOC_FENCE;
        else