diff mbox series

[2/2] drm/exynos: mixer: Use colorimetry helper function

Message ID 1543579332-16609-3-git-send-email-c.manszewski@samsung.com (mailing list archive)
State New, archived
Headers show
Series [1/2] drm/edid: Add colorimetry helper function | expand

Commit Message

Christoph Manszewski Nov. 30, 2018, 12:02 p.m. UTC
Use drm_default_colorimetry helper function to determine the default
colorspace type (ITU-R BT.601 or ITU-R BT.709).

Signed-off-by: Christoph Manszewski <c.manszewski@samsung.com>
---
 drivers/gpu/drm/exynos/exynos_mixer.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/gpu/drm/exynos/exynos_mixer.c b/drivers/gpu/drm/exynos/exynos_mixer.c
index 2a25822bd6a1..895c6268025d 100644
--- a/drivers/gpu/drm/exynos/exynos_mixer.c
+++ b/drivers/gpu/drm/exynos/exynos_mixer.c
@@ -384,9 +384,10 @@  static void mixer_cfg_scan(struct mixer_context *ctx, int width, int height)
 static void mixer_cfg_rgb_fmt(struct mixer_context *ctx, struct drm_display_mode *mode)
 {
 	enum hdmi_quantization_range range = drm_default_rgb_quant_range(mode);
+	enum hdmi_colorimetry format = drm_default_colorimetry(mode);
 	u32 val;
 
-	if (mode->vdisplay < 720) {
+	if (format == HDMI_COLORIMETRY_ITU_601) {
 		val = MXR_CFG_RGB601;
 	} else {
 		val = MXR_CFG_RGB709;