Skip to content
Commit 8c8c0620 authored by Ahzo's avatar Ahzo Committed by Christian König
Browse files

drm/ttm: fix leaking fences via ttm_buffer_object_transfer

Set the drm_device to NULL, so that the newly created buffer object
doesn't appear to use the embedded gem object.

This is necessary, because otherwise no corresponding dma_resv_fini for
the dma_resv_init is called, resulting in a memory leak.

The dma_resv_fini in ttm_bo_release_list is only called if the embedded
gem object is not used, which is determined by checking if the
drm_device is NULL.

Bug: https://gitlab.freedesktop.org/drm/amd/issues/958


Fixes: 1e053b10 ("drm/ttm: use gem reservation object")
Reviewed-by: default avatarChristian König <christian.koenig@amd.com>
Signed-off-by: default avatarAhzo <Ahzo@tutanota.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarChristian König <christian.koenig@amd.com>
Link: https://patchwork.freedesktop.org/patch/355089/
parent eb9d8ddb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment