drm/radeon/kms: do not force DVI mode on DCE4 if audio is on
Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
54ac76f851
commit
f92e70cae8
|
@ -409,8 +409,6 @@ int
|
|||
atombios_get_encoder_mode(struct drm_encoder *encoder)
|
||||
{
|
||||
struct radeon_encoder *radeon_encoder = to_radeon_encoder(encoder);
|
||||
struct drm_device *dev = encoder->dev;
|
||||
struct radeon_device *rdev = dev->dev_private;
|
||||
struct drm_connector *connector;
|
||||
struct radeon_connector *radeon_connector;
|
||||
struct radeon_connector_atom_dig *dig_connector;
|
||||
|
@ -434,13 +432,10 @@ atombios_get_encoder_mode(struct drm_encoder *encoder)
|
|||
switch (connector->connector_type) {
|
||||
case DRM_MODE_CONNECTOR_DVII:
|
||||
case DRM_MODE_CONNECTOR_HDMIB: /* HDMI-B is basically DL-DVI; analog works fine */
|
||||
if (drm_detect_monitor_audio(radeon_connector->edid) && radeon_audio) {
|
||||
/* fix me */
|
||||
if (ASIC_IS_DCE4(rdev))
|
||||
return ATOM_ENCODER_MODE_DVI;
|
||||
else
|
||||
return ATOM_ENCODER_MODE_HDMI;
|
||||
} else if (radeon_connector->use_digital)
|
||||
if (drm_detect_monitor_audio(radeon_connector->edid) &&
|
||||
radeon_audio)
|
||||
return ATOM_ENCODER_MODE_HDMI;
|
||||
else if (radeon_connector->use_digital)
|
||||
return ATOM_ENCODER_MODE_DVI;
|
||||
else
|
||||
return ATOM_ENCODER_MODE_CRT;
|
||||
|
@ -448,13 +443,10 @@ atombios_get_encoder_mode(struct drm_encoder *encoder)
|
|||
case DRM_MODE_CONNECTOR_DVID:
|
||||
case DRM_MODE_CONNECTOR_HDMIA:
|
||||
default:
|
||||
if (drm_detect_monitor_audio(radeon_connector->edid) && radeon_audio) {
|
||||
/* fix me */
|
||||
if (ASIC_IS_DCE4(rdev))
|
||||
return ATOM_ENCODER_MODE_DVI;
|
||||
else
|
||||
return ATOM_ENCODER_MODE_HDMI;
|
||||
} else
|
||||
if (drm_detect_monitor_audio(radeon_connector->edid) &&
|
||||
radeon_audio)
|
||||
return ATOM_ENCODER_MODE_HDMI;
|
||||
else
|
||||
return ATOM_ENCODER_MODE_DVI;
|
||||
break;
|
||||
case DRM_MODE_CONNECTOR_LVDS:
|
||||
|
@ -465,13 +457,10 @@ atombios_get_encoder_mode(struct drm_encoder *encoder)
|
|||
if ((dig_connector->dp_sink_type == CONNECTOR_OBJECT_ID_DISPLAYPORT) ||
|
||||
(dig_connector->dp_sink_type == CONNECTOR_OBJECT_ID_eDP))
|
||||
return ATOM_ENCODER_MODE_DP;
|
||||
else if (drm_detect_monitor_audio(radeon_connector->edid) && radeon_audio) {
|
||||
/* fix me */
|
||||
if (ASIC_IS_DCE4(rdev))
|
||||
return ATOM_ENCODER_MODE_DVI;
|
||||
else
|
||||
return ATOM_ENCODER_MODE_HDMI;
|
||||
} else
|
||||
else if (drm_detect_monitor_audio(radeon_connector->edid) &&
|
||||
radeon_audio)
|
||||
return ATOM_ENCODER_MODE_HDMI;
|
||||
else
|
||||
return ATOM_ENCODER_MODE_DVI;
|
||||
break;
|
||||
case DRM_MODE_CONNECTOR_eDP:
|
||||
|
|
Loading…
Reference in New Issue