mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-27 17:11:46 +00:00
drm/radeon: retry dcpd fetch
Retry the dpcd fetch several times. Some eDP panels fail several times before the fetch is successful. bug: https://bugs.freedesktop.org/show_bug.cgi?id=73530 Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
This commit is contained in:
parent
755c814a7d
commit
0f28d1281b
1 changed files with 11 additions and 9 deletions
|
@ -421,19 +421,21 @@ bool radeon_dp_getdpcd(struct radeon_connector *radeon_connector)
|
||||||
{
|
{
|
||||||
struct radeon_connector_atom_dig *dig_connector = radeon_connector->con_priv;
|
struct radeon_connector_atom_dig *dig_connector = radeon_connector->con_priv;
|
||||||
u8 msg[DP_DPCD_SIZE];
|
u8 msg[DP_DPCD_SIZE];
|
||||||
int ret;
|
int ret, i;
|
||||||
|
|
||||||
ret = drm_dp_dpcd_read(&radeon_connector->ddc_bus->aux, DP_DPCD_REV, msg,
|
for (i = 0; i < 7; i++) {
|
||||||
DP_DPCD_SIZE);
|
ret = drm_dp_dpcd_read(&radeon_connector->ddc_bus->aux, DP_DPCD_REV, msg,
|
||||||
if (ret > 0) {
|
DP_DPCD_SIZE);
|
||||||
memcpy(dig_connector->dpcd, msg, DP_DPCD_SIZE);
|
if (ret == DP_DPCD_SIZE) {
|
||||||
|
memcpy(dig_connector->dpcd, msg, DP_DPCD_SIZE);
|
||||||
|
|
||||||
DRM_DEBUG_KMS("DPCD: %*ph\n", (int)sizeof(dig_connector->dpcd),
|
DRM_DEBUG_KMS("DPCD: %*ph\n", (int)sizeof(dig_connector->dpcd),
|
||||||
dig_connector->dpcd);
|
dig_connector->dpcd);
|
||||||
|
|
||||||
radeon_dp_probe_oui(radeon_connector);
|
radeon_dp_probe_oui(radeon_connector);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
dig_connector->dpcd[0] = 0;
|
dig_connector->dpcd[0] = 0;
|
||||||
return false;
|
return false;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue