From: Jani Nikula <jani.nikula@linux.intel.com>
To: Kaushlendra Kumar <kaushlendra.kumar@intel.com>,
rodrigo.vivi@intel.com, joonas.lahtinen@linux.intel.com,
tursulin@ursulin.net, airlied@gmail.com, simona@ffwll.ch
Cc: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org,
dri-devel@lists.freedesktop.org,
"Kaushlendra Kumar" <kaushlendra.kumar@intel.com>,
"Jouni Högander" <jouni.hogander@intel.com>,
"Animesh Manna" <animesh.manna@intel.com>
Subject: Re: [PATCH] drm/i915/display: use port not transcoder for PORT_ALPM_CTL
Date: Fri, 09 Jan 2026 10:49:35 +0200 [thread overview]
Message-ID: <6dfa37a9c19089bda5efe1c43d1a40d88d53cf89@intel.com> (raw)
In-Reply-To: <20260109050021.2017982-1-kaushlendra.kumar@intel.com>
On Fri, 09 Jan 2026, Kaushlendra Kumar <kaushlendra.kumar@intel.com> wrote:
> intel_alpm_disable() incorrectly passes cpu_transcoder as the
> index to PORT_ALPM_CTL(), which expects an enum port. This
> writes to the wrong register, potentially corrupting state on
> unrelated ports.
>
> Use dp_to_dig_port(intel_dp)->base.port to access the correct
> port-indexed register.
Good catch!
For future reference, please also do 'git blame' on the source to find
out which commit introduced the error, and add a proper Fixes: tag. This
way we know the kernels that are affected.
We have to hop through code movement and multiple other changes to
eventually land on commit 1ccbf135862b ("drm/i915/psr: Enable ALPM on
source side for eDP Panel replay") adding the
PORT_ALPM_CTL(cpu_transcoder) usage in intel_psr.c.
'dim fixes 1ccbf135862b' gives us:
Fixes: 1ccbf135862b ("drm/i915/psr: Enable ALPM on source side for eDP Panel replay")
Cc: Jouni Högander <jouni.hogander@intel.com>
Cc: Animesh Manna <animesh.manna@intel.com>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: intel-gfx@lists.freedesktop.org
Cc: intel-xe@lists.freedesktop.org
Cc: <stable@vger.kernel.org> # v6.10+
Which I'd usually just trim to the author/reviewers like this:
Fixes: 1ccbf135862b ("drm/i915/psr: Enable ALPM on source side for eDP Panel replay")
Cc: Jouni Högander <jouni.hogander@intel.com>
Cc: Animesh Manna <animesh.manna@intel.com>
Cc: <stable@vger.kernel.org> # v6.10+
And these are more important Cc's for the patch than any of the
maintainers or dri-devel, which IMO should be dropped, regardless of
what get_maintainer.pl says.
Obviously, a backport to kernels v6.10..v6.15 will fail due to the other
changes, but it doesn't change the fact that the original broken commit
was 1ccbf135862b in v6.10, and that's what we should reference.
BR,
Jani.
Oh, and also,
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
>
> Signed-off-by: Kaushlendra Kumar <kaushlendra.kumar@intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_alpm.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_alpm.c b/drivers/gpu/drm/i915/display/intel_alpm.c
> index 6372f533f65b..09ba1c2be16c 100644
> --- a/drivers/gpu/drm/i915/display/intel_alpm.c
> +++ b/drivers/gpu/drm/i915/display/intel_alpm.c
> @@ -557,6 +557,7 @@ void intel_alpm_disable(struct intel_dp *intel_dp)
> {
> struct intel_display *display = to_intel_display(intel_dp);
> enum transcoder cpu_transcoder = intel_dp->alpm.transcoder;
> + enum port port = dp_to_dig_port(intel_dp)->base.port;
>
> if (DISPLAY_VER(display) < 20 || !intel_dp->alpm_dpcd)
> return;
> @@ -568,7 +569,7 @@ void intel_alpm_disable(struct intel_dp *intel_dp)
> ALPM_CTL_ALPM_AUX_LESS_ENABLE, 0);
>
> intel_de_rmw(display,
> - PORT_ALPM_CTL(cpu_transcoder),
> + PORT_ALPM_CTL(port),
> PORT_ALPM_CTL_ALPM_AUX_LESS_ENABLE, 0);
>
> drm_dbg_kms(display->drm, "Disabling ALPM\n");
--
Jani Nikula, Intel
next prev parent reply other threads:[~2026-01-09 8:49 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-09 5:00 [PATCH] drm/i915/display: use port not transcoder for PORT_ALPM_CTL Kaushlendra Kumar
2026-01-09 5:10 ` ✓ CI.KUnit: success for " Patchwork
2026-01-09 5:43 ` ✓ Xe.CI.BAT: " Patchwork
2026-01-09 7:26 ` ✓ Xe.CI.Full: " Patchwork
2026-01-09 8:49 ` Jani Nikula [this message]
2026-01-09 10:07 ` [PATCH] " Kumar, Kaushlendra
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=6dfa37a9c19089bda5efe1c43d1a40d88d53cf89@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=airlied@gmail.com \
--cc=animesh.manna@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=intel-xe@lists.freedesktop.org \
--cc=joonas.lahtinen@linux.intel.com \
--cc=jouni.hogander@intel.com \
--cc=kaushlendra.kumar@intel.com \
--cc=rodrigo.vivi@intel.com \
--cc=simona@ffwll.ch \
--cc=tursulin@ursulin.net \
/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