mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-29 10:01:25 +00:00
drm/radeon/kms: fix dp_detect handling for DP bridge chips
The HPD pin is not reliable for detecting whether a monitor is connected or not. Skip HPD and just use DDC or load detection. Fixes phantom VGA connected bugs. [Michel: fixes phantom VGA bugs on his llano system.] Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Michel Dänzer <michel.daenzer@amd.com> Tested-by: Michel Dänzer <michel.daenzer@amd.com> Cc: stable@kernel.org Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
4f332844cc
commit
6777a4f689
1 changed files with 6 additions and 15 deletions
|
@ -1303,23 +1303,14 @@ radeon_dp_detect(struct drm_connector *connector, bool force)
|
||||||
/* get the DPCD from the bridge */
|
/* get the DPCD from the bridge */
|
||||||
radeon_dp_getdpcd(radeon_connector);
|
radeon_dp_getdpcd(radeon_connector);
|
||||||
|
|
||||||
if (radeon_hpd_sense(rdev, radeon_connector->hpd.hpd))
|
if (encoder) {
|
||||||
ret = connector_status_connected;
|
/* setup ddc on the bridge */
|
||||||
else {
|
|
||||||
/* need to setup ddc on the bridge */
|
|
||||||
if (encoder)
|
|
||||||
radeon_atom_ext_encoder_setup_ddc(encoder);
|
radeon_atom_ext_encoder_setup_ddc(encoder);
|
||||||
if (radeon_ddc_probe(radeon_connector,
|
if (radeon_ddc_probe(radeon_connector,
|
||||||
radeon_connector->requires_extended_probe))
|
radeon_connector->requires_extended_probe)) /* try DDC */
|
||||||
ret = connector_status_connected;
|
ret = connector_status_connected;
|
||||||
}
|
else if (radeon_connector->dac_load_detect) { /* try load detection */
|
||||||
|
struct drm_encoder_helper_funcs *encoder_funcs = encoder->helper_private;
|
||||||
if ((ret == connector_status_disconnected) &&
|
|
||||||
radeon_connector->dac_load_detect) {
|
|
||||||
struct drm_encoder *encoder = radeon_best_single_encoder(connector);
|
|
||||||
struct drm_encoder_helper_funcs *encoder_funcs;
|
|
||||||
if (encoder) {
|
|
||||||
encoder_funcs = encoder->helper_private;
|
|
||||||
ret = encoder_funcs->detect(encoder, connector);
|
ret = encoder_funcs->detect(encoder, connector);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue