All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Lyude Paul" <lyude@redhat.com>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 5/6] drm/nouveau/kms/nv50-: Add nouveau_encoder->audio.crtc
Date: Wed, 19 Aug 2026 00:10:52 +0000	[thread overview]
Message-ID: <20260819001052.A7B0E1F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260818235637.1738055-6-lyude@redhat.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] PIOR encoders do not clear `audio.crtc` on disable, leading to stale audio state being reported.
--

--- Patch [5]: [PATCH 5/6] drm/nouveau/kms/nv50-: Add nouveau_encoder->audio.crtc ---
commit d00b281328e092a25d08552356c0a7fc11880073
Author: Lyude Paul <lyude@redhat.com>

drm/nouveau/kms/nv50-: Add nouveau_encoder->audio.crtc

This commit adds an audio.crtc pointer to track the assigned CRTC for an
encoder outside of modesetting locks. It replaces the usage of
nouveau_encoder->crtc in the audio ELD retrieval path.

> diff --git a/drivers/gpu/drm/nouveau/dispnv50/disp.c b/drivers/gpu/drm/nouveau/dispnv50/disp.c
> index 63d554e97fb62..3bfc04f7ef602 100644
> --- a/drivers/gpu/drm/nouveau/dispnv50/disp.c
> +++ b/drivers/gpu/drm/nouveau/dispnv50/disp.c
> @@ -636,7 +636,7 @@ nv50_audio_component_get_eld(struct device *kdev, int port, int dev_id,
>  
>  		nv_encoder = nouveau_encoder(encoder);
>  		nv_connector = nv_encoder->conn;
> -		nv_crtc = nouveau_crtc(nv_encoder->crtc);
> +		nv_crtc = nv_encoder->audio.crtc;
>  
>  		if (!nv_crtc || nv_encoder->outp.or.id != port || nv_crtc->index != dev_id)
>  			continue;

[Severity: Medium]
Will this cause stale audio state to be reported when PIOR encoders are
disabled?

Before this patch, checking the cleared crtc pointer successfully skipped
the disabled encoder. However, it looks like nv50_pior_atomic_disable()
only clears the old crtc pointer, but not the new audio.crtc pointer:

nv50_pior_atomic_disable()
{
	...
	core->func->pior->ctrl(core, nv_encoder->outp.or.id, ctrl, NULL);
	nv_encoder->crtc = NULL;
}

Does nv_encoder->audio.crtc also need to be cleared here, or does
nv50_audio_disable() need to be called in nv50_pior_atomic_disable() to
prevent userspace from receiving stale ELD data for a deactivated display?

[ ... ]

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260818235637.1738055-1-lyude@redhat.com?part=5

  reply	other threads:[~2026-08-19  0:10 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-18 23:48 [PATCH 0/6] drm/nouveau/kms/nv50-: Obliterate nv_encoder->crtc Lyude Paul
2026-08-18 23:48 ` Lyude Paul
2026-08-18 23:48 ` [PATCH 1/6] drm/nouveau/kms/nv50-: Move DPCD backlight disable into its own function Lyude Paul
2026-08-18 23:48   ` Lyude Paul
2026-08-19  0:07   ` sashiko-bot
2026-08-18 23:48 ` [PATCH 2/6] drm/nouveau/kms/nv50-: Add nv50_outp_get_old_crtc() Lyude Paul
2026-08-18 23:48   ` Lyude Paul
2026-08-18 23:48 ` [PATCH 3/6] drm/nouveau/kms/nv50-: Stop using nv_encoder->crtc in nv50_sor_atomic_disable() Lyude Paul
2026-08-18 23:48   ` Lyude Paul
2026-08-18 23:48 ` [PATCH 4/6] drm/nouveau/kms/nv50-: Stop using nv_encoder->crtc in nv50_disp_atomic_commit_core() Lyude Paul
2026-08-18 23:48   ` Lyude Paul
2026-08-19  0:04   ` sashiko-bot
2026-08-19  0:10   ` lyude
2026-08-19  0:10     ` lyude
2026-08-18 23:48 ` [PATCH 5/6] drm/nouveau/kms/nv50-: Add nouveau_encoder->audio.crtc Lyude Paul
2026-08-18 23:48   ` Lyude Paul
2026-08-19  0:10   ` sashiko-bot [this message]
2026-08-18 23:48 ` [PATCH 6/6] drm/nouveau/kms/nv50-: Obliterate nouveau_encoder->crtc Lyude Paul
2026-08-18 23:48   ` Lyude Paul

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=20260819001052.A7B0E1F000E9@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=lyude@redhat.com \
    --cc=sashiko-reviews@lists.linux.dev \
    /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.