All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: gregkh@linuxfoundation.org
Cc: dri-devel@lists.freedesktop.org
Subject: Re: Patch "drm/dp_mst: Handle torn-down topology gracefully in drm_dp_mst_topology_queue_probe()" has been added to the 6.12-stable tree
Date: Wed, 29 Jul 2026 16:37:19 +0000	[thread overview]
Message-ID: <20260729163720.4759B1F000E9@smtp.kernel.org> (raw)
In-Reply-To: <2026072907-framing-morphine-00a8@gregkh>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:

Pre-existing issues:
- [High] Calling `mutex_lock()` from within an atomic encoder callback path.
--

--- Patch [1]: Patch "drm/dp_mst: Handle torn-down topology gracefully in drm_dp_mst_topology_queue_probe()" has been added to the 6.12-stable tree ---
commit 746d73e2e2b5ca58eedb8e8371b10fa271386f44
Author: gregkh@linuxfoundation.org <gregkh@linuxfoundation.org>

drm/dp_mst: Handle torn-down topology gracefully in drm_dp_mst_topology_queue_probe()

This commit replaces a drm_WARN_ON with an early return in
drm_dp_mst_topology_queue_probe() to handle torn-down topologies gracefully
during concurrent hotplug or link-loss events. This eliminates spurious
kernel warnings and compositor crashes.

Link: https://lore.kernel.org/all/20260503034533.1023686-1-jonas.emilsson@gmail.com
Link: https://patch.msgid.link/20260622140532.526722-1-luciano.coelho@intel.com

> diff --git a/drivers/gpu/drm/display/drm_dp_mst_topology.c b/drivers/gpu/drm/display/drm_dp_mst_topology.c
> index ac90118b9e7a8..97ddd10df0229 100644
> --- a/drivers/gpu/drm/display/drm_dp_mst_topology.c
> +++ b/drivers/gpu/drm/display/drm_dp_mst_topology.c
> @@ -3739,8 +3739,10 @@ void drm_dp_mst_topology_queue_probe(struct drm_dp_mst_topology_mgr *mgr)
>  {
>  	mutex_lock(&mgr->lock);

[Severity: High]
This is a pre-existing issue, but won't this mutex lock cause a sleeping
in atomic context warning?

During non-blocking commits, the encoder atomic callback
intel_mst_pre_enable_dp() runs in an atomic context where sleeping is
forbidden. It calls intel_mst_reprobe_topology(), which then calls this
function:

intel_mst_pre_enable_dp() ->
    intel_mst_reprobe_topology() ->
        drm_dp_mst_topology_queue_probe()

Since drm_dp_mst_topology_queue_probe() unconditionally acquires mgr->lock
using mutex_lock(), won't this lead to scheduling while atomic splats or
potential deadlocks during hotplug events and modesets involving MST links?

> -	if (drm_WARN_ON(mgr->dev, !mgr->mst_state || !mgr->mst_primary))
> +	if (!mgr->mst_state || !mgr->mst_primary) {
> +		drm_dbg_kms(mgr->dev, "queue_probe skipped: topology torn down\n");
>  		goto out_unlock;
> +	}
>  
>  	drm_dp_mst_topology_mgr_invalidate_mstb(mgr->mst_primary);
>  	drm_dp_mst_queue_probe_work(mgr);

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/2026072907-framing-morphine-00a8@gregkh?part=1

  reply	other threads:[~2026-07-29 16:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-29 16:28 Patch "drm/dp_mst: Handle torn-down topology gracefully in drm_dp_mst_topology_queue_probe()" has been added to the 6.12-stable tree gregkh
2026-07-29 16:37 ` sashiko-bot [this message]
2026-07-29 17:02 ` ✗ Fi.CI.BUILD: failure for " 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=20260729163720.4759B1F000E9@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gregkh@linuxfoundation.org \
    --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.