drm/radeon/kms: fix radeon_dp_get_modes for LVDS bridges
Subsystems (2)
PATCH 1/1 drm/radeon/kms: fix radeon_dp_get_modes for LVDS bridges
From: Alex Deucher <[email protected]>
Need to call ExternalEncoderControl to set up DDC before trying to get an EDID for all DP bridge chipsi (including DP to LVDS).
Also remove redundant encoder assignment.
--- drivers/gpu/drm/radeon/radeon_connectors.c | 25 +++++++++++++++++-------- 1 files changed, 17 insertions(+), 8 deletions(-)
drivers/gpu/drm/radeon/radeon_connectors.c +17 -8
@@ -1117,13 +1117,23 @@ static int radeon_dp_get_modes(struct drm_connector *connector) (connector->connector_type == DRM_MODE_CONNECTOR_LVDS)) {struct drm_display_mode *mode; -if (!radeon_dig_connector->edp_on) -atombios_set_edp_panel_power (connector, -ATOM_TRANSMITTER_ACTION_POWER_ON ); - ret =radeon_ddc_get_modes (radeon_connector); -if (!radeon_dig_connector->edp_on) -atombios_set_edp_panel_power (connector, -ATOM_TRANSMITTER_ACTION_POWER_OFF ); +if (connector->connector_type == DRM_MODE_CONNECTOR_eDP) { +if (!radeon_dig_connector->edp_on) +atombios_set_edp_panel_power (connector, +ATOM_TRANSMITTER_ACTION_POWER_ON ); + ret =radeon_ddc_get_modes (radeon_connector); +if (!radeon_dig_connector->edp_on) +atombios_set_edp_panel_power (connector, +ATOM_TRANSMITTER_ACTION_POWER_OFF ); + }else { +/* need to setup ddc on the bridge */ +if (radeon_connector_encoder_get_dp_bridge_encoder_id (connector) != +ENCODER_OBJECT_ID_NONE ) { +if (encoder) +radeon_atom_ext_encoder_setup_ddc (encoder); + } + ret =radeon_ddc_get_modes (radeon_connector); + }if (ret >0 ) {if (encoder) {
@@ -1134,7 +1144,6 @@ static int radeon_dp_get_modes(struct drm_connector *connector)return ret; } - encoder =radeon_best_single_encoder (connector);if (!encoder)return 0 ;
Signature · 1 line
1.7.7.5
Dear Alex,
Am Montag, den 27.02.2012, 19:31 -0500 schrieb [email protected]:
Quoted 4 lines
From: Alex Deucher <[email protected]>
Need to call ExternalEncoderControl to set up DDC before trying to get an EDID for all DP bridge chipsi (including
Should that be s/chipsi/chips/?
Quoted 8 lines
DP to LVDS).
Also remove redundant encoder assignment.
Signed-off-by Alex Deucher <[email protected]>--- drivers/gpu/drm/radeon/radeon_connectors.c | 25 +++++++++++++++++-------- 1 files changed, 17 insertions(+), 8 deletions(-)
[…]
Thanks,
Paul
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Quoted 10 lines · Paul Menzel
Dear Alex,
Am Montag, den 27.02.2012, 19:31 -0500 schrieb [email protected]:
Quoted 4 lines
From: Alex Deucher <[email protected]>
Need to call ExternalEncoderControl to set up DDC before trying to get an EDID for all DP bridge chipsi (including
Should that be
s/chipsi/chips/?
Yeah, should be chips.
Alex
Quoted 16 lines
Quoted 9 lines
DP to LVDS).
Also remove redundant encoder assignment.
Signed-off-by Alex Deucher <[email protected]>---
drivers/gpu/drm/radeon/radeon_connectors.c | 25 +++++++++++++++++--------1 files changed, 17 insertions(+), 8 deletions(-)[…]
Thanks,
Paul
PATCH 1/1 drm/radeon/kms: fix radeon_dp_get_modes for LVDS bridges (v2)
In reply to Paul MenzelFrom: Alex Deucher <[email protected]>
Need to call ExternalEncoderControl to set up DDC before trying to get an EDID for all DP bridge chips (including DP to LVDS).
Also remove redundant encoder assignment.
V2: fix typo in commit message.
--- drivers/gpu/drm/radeon/radeon_connectors.c | 25 +++++++++++++++++-------- 1 files changed, 17 insertions(+), 8 deletions(-)
drivers/gpu/drm/radeon/radeon_connectors.c +17 -8
@@ -1117,13 +1117,23 @@ static int radeon_dp_get_modes(struct drm_connector *connector) (connector->connector_type == DRM_MODE_CONNECTOR_LVDS)) {struct drm_display_mode *mode; -if (!radeon_dig_connector->edp_on) -atombios_set_edp_panel_power (connector, -ATOM_TRANSMITTER_ACTION_POWER_ON ); - ret =radeon_ddc_get_modes (radeon_connector); -if (!radeon_dig_connector->edp_on) -atombios_set_edp_panel_power (connector, -ATOM_TRANSMITTER_ACTION_POWER_OFF ); +if (connector->connector_type == DRM_MODE_CONNECTOR_eDP) { +if (!radeon_dig_connector->edp_on) +atombios_set_edp_panel_power (connector, +ATOM_TRANSMITTER_ACTION_POWER_ON ); + ret =radeon_ddc_get_modes (radeon_connector); +if (!radeon_dig_connector->edp_on) +atombios_set_edp_panel_power (connector, +ATOM_TRANSMITTER_ACTION_POWER_OFF ); + }else { +/* need to setup ddc on the bridge */ +if (radeon_connector_encoder_get_dp_bridge_encoder_id (connector) != +ENCODER_OBJECT_ID_NONE ) { +if (encoder) +radeon_atom_ext_encoder_setup_ddc (encoder); + } + ret =radeon_ddc_get_modes (radeon_connector); + }if (ret >0 ) {if (encoder) {
@@ -1134,7 +1144,6 @@ static int radeon_dp_get_modes(struct drm_connector *connector)return ret; } - encoder =radeon_best_single_encoder (connector);if (!encoder)return 0 ;
Signature · 1 line
1.7.7.5