mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-28 05:06:43 +00:00
i915: Redo limited passthrough patch (verified working by user)
This commit is contained in:
parent
dfe3422281
commit
c614217b1c
@ -1,15 +1,14 @@
|
|||||||
From 72d030ffa118d6981cb678dae0b97dea77f14b4c Mon Sep 17 00:00:00 2001
|
From 7fa7c0b24aa134d5fdb65dc2a984c734b499f70e Mon Sep 17 00:00:00 2001
|
||||||
From: fritsch <peter.fruehberger@gmail.com>
|
From: fritsch <peter.fruehberger@gmail.com>
|
||||||
Date: Sun, 29 Nov 2015 16:38:14 +0100
|
Date: Sun, 29 Nov 2015 16:38:14 +0100
|
||||||
Subject: [PATCH] Intel: Implement Video Color Range
|
Subject: [PATCH] Intel: Implement Video Color Range (testing)
|
||||||
|
|
||||||
---
|
---
|
||||||
drivers/gpu/drm/i915/i915_drv.h | 1 +
|
drivers/gpu/drm/i915/i915_drv.h | 1 +
|
||||||
drivers/gpu/drm/i915/intel_display.c | 4 ++--
|
drivers/gpu/drm/i915/intel_drv.h | 8 ++++++++
|
||||||
drivers/gpu/drm/i915/intel_drv.h | 8 ++++++++
|
drivers/gpu/drm/i915/intel_hdmi.c | 17 +++++++++++++++--
|
||||||
drivers/gpu/drm/i915/intel_hdmi.c | 17 +++++++++++++++--
|
drivers/gpu/drm/i915/intel_modes.c | 1 +
|
||||||
drivers/gpu/drm/i915/intel_modes.c | 1 +
|
4 files changed, 25 insertions(+), 2 deletions(-)
|
||||||
5 files changed, 27 insertions(+), 4 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
|
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
|
||||||
index a01e515..9e4b8d0 100644
|
index a01e515..9e4b8d0 100644
|
||||||
@ -23,28 +22,6 @@ index a01e515..9e4b8d0 100644
|
|||||||
|
|
||||||
static inline uint32_t i915_vgacntrl_reg(struct drm_device *dev)
|
static inline uint32_t i915_vgacntrl_reg(struct drm_device *dev)
|
||||||
{
|
{
|
||||||
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
|
|
||||||
index 22e86d2..5d86734 100644
|
|
||||||
--- a/drivers/gpu/drm/i915/intel_display.c
|
|
||||||
+++ b/drivers/gpu/drm/i915/intel_display.c
|
|
||||||
@@ -8655,7 +8655,7 @@ static void intel_set_pipe_csc(struct drm_crtc *crtc)
|
|
||||||
* consideration.
|
|
||||||
*/
|
|
||||||
|
|
||||||
- if (intel_crtc->config->limited_color_range)
|
|
||||||
+ if (intel_crtc->config->limited_color_range && !intel_crtc->config->video_color_range)
|
|
||||||
coeff = ((235 - 16) * (1 << 12) / 255) & 0xff8; /* 0.xxx... */
|
|
||||||
|
|
||||||
/*
|
|
||||||
@@ -8679,7 +8679,7 @@ static void intel_set_pipe_csc(struct drm_crtc *crtc)
|
|
||||||
if (INTEL_INFO(dev)->gen > 6) {
|
|
||||||
uint16_t postoff = 0;
|
|
||||||
|
|
||||||
- if (intel_crtc->config->limited_color_range)
|
|
||||||
+ if (intel_crtc->config->limited_color_range && !intel_crtc->config->video_color_range)
|
|
||||||
postoff = (16 * (1 << 12) / 255) & 0x1fff;
|
|
||||||
|
|
||||||
I915_WRITE(PIPE_CSC_POSTOFF_HI(pipe), postoff);
|
|
||||||
diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
|
diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
|
||||||
index f2a1142..210e7a7 100644
|
index f2a1142..210e7a7 100644
|
||||||
--- a/drivers/gpu/drm/i915/intel_drv.h
|
--- a/drivers/gpu/drm/i915/intel_drv.h
|
||||||
@ -72,7 +49,7 @@ index f2a1142..210e7a7 100644
|
|||||||
bool has_audio;
|
bool has_audio;
|
||||||
enum hdmi_force_audio force_audio;
|
enum hdmi_force_audio force_audio;
|
||||||
diff --git a/drivers/gpu/drm/i915/intel_hdmi.c b/drivers/gpu/drm/i915/intel_hdmi.c
|
diff --git a/drivers/gpu/drm/i915/intel_hdmi.c b/drivers/gpu/drm/i915/intel_hdmi.c
|
||||||
index 81cdd9f..741bf89 100644
|
index 81cdd9f..417f9be 100644
|
||||||
--- a/drivers/gpu/drm/i915/intel_hdmi.c
|
--- a/drivers/gpu/drm/i915/intel_hdmi.c
|
||||||
+++ b/drivers/gpu/drm/i915/intel_hdmi.c
|
+++ b/drivers/gpu/drm/i915/intel_hdmi.c
|
||||||
@@ -464,7 +464,8 @@ static void intel_hdmi_set_avi_infoframe(struct drm_encoder *encoder,
|
@@ -464,7 +464,8 @@ static void intel_hdmi_set_avi_infoframe(struct drm_encoder *encoder,
|
||||||
@ -117,7 +94,7 @@ index 81cdd9f..741bf89 100644
|
|||||||
+ break;
|
+ break;
|
||||||
+ case INTEL_BROADCAST_RGB_VIDEO:
|
+ case INTEL_BROADCAST_RGB_VIDEO:
|
||||||
+ intel_hdmi->color_range_auto = false;
|
+ intel_hdmi->color_range_auto = false;
|
||||||
+ intel_hdmi->limited_color_range = true;
|
+ intel_hdmi->limited_color_range = false;
|
||||||
+ intel_hdmi->color_range_video = true;
|
+ intel_hdmi->color_range_video = true;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@ -145,4 +122,3 @@ index 38a4c8c..c49681a 100644
|
|||||||
void
|
void
|
||||||
--
|
--
|
||||||
2.5.0
|
2.5.0
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user