mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
To: Mario Kleiner <mario.kleiner.de@gmail.com>,
	dri-devel@lists.freedesktop.org
Cc: intel-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Daniel Vetter <daniel.vetter@ffwll.ch>
Subject: Re: [PATCH] drm/i915: Fix legacy gamma lut updates in Linux 4.7-rc6
Date: Tue, 12 Jul 2016 11:50:40 +0100	[thread overview]
Message-ID: <15be51a4-74e2-2390-5a18-2172a7eae8ce@intel.com> (raw)
In-Reply-To: <1468319586-8509-1-git-send-email-mario.kleiner.de@gmail.com>

Hi Mario,

There was a couple of patch to fix this issue :

https://patchwork.freedesktop.org/series/5467/
https://patchwork.freedesktop.org/series/5466/

I tested this late last week on drm-intel-nightly, it seems a series of 
revert fixed most of the issues.

Cheers,

-
Lionel

On 12/07/16 11:33, Mario Kleiner wrote:
> Updating legacy gamma tables, e.g., via RandR doesn't work at all
> as of Linux 4.7-rc6.
>
> Reason seems to be that the required call to
> drm_atomic_helper_commit_planes_on_crtc is skipped in
> intel_atomic_commit after userspace set new gamma tables,
> because neither crtc->state->planes_changed nor
> update_pipe (= pipe_config->update_pipe) are true.
>
> Removing the check for planes_changed || update_pipe fixes
> gamma table updates.
>
> The code for Linux 4.8 drm-next has changed a lot in that area
> wrt. 4.7, but the new code for 4.8 also removed those checks
> and calls drm_atomic_helper_commit_planes_on_crtc unconditionally,
> and legacy gamma lut updates work on drm-next, so this seems to be
> the right solution.
>
> Tested also shutdown/reboot, suspend/resume, (un-)plugging displays,
> mode switches for resolution/refresh rate, display rotation, and
> page-flipping/pageflip timing on Intel HD Ironlake to confirm the
> fix apparently doesn't break anything under X11.
>
> Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> Cc: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> ---
>   drivers/gpu/drm/i915/intel_display.c | 4 +---
>   1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 04452cf..eb8fb36 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -13685,7 +13685,6 @@ static int intel_atomic_commit(struct drm_device *dev,
>   		bool modeset = needs_modeset(crtc->state);
>   		struct intel_crtc_state *pipe_config =
>   			to_intel_crtc_state(crtc->state);
> -		bool update_pipe = !modeset && pipe_config->update_pipe;
>   
>   		if (modeset && crtc->state->active) {
>   			update_scanline_offset(to_intel_crtc(crtc));
> @@ -13699,8 +13698,7 @@ static int intel_atomic_commit(struct drm_device *dev,
>   		    drm_atomic_get_existing_plane_state(state, crtc->primary))
>   			intel_fbc_enable(intel_crtc);
>   
> -		if (crtc->state->active &&
> -		    (crtc->state->planes_changed || update_pipe))
> +		if (crtc->state->active)
>   			drm_atomic_helper_commit_planes_on_crtc(old_crtc_state);
>   
>   		if (pipe_config->base.active && needs_vblank_wait(pipe_config))

  reply	other threads:[~2016-07-12 10:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-12 10:33 Mario Kleiner
2016-07-12 10:50 ` Lionel Landwerlin [this message]
2016-07-12 12:11   ` Mario Kleiner
2016-07-12 15:02     ` Lionel Landwerlin
2016-07-12 15:54       ` Mario Kleiner
2016-07-14 17:52   ` Mario Kleiner

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=15be51a4-74e2-2390-5a18-2172a7eae8ce@intel.com \
    --to=lionel.g.landwerlin@intel.com \
    --cc=daniel.vetter@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mario.kleiner.de@gmail.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

all inboxes | Powered by JetHome®