Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: Hans de Goede <hdegoede@redhat.com>, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 1/2] drm/i915: Force a LUT update in intel_initial_commit()
Date: Wed, 21 Nov 2018 13:40:17 +0200	[thread overview]
Message-ID: <20181121114017.GB9144@intel.com> (raw)
In-Reply-To: <20181120222540.GB2515@intel.com>

On Tue, Nov 20, 2018 at 02:25:40PM -0800, Rodrigo Vivi wrote:
> On Tue, Nov 20, 2018 at 03:54:49PM +0200, Ville Syrjala wrote:
> > From: Ville Syrjälä <ville.syrjala@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.
> 
> Since this is temporary and marked with FIXME and Hans confirmed
> it solves the best behaviour let's move with this.
> 
> But I'm wondering if there is no way to minimize this instead of
> forcing this to every commit for each crtc...

It's just for the first commit we do when loading the driver.

> 
> Anyway,
> 
> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
> 
> > 
> > Cc: Hans de Goede <hdegoede@redhat.com>
> > Fixes: 516a49cc1946 ("drm/i915: Fix assert_plane() warning on bootup with external display")
> > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > ---
> >  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;
> >  		}
> >  	}
> >  
> > -- 
> > 2.18.1
> > 
> > _______________________________________________
> > Intel-gfx mailing list
> > Intel-gfx@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Ville Syrjälä
Intel
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

      reply	other threads:[~2018-11-21 11:40 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-20 13:54 [PATCH 1/2] drm/i915: Force a LUT update in intel_initial_commit() Ville Syrjala
2018-11-20 13:54 ` [PATCH 2/2] drm/i915: Add rotation readout for plane initial config Ville Syrjala
2018-11-20 22:20   ` Rodrigo Vivi
2018-11-21 11:34     ` Maarten Lankhorst
2018-11-21 12:13     ` Ville Syrjälä
2018-11-20 14:29 ` ✓ Fi.CI.BAT: success for series starting with [1/2] drm/i915: Force a LUT update in intel_initial_commit() Patchwork
2018-11-20 18:34 ` [PATCH 1/2] " Hans de Goede
2018-11-20 20:54 ` ✓ Fi.CI.IGT: success for series starting with [1/2] " Patchwork
2018-11-20 22:25 ` [PATCH 1/2] " Rodrigo Vivi
2018-11-21 11:40   ` Ville Syrjälä [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181121114017.GB9144@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=hdegoede@redhat.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=rodrigo.vivi@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox