summaryrefslogtreecommitdiff
path: root/include/drm
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2020-08-04 12:56:08 +1000
committerDave Airlie <airlied@redhat.com>2020-08-06 12:32:03 +1000
commit0cf0a7984268c64e906b63a96df3e331ca61f989 (patch)
treed80bf1dda7f47d2cba366113ebaa3b00e98eb356 /include/drm
parent085097e5ae5e622358554ef773bccefb416b3df1 (diff)
drm/ttm: make TTM responsible for cleaning system only.
Drivers should all be cleaning up their memory managers themselves now, so let the core just clean the system one up. Remove the legacy cleaning interface. Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20200804025632.3868079-36-airlied@gmail.com
Diffstat (limited to 'include/drm')
-rw-r--r--include/drm/ttm/ttm_bo_api.h28
-rw-r--r--include/drm/ttm/ttm_bo_driver.h10
2 files changed, 0 insertions, 38 deletions
diff --git a/include/drm/ttm/ttm_bo_api.h b/include/drm/ttm/ttm_bo_api.h
index 56d207b983e9..045f283d79e8 100644
--- a/include/drm/ttm/ttm_bo_api.h
+++ b/include/drm/ttm/ttm_bo_api.h
@@ -547,34 +547,6 @@ void ttm_mem_type_manager_init(struct ttm_bo_device *bdev,
unsigned long p_size);
/**
- * ttm_bo_clean_mm
- *
- * @bdev: Pointer to a ttm_bo_device struct.
- * @mem_type: The memory type.
- *
- * Take down a manager for a given memory type after first walking
- * the LRU list to evict any buffers left alive.
- *
- * Normally, this function is part of lastclose() or unload(), and at that
- * point there shouldn't be any buffers left created by user-space, since
- * there should've been removed by the file descriptor release() method.
- * However, before this function is run, make sure to signal all sync objects,
- * and verify that the delayed delete queue is empty. The driver must also
- * make sure that there are no NO_EVICT buffers present in this memory type
- * when the call is made.
- *
- * If this function is part of a VT switch, the caller must make sure that
- * there are no appications currently validating buffers before this
- * function is called. The caller can do that by first taking the
- * struct ttm_bo_device::ttm_lock in write mode.
- *
- * Returns:
- * -EINVAL: invalid or uninitialized memory type.
- * -EBUSY: There are still buffers left in this memory type.
- */
-int ttm_bo_clean_mm(struct ttm_bo_device *bdev, unsigned mem_type);
-
-/**
* ttm_bo_evict_mm
*
* @bdev: Pointer to a ttm_bo_device struct.
diff --git a/include/drm/ttm/ttm_bo_driver.h b/include/drm/ttm/ttm_bo_driver.h
index 811ace1416b3..c76301a808ae 100644
--- a/include/drm/ttm/ttm_bo_driver.h
+++ b/include/drm/ttm/ttm_bo_driver.h
@@ -49,16 +49,6 @@ struct ttm_mem_type_manager;
struct ttm_mem_type_manager_func {
/**
- * struct ttm_mem_type_manager member takedown
- *
- * @man: Pointer to a memory type manager.
- *
- * Called to undo the setup done in init. All allocated resources
- * should be freed.
- */
- int (*takedown)(struct ttm_mem_type_manager *man);
-
- /**
* struct ttm_mem_type_manager member get_node
*
* @man: Pointer to a memory type manager.