Don't create a ttm just to copy from.

This commit is contained in:
Thomas Hellstrom 2007-02-08 19:06:39 +01:00
parent bf8f46d4c6
commit a0ed808d05
2 changed files with 3 additions and 2 deletions

View file

@ -164,8 +164,7 @@ static int drm_bo_handle_move_mem(drm_buffer_object_t *bo,
if (ret)
return ret;
if ((!(old_man->flags & _DRM_FLAG_MEMTYPE_FIXED) ||
!(new_man->flags & _DRM_FLAG_MEMTYPE_FIXED)) &&
if (!(new_man->flags & _DRM_FLAG_MEMTYPE_FIXED) &&
(bo->ttm == NULL))
ret = drm_bo_add_ttm(bo);
if (ret)

View file

@ -219,6 +219,8 @@ int drm_bo_move_memcpy(drm_buffer_object_t *bo,
if (old_iomap == NULL && new_iomap == NULL)
goto out2;
if (old_iomap == NULL && ttm == NULL)
goto out2;
add = 0;
dir = 1;