]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/gpu/drm/nouveau/nouveau_bo.c
drm/nouveau: add instmem flush() hook
[karo-tx-linux.git] / drivers / gpu / drm / nouveau / nouveau_bo.c
index 9f5ab4677758e7ea1013a515ef9ff3f57379a8d7..3ca8343c15df9608c444140d9853603a94fd49a6 100644 (file)
@@ -461,9 +461,9 @@ nouveau_bo_move_accel_cleanup(struct nouveau_channel *chan,
                return ret;
 
        ret = ttm_bo_move_accel_cleanup(&nvbo->bo, fence, NULL,
-                                       evict, no_wait_reserve, no_wait_gpu, new_mem);
-       if (nvbo->channel && nvbo->channel != chan)
-               ret = nouveau_fence_wait(fence, NULL, false, false);
+                                       evict || (nvbo->channel &&
+                                                 nvbo->channel != chan),
+                                       no_wait_reserve, no_wait_gpu, new_mem);
        nouveau_fence_unref((void *)&fence);
        return ret;
 }
@@ -711,8 +711,7 @@ nouveau_bo_move(struct ttm_buffer_object *bo, bool evict, bool intr,
                return ret;
 
        /* Software copy if the card isn't up and running yet. */
-       if (dev_priv->init_state != NOUVEAU_CARD_INIT_DONE ||
-           !dev_priv->channel) {
+       if (!dev_priv->channel) {
                ret = ttm_bo_move_memcpy(bo, evict, no_wait_reserve, no_wait_gpu, new_mem);
                goto out;
        }