2015-11-30, 23:58
Luckly i've patched kernel tree for 4.4-rc2 :-)
The only change i've made to original patch was in intel_hdmi.c - some variables were gone so i tried to adapt patch to this situation (with my not-high coding level ). Here is patch for intel_hdmi.c from 4.4-rc2 kernel. With this patch everything worked 100% as before:
The only change i've made to original patch was in intel_hdmi.c - some variables were gone so i tried to adapt patch to this situation (with my not-high coding level ). Here is patch for intel_hdmi.c from 4.4-rc2 kernel. With this patch everything worked 100% as before:
Code:
--- intel_hdmi.c 2015-11-23 01:45:59.000000000 +0100
+++ intel_hdmi_new.c 2015-11-30 22:54:09.875926639 +0100
@@ -464,7 +464,8 @@
}
if (intel_hdmi->rgb_quant_range_selectable) {
- if (intel_crtc->config->limited_color_range)
+ if (intel_crtc->config->limited_color_range ||
+ intel_crtc->config->video_color_range)
frame.avi.quantization_range =
HDMI_QUANTIZATION_RANGE_LIMITED;
else
@@ -1266,6 +1267,8 @@
pipe_config->limited_color_range =
intel_hdmi->limited_color_range;
}
+ if (intel_hdmi->color_range_video)
+ pipe_config->video_color_range = true;
if (adjusted_mode->flags & DRM_MODE_FLAG_DBLCLK) {
pipe_config->pixel_multiplier = 2;
@@ -1485,25 +1488,35 @@
if (property == dev_priv->broadcast_rgb_property) {
bool old_auto = intel_hdmi->color_range_auto;
bool old_range = intel_hdmi->limited_color_range;
+ bool old_range_video = intel_hdmi->color_range_video;
switch (val) {
case INTEL_BROADCAST_RGB_AUTO:
intel_hdmi->color_range_auto = true;
+ intel_hdmi->color_range_video = false;
break;
case INTEL_BROADCAST_RGB_FULL:
intel_hdmi->color_range_auto = false;
intel_hdmi->limited_color_range = false;
+ intel_hdmi->color_range_video = false;
break;
case INTEL_BROADCAST_RGB_LIMITED:
intel_hdmi->color_range_auto = false;
intel_hdmi->limited_color_range = true;
+ intel_hdmi->color_range_video = false;
+ break;
+ case INTEL_BROADCAST_RGB_VIDEO:
+ intel_hdmi->color_range_auto = false;
+ intel_hdmi->limited_color_range = true;
+ intel_hdmi->color_range_video = true;
break;
default:
return -EINVAL;
}
if (old_auto == intel_hdmi->color_range_auto &&
- old_range == intel_hdmi->limited_color_range)
+ old_range == intel_hdmi->limited_color_range &&
+ old_range_video == intel_hdmi->color_range_video)
return 0;
goto done;