summaryrefslogtreecommitdiff
path: root/src/gallium/winsys/drm/intel/gem/intel_drm_buffer.c
diff options
context:
space:
mode:
authorNicolai Hähnle <nhaehnle@gmail.com>2009-10-03 19:30:48 +0200
committerNicolai Hähnle <nhaehnle@gmail.com>2009-10-03 19:30:48 +0200
commit6d25b9125ec1e66e0e255b0ee20fe18dfe1076fa (patch)
treec376951940eac2875567979a81e6a03a019942b7 /src/gallium/winsys/drm/intel/gem/intel_drm_buffer.c
parent81c7561d9d3faf70ac22c6a5f3fbea18f53eed92 (diff)
parent7d2699aedc084d9cb9c2bd2f8bdb5f038271ac1e (diff)
Merge branch 'master' into r300-compiler
Diffstat (limited to 'src/gallium/winsys/drm/intel/gem/intel_drm_buffer.c')
-rw-r--r--src/gallium/winsys/drm/intel/gem/intel_drm_buffer.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/gallium/winsys/drm/intel/gem/intel_drm_buffer.c b/src/gallium/winsys/drm/intel/gem/intel_drm_buffer.c
index 0030f915a3..327e19fcd6 100644
--- a/src/gallium/winsys/drm/intel/gem/intel_drm_buffer.c
+++ b/src/gallium/winsys/drm/intel/gem/intel_drm_buffer.c
@@ -58,11 +58,17 @@ intel_drm_buffer_set_fence_reg(struct intel_winsys *iws,
unsigned stride,
enum intel_buffer_tile tile)
{
+ struct intel_drm_buffer *buf = intel_drm_buffer(buffer);
assert(I915_TILING_NONE == INTEL_TILE_NONE);
assert(I915_TILING_X == INTEL_TILE_X);
assert(I915_TILING_Y == INTEL_TILE_Y);
- return drm_intel_bo_set_tiling(intel_bo(buffer), &tile, stride);
+ if (tile != INTEL_TILE_NONE) {
+ assert(buf->map_count == 0);
+ buf->map_gtt = TRUE;
+ }
+
+ return drm_intel_bo_set_tiling(buf->bo, &tile, stride);
}
static void *