[PATCH xf86-video-amdgpu] Only call drmmode_scanout_free for non-GPU screens in LeaveVT

Alex Deucher alexdeucher at gmail.com
Tue Jun 27 13:46:52 UTC 2017


On Tue, Jun 27, 2017 at 5:18 AM, Michel Dänzer <michel at daenzer.net> wrote:
> From: Michel Dänzer <michel.daenzer at amd.com>
>
> Destroying the scanout buffers of GPU screens resulted in a crash when
> switching back to the Xorg VT.
>
> Fixes: b10ecdbd89b0 ("Use drmmode_crtc_scanout_* helpers for RandR 1.4
>                       scanout pixmaps")
> (Ported from radeon commit c9dd28cb0c9c3de676eadac61e727732510f6b9b)
>
> Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>

Reviewed-by: Alex Deucher <alexander.deucher at amd.com>

> ---
>  src/amdgpu_kms.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/src/amdgpu_kms.c b/src/amdgpu_kms.c
> index 143294a9f..b625250fd 100644
> --- a/src/amdgpu_kms.c
> +++ b/src/amdgpu_kms.c
> @@ -1975,7 +1975,8 @@ void AMDGPULeaveVT_KMS(VT_FUNC_ARGS_DECL)
>         amdgpu_drop_drm_master(pScrn);
>
>         xf86RotateFreeShadow(pScrn);
> -       drmmode_scanout_free(pScrn);
> +       if (!pScrn->is_gpu)
> +               drmmode_scanout_free(pScrn);
>
>         xf86_hide_cursors(pScrn);
>
> --
> 2.13.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