[Intel-gfx] [PATCH 1/2] drm/i915: Force a LUT update in intel_initial_commit()

Hans de Goede hdegoede at redhat.com
Tue Nov 20 18:34:09 UTC 2018


Hi Ville,

On 20-11-18 14:54, Ville Syrjala wrote:
> From: Ville Syrjälä <ville.syrjala at linux.intel.com>
> 
> If we force a plane update to fix up our half populated plane state
> we'll also force on the pipe gamma for the plane (since we always
> enable pipe gamma currently). If the BIOS hasn't programmed a sensible
> LUT into the hardware this will cause the image to become corrupted.
> Typical symptoms are a purple/yellow/etc. flash when the driver loads.
> 
> To avoid this let's program something sensible into the LUT when
> we do the plane update. In the future I plan to add proper plane
> gamma enable readout so this is just a temporary measure.
> 
> Cc: Hans de Goede <hdegoede at redhat.com>
> Fixes: 516a49cc1946 ("drm/i915: Fix assert_plane() warning on bootup with external display")
> Signed-off-by: Ville Syrjälä <ville.syrjala at linux.intel.com>

I can confirm that this series fixes the purple flash I was seeing on
DSI panels.

And the reporter in bug https://bugs.freedesktop.org/show_bug.cgi?id=108225
has also just reported back that the blanking he was seeing which was
also caused by the "drm/i915: Fix assert_plane() warning on bootup with external display"
commit is also fixed, so it looks like this series is good to go:

Tested-by: Hans de Goede <hdegoede at redhat.com>

Regards,

Hans




> ---
>   drivers/gpu/drm/i915/intel_display.c | 8 ++++++++
>   1 file changed, 8 insertions(+)
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 132e978227fb..60c1e54285c1 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -15011,6 +15011,14 @@ static int intel_initial_commit(struct drm_device *dev)
>   			ret = drm_atomic_add_affected_planes(state, crtc);
>   			if (ret)
>   				goto out;
> +
> +			/*
> +			 * FIXME hack to force a LUT update to avoid the
> +			 * plane update forcing the pipe gamma on without
> +			 * having a proper LUT loaded. Remove once we
> +			 * have readout for pipe gamma enable.
> +			 */
> +			crtc_state->color_mgmt_changed = true;
>   		}
>   	}
>   
> 


More information about the Intel-gfx mailing list