diff mbox series

[v3,20/20] drm/i915: Do state check for color management changes

Message ID 20221114153732.11773-21-ville.syrjala@linux.intel.com (mailing list archive)
State New, archived
Headers show
Series drm/i915: Finish (de)gamma readout | expand

Commit Message

Ville Syrjälä Nov. 14, 2022, 3:37 p.m. UTC
From: Ville Syrjälä <ville.syrjala@linux.intel.com>

In order to validate LUT programming more thoroughly let's
do a state check for all color management updates as well.

Not sure we really want this outside CI. It is rather heavy
and color management updates could become rather common
with all the HDR/etc. stuff happening. Maybe we should have
an extra knob for this that we could enable in CI?

v2: Skip for initial_commit to avoid FDI dotclock
    sanity checks/etc. tripping up

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 drivers/gpu/drm/i915/display/intel_modeset_verify.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Shankar, Uma Nov. 18, 2022, 6:45 p.m. UTC | #1
> -----Original Message-----
> From: Intel-gfx <intel-gfx-bounces@lists.freedesktop.org> On Behalf Of Ville Syrjala
> Sent: Monday, November 14, 2022 9:08 PM
> To: intel-gfx@lists.freedesktop.org
> Subject: [Intel-gfx] [PATCH v3 20/20] drm/i915: Do state check for color
> management changes
> 
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> 
> In order to validate LUT programming more thoroughly let's do a state check for all
> color management updates as well.
> 
> Not sure we really want this outside CI. It is rather heavy and color management
> updates could become rather common with all the HDR/etc. stuff happening. Maybe
> we should have an extra knob for this that we could enable in CI?

Yeah for now it maybe not be that heavily used, but in future usage may increase.
I think we can have it enable via debugfs when we really need for testing and keep it
disabled as default. 

For now, looks good.
Reviewed-by: Uma Shankar <uma.shankar@intel.com>

> v2: Skip for initial_commit to avoid FDI dotclock
>     sanity checks/etc. tripping up
> 
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
>  drivers/gpu/drm/i915/display/intel_modeset_verify.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/gpu/drm/i915/display/intel_modeset_verify.c
> b/drivers/gpu/drm/i915/display/intel_modeset_verify.c
> index 842d70f0dfd2..9e4767e1b900 100644
> --- a/drivers/gpu/drm/i915/display/intel_modeset_verify.c
> +++ b/drivers/gpu/drm/i915/display/intel_modeset_verify.c
> @@ -228,6 +228,8 @@ void intel_modeset_verify_crtc(struct intel_crtc *crtc,
>  			       struct intel_crtc_state *new_crtc_state)  {
>  	if (!intel_crtc_needs_modeset(new_crtc_state) &&
> +	    (!intel_crtc_needs_color_update(new_crtc_state) ||
> +	     new_crtc_state->inherited) &&
>  	    !intel_crtc_needs_fastset(new_crtc_state))
>  		return;
> 
> --
> 2.37.4
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/display/intel_modeset_verify.c b/drivers/gpu/drm/i915/display/intel_modeset_verify.c
index 842d70f0dfd2..9e4767e1b900 100644
--- a/drivers/gpu/drm/i915/display/intel_modeset_verify.c
+++ b/drivers/gpu/drm/i915/display/intel_modeset_verify.c
@@ -228,6 +228,8 @@  void intel_modeset_verify_crtc(struct intel_crtc *crtc,
 			       struct intel_crtc_state *new_crtc_state)
 {
 	if (!intel_crtc_needs_modeset(new_crtc_state) &&
+	    (!intel_crtc_needs_color_update(new_crtc_state) ||
+	     new_crtc_state->inherited) &&
 	    !intel_crtc_needs_fastset(new_crtc_state))
 		return;