Re: [PATCH v8 6/9] drm/msm/dp: don't take extra references on multiple plug events

From: Yongxing Mou

Date: Wed Nov 11 2026 - 21:48:22 EST




On 10/24/2026 8:35 AM, Dmitry Baryshkov wrote:
The upper layers might signal multiple sequential HPD plug events. Don't
take extra references and skip all further HPD plug events until we
receive the unplug event.

Fixes: 3ea2d1c3d154 ("drm/msm/dp: turn link_ready into plugged")
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@xxxxxxxxxxxxxxxx>
---
drivers/gpu/drm/msm/dp/dp_display.c | 3 +++
1 file changed, 3 insertions(+)

diff --git a/drivers/gpu/drm/msm/dp/dp_display.c b/drivers/gpu/drm/msm/dp/dp_display.c
index fa8942922b53..ce919a26fba2 100644
--- a/drivers/gpu/drm/msm/dp/dp_display.c
+++ b/drivers/gpu/drm/msm/dp/dp_display.c
@@ -412,6 +412,9 @@ static int msm_dp_hpd_plug_handle(struct msm_dp_display_private *dp)
guard(mutex)(&dp->plugged_lock);
+ if (dp->plugged)
+ return 0;
+
ret = pm_runtime_resume_and_get(&pdev->dev);
if (ret) {
DRM_ERROR("failed to pm_runtime_resume\n");

Hi, the issue reported by the AI is real. There is a regression in the SST case: when .detect() runs first, it sets plugged to true. As a result, when msm_dp_hpd_plug_handle() is called, msm_dp_display_process_hpd_high() is skipped, which causes the subsequent failure.

I tried removing the plugged update from .detect(), and that fixes the SST issue. The display works now. However, there is still an intermittent issue where the wrong resolution is selected. I suspect this is related to the timing of the EDID read: when fbcon comes up, the correct EDID may not be available immediately.