All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Xiao Lu" <xiaolu.xie@intel.com>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm/dp/mst: skip connector creation for unplugged downstream ports
Date: Thu, 17 Sep 2026 08:17:11 +0000	[thread overview]
Message-ID: <20260917081711.C749E1F00893@smtp.kernel.org> (raw)
In-Reply-To: <20260917080126.1729898-1-xiaolu.xie@intel.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] drm/dp/mst: missing connector creation breaks hotplug for empty downstream ports
--

commit b7642d2c459f1deba3af19a444979a2c15cbf1e0
Author: Xiao Lu <xiaolu.xie@intel.com>

drm/dp/mst: skip connector creation for unplugged downstream ports

This patch modifies the MST link enumeration path to skip creating DRM
connectors for downstream ports that do not have a device connected.
It aims to reduce error log noise and spurious sideband messages from
DPCD reads on empty ports.

> diff --git a/drivers/gpu/drm/display/drm_dp_mst_topology.c b/drivers/gpu/drm/display/drm_dp_mst_topology.c
> --- a/drivers/gpu/drm/display/drm_dp_mst_topology.c
> +++ b/drivers/gpu/drm/display/drm_dp_mst_topology.c
> @@ -2448,7 +2448,7 @@ drm_dp_mst_handle_link_address_port(struct drm_dp_mst_branch *mstb,
>  
>  	if (port->connector)
>  		drm_modeset_unlock(&mgr->base.lock);
> -	else if (!port->input)
> +	else if (!port->input && port->ddps)
>  		drm_dp_mst_port_add_connector(mstb, port);

[Severity: High]
If we skip connector creation here for empty ports, will the hotplug path
actually create the connector when a monitor is plugged in?

Looking at drm_dp_mst_handle_conn_stat(), create_connector is only set to
true when transitioning from an input port to an output port:

    } else if (port->input && !conn_stat->input_port) {
        create_connector = true;

For standard downstream ports, port->input is 0, so create_connector
remains false during a hotplug event.

Later in drm_dp_mst_handle_conn_stat(), it checks:

    else if (create_connector)
        drm_dp_mst_port_add_connector(mstb, port);

Since create_connector evaluated to false, the dynamic connector creation
is bypassed.

Also, drm_dp_port_set_pdt() returns 0 for regular SST monitors:

        if (drm_dp_mst_is_end_device(port->pdt, port->mcs)) {
            /* add i2c over sideband */
            ret = drm_dp_mst_register_i2c_bus(port);

This prevents the caller from setting dowork = true and triggering a
fallback link address reprobe.

Does this mean a display plugged into an MST hub port that was empty at
boot will remain permanently dark because its DRM connector is never
created?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260917080126.1729898-1-xiaolu.xie@intel.com?part=1

  reply	other threads:[~2026-09-17  8:17 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-17  8:01 [PATCH] drm/dp/mst: skip connector creation for unplugged downstream ports Xiao Lu
2026-09-17  8:17 ` sashiko-bot [this message]
2026-09-17  8:26   ` Xie, Xiaolu
2026-09-17 16:49 ` lyude
2026-09-18  1:29   ` Xiao Lu
2026-09-18 18:19     ` lyude
2026-09-20  2:21       ` Xiao Lu
2026-09-20  2:21       ` [PATCH v2] drm/dp/mst: reject DPCD read/write on ports with ddps=0 Xiao Lu
2026-09-21 21:04         ` lyude
2026-09-22  3:26           ` Xiao Lu
2026-09-22 19:19             ` lyude
2026-09-23  1:24               ` Xiao Lu
2026-10-13  6:38         ` Marco Nenciarini
2026-09-18  9:04 ` ✓ CI.KUnit: success for drm/dp/mst: skip connector creation for unplugged downstream ports Patchwork
2026-09-18 10:01 ` ✓ Xe.CI.BAT: " Patchwork
2026-09-18 10:12 ` ✓ i915.CI.BAT: " Patchwork
2026-09-18 17:15 ` ✗ i915.CI.Full: failure " Patchwork
2026-09-18 18:59 ` ✗ Xe.CI.FULL: " 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=20260917081711.C749E1F00893@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=sashiko-reviews@lists.linux.dev \
    --cc=xiaolu.xie@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 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.