Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Jouni Högander" <jouni.hogander@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: animesh.manna@intel.com, mika.kahola@intel.com,
	"Jouni Högander" <jouni.hogander@intel.com>
Subject: [PATCH 4/6] drm/i915/display: Selective fetch Y position on Region Early Transport
Date: Wed, 29 May 2024 12:38:47 +0300	[thread overview]
Message-ID: <20240529093849.1016172-5-jouni.hogander@intel.com> (raw)
In-Reply-To: <20240529093849.1016172-1-jouni.hogander@intel.com>

Selective fetch Y position differs when Region Early Transport is
used. Use formula from Bspec for this.

Bspec: 68927

Signed-off-by: Jouni Högander <jouni.hogander@intel.com>
---
 drivers/gpu/drm/i915/display/skl_universal_plane.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/display/skl_universal_plane.c b/drivers/gpu/drm/i915/display/skl_universal_plane.c
index b7678b8a7f3d..1aa70fc35b9d 100644
--- a/drivers/gpu/drm/i915/display/skl_universal_plane.c
+++ b/drivers/gpu/drm/i915/display/skl_universal_plane.c
@@ -1302,7 +1302,11 @@ static void icl_plane_update_sel_fetch_noarm(struct intel_plane *plane,
 
 	clip = &plane_state->psr2_sel_fetch_area;
 
-	val = (clip->y1 + plane_state->uapi.dst.y1) << 16;
+	if (crtc_state->enable_psr2_su_region_et)
+		y = max(0, plane_state->uapi.dst.y1 - crtc_state->psr2_su_area.y1);
+	else
+		y = (clip->y1 + plane_state->uapi.dst.y1);
+	val = y << 16;
 	val |= plane_state->uapi.dst.x1;
 	intel_de_write_fw(i915, SEL_FETCH_PLANE_POS(pipe, plane->id), val);
 
-- 
2.34.1


  parent reply	other threads:[~2024-05-29  9:39 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-29  9:38 [PATCH 0/6] Region Early Transport debugfs support Jouni Högander
2024-05-29  9:38 ` [PATCH 1/6] drm/i915/psr: Add Early Transport status boolean into intel_psr Jouni Högander
2024-05-29  9:38 ` [PATCH 2/6] drm/i915/psr: Get Early Transport status in intel_psr_pipe_get_config Jouni Högander
2024-05-29  9:38 ` [PATCH 3/6] drm/i915/psr: Use enable boolean from intel_crtc_state for Early Transport Jouni Högander
2024-05-29  9:38 ` Jouni Högander [this message]
2024-05-29  9:38 ` [PATCH 5/6] drm/i915/psr: Allow setting I915_PSR_DEBUG_SU_REGION_ET_DISABLE via debugfs Jouni Högander
2024-05-29  9:38 ` [PATCH 6/6] drm/i915/psr: Add Early Transport into psr debugfs interface Jouni Högander
2024-05-29 11:58 ` ✗ Fi.CI.CHECKPATCH: warning for Region Early Transport debugfs support Patchwork
2024-05-29 11:58 ` ✗ Fi.CI.SPARSE: " Patchwork
2024-05-29 12:08 ` ✗ Fi.CI.BAT: failure " Patchwork
2024-05-29 12:50 ` ✓ Fi.CI.BAT: success " Patchwork
2024-05-30  9:52 ` ✗ Fi.CI.IGT: failure " Patchwork
2024-06-03  8:40   ` Hogander, Jouni
2024-06-03  7:30 ` [PATCH 0/6] " Manna, Animesh
2024-06-03  8:44   ` Hogander, Jouni

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=20240529093849.1016172-5-jouni.hogander@intel.com \
    --to=jouni.hogander@intel.com \
    --cc=animesh.manna@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=mika.kahola@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