aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/drivers/gpu/drm/drm_gem_vram_helper.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2020-09-17 13:20:48 +1000
committerDave Airlie <airlied@redhat.com>2020-09-18 06:14:41 +1000
commit7626168fd132009c79a0457bccc58014abc738f5 (patch)
tree963660ce229de967db864207c79d913b139f9cde /drivers/gpu/drm/drm_gem_vram_helper.c
parentdrm/ttm: protect against reentrant bind in the drivers (diff)
downloadwireguard-linux-7626168fd132009c79a0457bccc58014abc738f5.tar.xz
wireguard-linux-7626168fd132009c79a0457bccc58014abc738f5.zip
drm/ttm: flip tt destroy ordering.
Call the driver first and have it call the common code cleanup. This is useful later to fix unbind. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20200917043040.146575-3-airlied@gmail.com
Diffstat (limited to 'drivers/gpu/drm/drm_gem_vram_helper.c')
-rw-r--r--drivers/gpu/drm/drm_gem_vram_helper.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/drm_gem_vram_helper.c b/drivers/gpu/drm/drm_gem_vram_helper.c
index f96321509d7e..50cad0e4a92e 100644
--- a/drivers/gpu/drm/drm_gem_vram_helper.c
+++ b/drivers/gpu/drm/drm_gem_vram_helper.c
@@ -922,6 +922,7 @@ static const struct drm_gem_object_funcs drm_gem_vram_object_funcs = {
static void bo_driver_ttm_tt_destroy(struct ttm_bo_device *bdev, struct ttm_tt *tt)
{
+ ttm_tt_destroy_common(bdev, tt);
ttm_tt_fini(tt);
kfree(tt);
}