]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
drm/amdgpu: return from atombios_dp_get_dpcd only when error
authorArindam Nath <arindam.nath@amd.com>
Wed, 2 Mar 2016 11:49:01 +0000 (17:19 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 9 Mar 2016 23:34:52 +0000 (15:34 -0800)
commitf17a7e403d87e5ffb6c3598c9c562650ce70b392
treed83363f600428fd1abd9bc51ec7859fe77849b97
parent624a59a5d85f95c77fa99fd33ae7cea35bc062a5
drm/amdgpu: return from atombios_dp_get_dpcd only when error

commit 0b39c531cfa12dad54eac238c2e303b994df1ef7 upstream.

In amdgpu_connector_hotplug(), we need to start DP link
training only after we have received DPCD. The function
amdgpu_atombios_dp_get_dpcd() returns non-zero value only
when an error condition is met, otherwise returns zero.
So in case the function encounters an error, we need to
skip rest of the code and return from amdgpu_connector_hotplug()
immediately. Only when we are successfull in reading DPCD
pin, we should carry on with turning-on the monitor.

Signed-off-by: Arindam Nath <arindam.nath@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/amd/amdgpu/amdgpu_connectors.c