]> Git Repo - linux.git/blobdiff - drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
Merge remote-tracking branches 'asoc/topic/davinci', 'asoc/topic/debugfs', 'asoc...
[linux.git] / drivers / gpu / drm / amd / amdgpu / amdgpu_cs.c
index bdef497a6a26253e3edbb216e76351b6c5fd7234..57abf7abd7a9cda177e9e82c6c5e42d3dc759f6d 100644 (file)
@@ -409,6 +409,10 @@ static bool amdgpu_cs_try_evict(struct amdgpu_cs_parser *p,
                if (candidate->robj == validated)
                        break;
 
+               /* We can't move pinned BOs here */
+               if (bo->pin_count)
+                       continue;
+
                other = amdgpu_mem_type_to_domain(bo->tbo.mem.mem_type);
 
                /* Check if this BO is in one of the domains we need space for */
@@ -562,8 +566,7 @@ static int amdgpu_cs_parser_bos(struct amdgpu_cs_parser *p,
                                 * invalidated it. Free it and try again
                                 */
                                release_pages(e->user_pages,
-                                             bo->tbo.ttm->num_pages,
-                                             false);
+                                             bo->tbo.ttm->num_pages);
                                kvfree(e->user_pages);
                                e->user_pages = NULL;
                        }
@@ -694,8 +697,7 @@ error_free_pages:
                                continue;
 
                        release_pages(e->user_pages,
-                                     e->robj->tbo.ttm->num_pages,
-                                     false);
+                                     e->robj->tbo.ttm->num_pages);
                        kvfree(e->user_pages);
                }
        }
This page took 0.045102 seconds and 4 git commands to generate.