From: Alex Hung <alex.hung@amd.com>
To: <amd-gfx@lists.freedesktop.org>
Cc: Harry Wentland <harry.wentland@amd.com>,
Leo Li <sunpeng.li@amd.com>,
Aurabindo Pillai <aurabindo.pillai@amd.com>,
Roman Li <roman.li@amd.com>, Wayne Lin <wayne.lin@amd.com>,
Tom Chung <chiahsuan.chung@amd.com>,
"Fangzhi Zuo" <jerry.zuo@amd.com>,
Dan Wheeler <daniel.wheeler@amd.com>, Ray Wu <Ray.Wu@amd.com>,
Ivan Lipski <ivan.lipski@amd.com>, Alex Hung <alex.hung@amd.com>,
Benjamin Nwankwo <Benjamin.Nwankwo@amd.com>,
Aric Cyr <aric.cyr@amd.com>,
Mario Limonciello <mario.limonciello@amd.com>,
"Alex Deucher" <alexander.deucher@amd.com>,
<stable@vger.kernel.org>
Subject: [PATCH 1/8] drm/amd/display: Skip cursor cache reset if hubp powergating is disabled
Date: Wed, 25 Feb 2026 16:57:40 -0700 [thread overview]
Message-ID: <20260226000048.68030-2-alex.hung@amd.com> (raw)
In-Reply-To: <20260226000048.68030-1-alex.hung@amd.com>
From: Benjamin Nwankwo <Benjamin.Nwankwo@amd.com>
[WHY]
On pipe resets, cursor cache resets to sync with power gated hubp.
But dcn42 doesn't power gate hubp which causes a discrepancy
where cursor registers are still enabled while the cache is cleared.
This ultimately leads to a pipe's cursor incorrectly retaining its
enabled state, while the cursor isn't in its viewport
[HOW]
Skip memsets for dpp and hubp cursor caches if either
disable_hubp_power_gate or ignore_pg flags are true
Reviewed-by: Aric Cyr <aric.cyr@amd.com>
Signed-off-by: Benjamin Nwankwo <Benjamin.Nwankwo@amd.com>
Signed-off-by: Alex Hung <alex.hung@amd.com>
Cc: Mario Limonciello <mario.limonciello@amd.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
---
drivers/gpu/drm/amd/display/dc/dpp/dcn10/dcn10_dpp.c | 7 ++++---
drivers/gpu/drm/amd/display/dc/hubp/dcn10/dcn10_hubp.c | 6 ++++--
2 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/drivers/gpu/drm/amd/display/dc/dpp/dcn10/dcn10_dpp.c b/drivers/gpu/drm/amd/display/dc/dpp/dcn10/dcn10_dpp.c
index ce91e5d28956..194dba734cc1 100644
--- a/drivers/gpu/drm/amd/display/dc/dpp/dcn10/dcn10_dpp.c
+++ b/drivers/gpu/drm/amd/display/dc/dpp/dcn10/dcn10_dpp.c
@@ -193,9 +193,10 @@ void dpp_reset(struct dpp *dpp_base)
dpp->filter_v_c = NULL;
dpp->filter_h = NULL;
dpp->filter_v = NULL;
-
- memset(&dpp_base->pos, 0, sizeof(dpp_base->pos));
- memset(&dpp_base->att, 0, sizeof(dpp_base->att));
+ if (!dpp_base->ctx->dc->debug.ignore_pg) {
+ memset(&dpp_base->pos, 0, sizeof(dpp_base->pos));
+ memset(&dpp_base->att, 0, sizeof(dpp_base->att));
+ }
memset(&dpp->scl_data, 0, sizeof(dpp->scl_data));
memset(&dpp->pwl_data, 0, sizeof(dpp->pwl_data));
diff --git a/drivers/gpu/drm/amd/display/dc/hubp/dcn10/dcn10_hubp.c b/drivers/gpu/drm/amd/display/dc/hubp/dcn10/dcn10_hubp.c
index 6378e3fd7249..a2ddf81538e6 100644
--- a/drivers/gpu/drm/amd/display/dc/hubp/dcn10/dcn10_hubp.c
+++ b/drivers/gpu/drm/amd/display/dc/hubp/dcn10/dcn10_hubp.c
@@ -548,8 +548,10 @@ void hubp1_dcc_control(struct hubp *hubp, bool enable,
void hubp_reset(struct hubp *hubp)
{
- memset(&hubp->pos, 0, sizeof(hubp->pos));
- memset(&hubp->att, 0, sizeof(hubp->att));
+ if (!hubp->ctx->dc->debug.ignore_pg && !hubp->ctx->dc->debug.disable_hubp_power_gate) {
+ memset(&hubp->pos, 0, sizeof(hubp->pos));
+ memset(&hubp->att, 0, sizeof(hubp->att));
+ }
hubp->cursor_offload = false;
}
--
2.43.0
next parent reply other threads:[~2026-02-26 0:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20260226000048.68030-1-alex.hung@amd.com>
2026-02-25 23:57 ` Alex Hung [this message]
2026-02-25 23:57 ` [PATCH 2/8] drm/amd/display: Fallback to boot snapshot for dispclk Alex Hung
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=20260226000048.68030-2-alex.hung@amd.com \
--to=alex.hung@amd.com \
--cc=Benjamin.Nwankwo@amd.com \
--cc=Ray.Wu@amd.com \
--cc=alexander.deucher@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=aric.cyr@amd.com \
--cc=aurabindo.pillai@amd.com \
--cc=chiahsuan.chung@amd.com \
--cc=daniel.wheeler@amd.com \
--cc=harry.wentland@amd.com \
--cc=ivan.lipski@amd.com \
--cc=jerry.zuo@amd.com \
--cc=mario.limonciello@amd.com \
--cc=roman.li@amd.com \
--cc=stable@vger.kernel.org \
--cc=sunpeng.li@amd.com \
--cc=wayne.lin@amd.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