Skip to content

Commit

Permalink
drm/radeon: fix HDMI quantization_range for pre-DCE5 asics
Browse files Browse the repository at this point in the history
Support for output_csc is only available on DCE5 and newer so
don't mess with the HDMI quantization_range on pre-DCE5 asics.

bug:
https://bugs.freedesktop.org/show_bug.cgi?id=83226

Signed-off-by: Alex Deucher <[email protected]>
Cc: [email protected]
  • Loading branch information
alexdeucher committed Aug 28, 2015
1 parent 92cffd5 commit 86b7709
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions drivers/gpu/drm/radeon/radeon_audio.c
Original file line number Diff line number Diff line change
Expand Up @@ -522,13 +522,15 @@ static int radeon_audio_set_avi_packet(struct drm_encoder *encoder,
return err;
}

if (drm_rgb_quant_range_selectable(radeon_connector_edid(connector))) {
if (radeon_encoder->output_csc == RADEON_OUTPUT_CSC_TVRGB)
frame.quantization_range = HDMI_QUANTIZATION_RANGE_LIMITED;
else
frame.quantization_range = HDMI_QUANTIZATION_RANGE_FULL;
} else {
frame.quantization_range = HDMI_QUANTIZATION_RANGE_DEFAULT;
if (radeon_encoder->output_csc != RADEON_OUTPUT_CSC_BYPASS) {
if (drm_rgb_quant_range_selectable(radeon_connector_edid(connector))) {
if (radeon_encoder->output_csc == RADEON_OUTPUT_CSC_TVRGB)
frame.quantization_range = HDMI_QUANTIZATION_RANGE_LIMITED;
else
frame.quantization_range = HDMI_QUANTIZATION_RANGE_FULL;
} else {
frame.quantization_range = HDMI_QUANTIZATION_RANGE_DEFAULT;
}
}

err = hdmi_avi_infoframe_pack(&frame, buffer, sizeof(buffer));
Expand Down

0 comments on commit 86b7709

Please sign in to comment.