From: Jim Qu Date: Wed, 1 Mar 2017 07:53:29 +0000 (+0800) Subject: drm/amd/amdgpu: fix console deadlock if late init failed X-Git-Tag: v4.11-rc2~13^2~5^2~2 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=c085bd5119d5d0bdf3ef591a5563566be7dedced;p=karo-tx-linux.git drm/amd/amdgpu: fix console deadlock if late init failed Signed-off-by: Jim Qu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index 6abb238b25c9..4120b351a8e5 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c @@ -2094,8 +2094,11 @@ int amdgpu_device_resume(struct drm_device *dev, bool resume, bool fbcon) } r = amdgpu_late_init(adev); - if (r) + if (r) { + if (fbcon) + console_unlock(); return r; + } /* pin cursors */ list_for_each_entry(crtc, &dev->mode_config.crtc_list, head) {