]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
drm/i915: Compute and commit color features in fastsets
authorJosé Roberto de Souza <jose.souza@intel.com>
Fri, 8 Mar 2019 00:00:44 +0000 (16:00 -0800)
committerJosé Roberto de Souza <jose.souza@intel.com>
Fri, 8 Mar 2019 18:31:42 +0000 (10:31 -0800)
In any commit, intel_modeset_pipe_config() will initialilly clear
and then recalculate most of the pipe states but it leave intel
specific color features states in reset state.

If after intel_pipe_config_compare() is detected that a fastset is
possible it will mark update_pipe as true and unsed mode_changed,
causing the color features state to be kept in reset state and then
latter being committed to hardware disabling the color features.

This issue can be reproduced by any code patch that duplicates the
actual(with color features already enabled) state and only mark
mode_changed as true.

Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190308000050.6226-3-jose.souza@intel.com
drivers/gpu/drm/i915/intel_display.c

index 72c8d0b61672ff3399cc4812c714b957665dcfc0..36cfca01a36a622669c2d739cecac2f3edcc9fdf 100644 (file)
@@ -11202,7 +11202,8 @@ static int intel_crtc_atomic_check(struct drm_crtc *crtc,
                        return ret;
        }
 
-       if (mode_changed || crtc_state->color_mgmt_changed) {
+       if (mode_changed || pipe_config->update_pipe ||
+           crtc_state->color_mgmt_changed) {
                ret = intel_color_check(pipe_config);
                if (ret)
                        return ret;