[PATCH 3/3] drm/amdgpu: stop evicting encrypted BOs to swap
Alex Deucher
alexdeucher at gmail.com
Mon Mar 2 21:37:17 UTC 2020
On Mon, Mar 2, 2020 at 7:18 AM Christian König
<ckoenig.leichtzumerken at gmail.com> wrote:
>
> Swapping out encrypted BOs doesn't work because they can't change
> their physical location without going through a bounce copy.
>
> As a workaround disable evicting encrypted BOs to the system
> domain for now.
>
> Signed-off-by: Christian König <christian.koenig at amd.com>
Series is:
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> index 25d3b93f446e..96d97523da65 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> @@ -1552,6 +1552,9 @@ static bool amdgpu_ttm_bo_eviction_valuable(struct ttm_buffer_object *bo,
>
> switch (bo->mem.mem_type) {
> case TTM_PL_TT:
> + if (amdgpu_bo_is_amdgpu_bo(bo) &&
> + amdgpu_bo_encrypted(ttm_to_amdgpu_bo(bo)))
> + return false;
> return true;
>
> case TTM_PL_VRAM:
> --
> 2.17.1
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
More information about the amd-gfx
mailing list