projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
17d33bc
)
drm/ttm: wait for BO idle after the move in ttm_bo_swapout
author
Christian König
<christian.koenig@amd.com>
Mon, 6 Jun 2016 08:17:57 +0000
(10:17 +0200)
committer
Alex Deucher
<alexander.deucher@amd.com>
Thu, 7 Jul 2016 18:54:37 +0000
(14:54 -0400)
Final part to avoid pre move waits.
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/ttm/ttm_bo.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/ttm/ttm_bo.c
b/drivers/gpu/drm/ttm/ttm_bo.c
index 86dd695021a6d436d8e924b10a9838082fd4a90e..c3c615c525a4a21d901d01e33760bd2b3cbe040e 100644
(file)
--- a/
drivers/gpu/drm/ttm/ttm_bo.c
+++ b/
drivers/gpu/drm/ttm/ttm_bo.c
@@
-1655,14
+1655,9
@@
static int ttm_bo_swapout(struct ttm_mem_shrink *shrink)
ttm_bo_list_ref_sub(bo, put_count, true);
/**
- *
Wait for GPU, then move to system cached.
+ *
Move to system cached
*/
- ret = ttm_bo_wait(bo, false, false);
-
- if (unlikely(ret != 0))
- goto out;
-
if ((bo->mem.placement & swap_placement) != swap_placement) {
struct ttm_mem_reg evict_mem;
@@
-1677,6
+1672,14
@@
static int ttm_bo_swapout(struct ttm_mem_shrink *shrink)
goto out;
}
+ /**
+ * Make sure BO is idle.
+ */
+
+ ret = ttm_bo_wait(bo, false, false);
+ if (unlikely(ret != 0))
+ goto out;
+
ttm_bo_unmap_virtual(bo);
/**