summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2020-10-21 14:40:29 +1000
committerDave Airlie <airlied@redhat.com>2020-10-22 10:11:49 +1000
commit6a6e5988a2657cd0c91f6f1a3e7d194599248b6d (patch)
tree72c3fe530998ab40e2ea678f21f93125a6ced31a /drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
parent439c3b01b87c39c3b61c841dee23c0337087dfcb (diff)
downloadlinux-6a6e5988a2657cd0c91f6f1a3e7d194599248b6d.tar.bz2
drm/ttm: replace last move_notify with delete_mem_notify
The move notify callback is only used in one place, this should be removed in the future, but for now just rename it to the use case which is to notify the driver that the GPU memory is to be deleted. Drivers can be cleaned up after this separately. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20201021044031.1752624-2-airlied@gmail.com
Diffstat (limited to 'drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c')
-rw-r--r--drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c b/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
index de25cf016be2..88be48ad0344 100644
--- a/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
+++ b/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
@@ -771,6 +771,12 @@ fail:
return ret;
}
+static void
+vmw_delete_mem_notify(struct ttm_buffer_object *bo)
+{
+ vmw_move_notify(bo, false, NULL);
+}
+
struct ttm_bo_driver vmw_bo_driver = {
.ttm_tt_create = &vmw_ttm_tt_create,
.ttm_tt_populate = &vmw_ttm_populate,
@@ -780,7 +786,7 @@ struct ttm_bo_driver vmw_bo_driver = {
.evict_flags = vmw_evict_flags,
.move = vmw_move,
.verify_access = vmw_verify_access,
- .move_notify = vmw_move_notify,
+ .delete_mem_notify = vmw_delete_mem_notify,
.swap_notify = vmw_swap_notify,
.io_mem_reserve = &vmw_ttm_io_mem_reserve,
};