> -----Original Message-----
> From: amd-gfx [mailto:[email protected]] On Behalf
> Of Xiangliang Yu
> Sent: Thursday, May 04, 2017 2:34 AM
> To: [email protected]
> Cc: Ding, Pixel; Yu, Xiangliang
> Subject: [PATCH 1/6] drm/amdgpu: fix mutex list null pointer reference
> 
> From: Pixel Ding <[email protected]>
> 
> Fix NULL pointer reference.
> 
> Signed-off-by: Pixel Ding <[email protected]>
> Signed-off-by: Xiangliang Yu <[email protected]>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> index e685ca9..aef2019 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> @@ -2118,7 +2118,8 @@ void amdgpu_device_fini(struct amdgpu_device
> *adev)
> 
>       DRM_INFO("amdgpu: finishing device.\n");
>       adev->shutdown = true;
> -     drm_crtc_force_disable_all(adev->ddev);
> +     if (adev->ddev->mode_config.funcs)
> +             drm_crtc_force_disable_all(adev->ddev);

For consistency, I think we generally check for 
adev->mode_info.mode_confg_initialized or adev->mode_info.num_crtc.  Either way:
Reviewed-by: Alex Deucher <[email protected]>

>       /* evict vram memory */
>       amdgpu_bo_evict_vram(adev);
>       amdgpu_ib_pool_fini(adev);
> --
> 2.7.4
> 
> _______________________________________________
> amd-gfx mailing list
> [email protected]
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

Reply via email to