aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/radeon_ttm.c
diff options
context:
space:
mode:
authorChristian König <deathsimple@vodafone.de>2011-10-13 07:19:22 -0400
committerDave Airlie <airlied@redhat.com>2011-12-20 14:50:10 -0500
commitbf85279958da96cb4b11aac89b34f0424c3c120e (patch)
tree1d0197a268a642ee02ebe1a22d8f5ac0e7798494 /drivers/gpu/drm/radeon/radeon_ttm.c
parent5596a9db156107b01ceb7db4d50cc091117da627 (diff)
drm/radeon: make cp variable an array
Replace cp, cp1 and cp2 members with just an array of radeon_cp structs. Signed-off-by: Christian König <deathsimple@vodafone.de> Reviewed-by: Jerome Glisse <jglisse@redhat.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_ttm.c')
-rw-r--r--drivers/gpu/drm/radeon/radeon_ttm.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon/radeon_ttm.c
index 112ecaa6362b..0be15bf38d3c 100644
--- a/drivers/gpu/drm/radeon/radeon_ttm.c
+++ b/drivers/gpu/drm/radeon/radeon_ttm.c
@@ -188,7 +188,7 @@ static void radeon_evict_flags(struct ttm_buffer_object *bo,
188 rbo = container_of(bo, struct radeon_bo, tbo); 188 rbo = container_of(bo, struct radeon_bo, tbo);
189 switch (bo->mem.mem_type) { 189 switch (bo->mem.mem_type) {
190 case TTM_PL_VRAM: 190 case TTM_PL_VRAM:
191 if (rbo->rdev->cp.ready == false) 191 if (rbo->rdev->cp[RADEON_RING_TYPE_GFX_INDEX].ready == false)
192 radeon_ttm_placement_from_domain(rbo, RADEON_GEM_DOMAIN_CPU); 192 radeon_ttm_placement_from_domain(rbo, RADEON_GEM_DOMAIN_CPU);
193 else 193 else
194 radeon_ttm_placement_from_domain(rbo, RADEON_GEM_DOMAIN_GTT); 194 radeon_ttm_placement_from_domain(rbo, RADEON_GEM_DOMAIN_GTT);
@@ -255,7 +255,7 @@ static int radeon_move_blit(struct ttm_buffer_object *bo,
255 DRM_ERROR("Unknown placement %d\n", old_mem->mem_type); 255 DRM_ERROR("Unknown placement %d\n", old_mem->mem_type);
256 return -EINVAL; 256 return -EINVAL;
257 } 257 }
258 if (!rdev->cp.ready) { 258 if (!rdev->cp[RADEON_RING_TYPE_GFX_INDEX].ready) {
259 DRM_ERROR("Trying to move memory with CP turned off.\n"); 259 DRM_ERROR("Trying to move memory with CP turned off.\n");
260 return -EINVAL; 260 return -EINVAL;
261 } 261 }
@@ -380,7 +380,7 @@ static int radeon_bo_move(struct ttm_buffer_object *bo,
380 radeon_move_null(bo, new_mem); 380 radeon_move_null(bo, new_mem);
381 return 0; 381 return 0;
382 } 382 }
383 if (!rdev->cp.ready || rdev->asic->copy == NULL) { 383 if (!rdev->cp[RADEON_RING_TYPE_GFX_INDEX].ready || rdev->asic->copy == NULL) {
384 /* use memcpy */ 384 /* use memcpy */
385 goto memcpy; 385 goto memcpy;
386 } 386 }