All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: [Intel-gfx] [PATCH v1 2/2] drm/i915: Update dbuf slices also when active_pipe_changes pending
Date: Thu, 13 Feb 2020 14:43:52 +0200	[thread overview]
Message-ID: <20200213124352.29600-3-stanislav.lisovskiy@intel.com> (raw)
In-Reply-To: <20200213124352.29600-1-stanislav.lisovskiy@intel.com>

When distrust_bios_wm flag is set, we might have active_pipe_changes
flag set which forces ddb recalculation in absence of state->modeset
field being set. Which might in turn result in inconsistent update,
i.e ddb/wm allocations are updated in hw, but DBuf slice power state
is not. Fix this by evaluating active_pipe_changes field as well,
as it currently behaves as a separate entity in the code from
state->modeset.
Previously with Ville we tried to fix that by forcing a modeset
when distrust_bios_wm is set, however it broke DSI code as it
didn't have pipe_config precomputed, so this fix probably is more
preferrable.

Signed-off-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>
---
 drivers/gpu/drm/i915/display/intel_display.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
index 61ba1f2256a0..6eee69f8464a 100644
--- a/drivers/gpu/drm/i915/display/intel_display.c
+++ b/drivers/gpu/drm/i915/display/intel_display.c
@@ -15723,7 +15723,7 @@ static void intel_atomic_commit_tail(struct intel_atomic_state *state)
 		intel_encoders_update_prepare(state);
 
 	/* Enable all new slices, we might need */
-	if (state->modeset)
+	if (state->modeset || state->active_pipe_changes)
 		icl_dbuf_slice_pre_update(state);
 
 	/* Now enable the clocks, plane, pipe, and connectors that we set up. */
@@ -15780,7 +15780,7 @@ static void intel_atomic_commit_tail(struct intel_atomic_state *state)
 	}
 
 	/* Disable all slices, we don't need */
-	if (state->modeset)
+	if (state->modeset || state->active_pipe_changes)
 		icl_dbuf_slice_post_update(state);
 
 	for_each_oldnew_intel_crtc_in_state(state, crtc, old_crtc_state, new_crtc_state, i) {
-- 
2.24.1.485.gad05a3d8e5

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

  parent reply	other threads:[~2020-02-13 12:47 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-13 12:43 [Intel-gfx] [PATCH v1 0/2] Fix state transitions affecting DBuf Stanislav Lisovskiy
2020-02-13 12:43 ` [Intel-gfx] [PATCH v1 1/2] drm/i915: Ensure no conflicts with BIOS when updating Dbuf Stanislav Lisovskiy
2020-02-13 12:43 ` Stanislav Lisovskiy [this message]
2020-02-13 15:13 ` [Intel-gfx] ✓ Fi.CI.BAT: success for Fix state transitions affecting DBuf Patchwork
2020-02-17 10:43 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork

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=20200213124352.29600-3-stanislav.lisovskiy@intel.com \
    --to=stanislav.lisovskiy@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.