[PATCH 7/9] drm/amdgpu:block kms open during gpu_reset

Christian König ckoenig.leichtzumerken at gmail.com
Thu Oct 26 07:18:18 UTC 2017


NAK, why the heck should we do this? It would just block all new 
processes from using the device.

Christian.

Am 25.10.2017 um 11:22 schrieb Monk Liu:
> Change-Id: Ibdb0ea9e3769d572fbbc13bbf1ef73f1af2ab7be
> Signed-off-by: Monk Liu <Monk.Liu at amd.com>
> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 3 +++
>   1 file changed, 3 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> index 4a9f749..c155ce4 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> @@ -813,6 +813,9 @@ int amdgpu_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv)
>   	if (r < 0)
>   		return r;
>   
> +	if (adev->in_gpu_reset)
> +		return -ENODEV;
> +
>   	fpriv = kzalloc(sizeof(*fpriv), GFP_KERNEL);
>   	if (unlikely(!fpriv)) {
>   		r = -ENOMEM;




More information about the amd-gfx mailing list