Skip to content

Pr tech mm drm v2 shutdown - #1639

Open
quicmahap wants to merge 2 commits into
qualcomm-linux:tech/mm/drmfrom
quicmahap:pr-tech-mm-drm-v2-shutdown
Open

Pr tech mm drm v2 shutdown#1639
quicmahap wants to merge 2 commits into
qualcomm-linux:tech/mm/drmfrom
quicmahap:pr-tech-mm-drm-v2-shutdown

Conversation

@quicmahap

Copy link
Copy Markdown

No description provided.

Mahadevan P added 2 commits August 4, 2026 16:37
…er_shutdown()

drm_atomic_helper_shutdown() disables all CRTCs but leaves output
polling and IRQ-driven hot-plug detection running. On reboot, a late
DP hot-plug-detect (HPD) IRQ can fire after apps_smmu has already
disabled translation for the display subsystem, causing the HPD
thread to kick off a new modeset that drives DPU/DP hardware and DMA
through a stale IOMMU mapping.

drm_atomic_helper_shutdown() disables all CRTCs first, but a pending
HPD IRQ thread wakes up afterwards, reads the DPCD, and fires an
unsolicited hotplug event that triggers a second atomic commit
turning the display back on -- right as the IOMMU is disabling
translation:

  systemd-shutdown[1]: Rebooting.
  msm_dpu: drm_atomic_commit: committing (shutdown disabling CRTCs)
  arm-smmu 3da0000.iommu: disabling translation
  msm_dpu: drm_dp_read_dpcd_caps (late HPD IRQ thread wakes up)
  msm_dpu: drm_sysfs_connector_hotplug_event: DP-1 hotplug event
  msm_dpu: drm_client_modeset_probe: DP-1 found preferred mode
  msm_dpu: drm_atomic_commit: committing (unsolicited, re-enables display)
  dpu_crtc_commit_kickoff: crtc94 first commit
  arm-smmu 15200000.iommu: disabling translation

drm_kms_helper_poll_fini() tears down this: it stops the output poll
worker and calls each connector's &drm_connector_helper_funcs.disable_hpd,
which for HPD-capable bridges masks the interrupt in hardware.

Reported on Qualcomm platforms such as lemans-evk and monaco-evk
during reboot stress testing.

Assisted-by: Claude:claude-sonnet-5
Link: https://lore.kernel.org/r/20260730-dpshutdown-v2-1-441fc5543bed@oss.qualcomm.com
Signed-off-by: Mahadevan P <mahadevan.p@oss.qualcomm.com>
@qcomlnxci
qcomlnxci requested review from a team, Rajesh Kemisetti (quic-rajeshk) and riteshk-quic and removed request for a team August 4, 2026 11:13
@qlijarvis

Copy link
Copy Markdown

🔨 Build Failure Analysis — PR #1639

PR: #1639
Build run: https://github.com/qualcomm-linux/kernel-config/actions/runs/30903931608

# Error File:Line PR-introduced? Root Cause
1 Merge conflict during automerge drivers/gpu/drm/bridge/lontium-lt9611c.c No Pre-existing conflict between PR base branch and topic branch topic/tech/mm/drm. The PR does not modify this file.

Verdict

This is NOT a compilation failure. The build failed during the automerge/integration phase due to a merge conflict in a file (lontium-lt9611c.c) that is not touched by this PR. The conflict is pre-existing and unrelated to the PR changes.

📎 Detailed analysis: Full report

@qlijarvis

Copy link
Copy Markdown

🔨 Build Failure Analysis — PR #1639

PR: #1639
Build run: https://github.com/qualcomm-linux/kernel-config/actions/runs/30903931608

# Error File:Line PR-introduced? Root Cause
1 Merge conflict during automerge drivers/gpu/drm/bridge/lontium-lt9611c.c No Pre-existing conflict between baseline and topic/tech/mm/drm branch. PR does not modify this file.

Verdict

This is NOT a compilation error. The build failed during the integration/automerge phase due to a pre-existing merge conflict in a file that this PR does not touch. The PR changes are limited to drivers/gpu/drm/msm/dp/dp_display.c and drivers/gpu/drm/drm_atomic_helper.c, while the conflict is in drivers/gpu/drm/bridge/lontium-lt9611c.c.

📎 Detailed analysis: Full report

@qlijarvis

Copy link
Copy Markdown

PR #1639 — validate-patch

PR: #1639

Verdict Issues Detailed Report
⚠️ 1 Full report

Final Summary

  1. Lore link present: Yes — https://lore.kernel.org/r/20260730-dpshutdown-v2-1-441fc5543bed@oss.qualcomm.com (commit 2/2 only; commit 1/2 is a revert with no lore link, which is acceptable)

  2. Lore link matches PR commits: Yes — commit 2/2 diff is byte-for-byte identical to the lore patch (context line numbers differ due to different base commits, but code hunks match exactly)

  3. Upstream patch status:In review — Posted 2026-07-30 (4 days ago); no maintainer decision yet; Sashiko AI raised concerns but no human maintainer has responded

  4. PR present in qcom-next/topics: Fail - 2/2 commit(s) are missing from both qcom-next and topics


Verdict: ⚠️ — click to expand

🔍 Patch Validation

PR: #1639
Commits: 2 commits (1 revert + 1 FROMLIST patch)


Commit 1/2: Revert "FROMLIST: drm/msm/dp: add .shutdown to mask HPD IRQ before system shutdown"

Upstream commit: N/A (revert of a previous FROMLIST commit)
Verdict: ⚠️ PARTIAL — Revert is clean but lacks context

Commit Message

Check Status Note
Subject matches upstream N/A Revert commit — no upstream source
Body preserves rationale Missing explanation for why the revert is needed
Fixes tag present/correct N/A Not applicable for reverts
Authorship preserved Mahadevan P is the author
Backport note (if applicable) N/A Not a backport

Diff

File Status Notes
drivers/gpu/drm/msm/dp/dp_display.c Clean revert — removes msm_dp_display_shutdown() function and .shutdown hook

Issues

  • Missing revert rationale: The commit message only states "This reverts commit 9e407ef..." but does not explain why the revert is necessary. Best practice for kernel reverts is to include a paragraph explaining the reason (e.g., "This local workaround is no longer needed because the issue is now fixed at the DRM core level in the following commit").

Verdict

The revert is technically correct but incomplete. Add a rationale paragraph explaining that this driver-specific workaround is being replaced by a core DRM fix.


Commit 2/2: FROMLIST: drm/atomic-helper: tear down HPD/polling in drm_atomic_helper_shutdown()

Upstream commit: https://lore.kernel.org/r/20260730-dpshutdown-v2-1-441fc5543bed@oss.qualcomm.com
Verdict:PASS — Faithful to lore source

Commit Message

Check Status Note
Subject matches upstream Identical except for FROMLIST: prefix (expected)
Body preserves rationale Full problem description, trace log, and technical explanation preserved
Fixes tag present/correct N/A No Fixes: tag in upstream or PR (new feature, not a fix)
Authorship preserved From: Mahadevan P <mahadevan.p@oss.qualcomm.com> matches lore author
Backport note (if applicable) N/A Not a backport — FROMLIST: prefix is correct

Diff Comparison

File Status Notes
drivers/gpu/drm/drm_atomic_helper.c Identical code change — adds drm_kms_helper_poll_fini(dev); call and updates function documentation

Detailed diff analysis:

PR patch context lines:

@@ -3670,6 +3671,8 @@ EXPORT_SYMBOL(drm_atomic_helper_reset_crtc);
 void drm_atomic_helper_shutdown(struct drm_device *dev)
 {
@@ -3679,6 +3682,8 @@ void drm_atomic_helper_shutdown(struct drm_device *dev)
 	if (dev == NULL)
 		return;
 
+	drm_kms_helper_poll_fini(dev);

Lore patch context lines:

@@ -3676,6 +3677,8 @@ EXPORT_SYMBOL(drm_atomic_helper_reset_crtc);
 void drm_atomic_helper_shutdown(struct drm_device *dev)
 {
@@ -3685,6 +3688,8 @@ void drm_atomic_helper_shutdown(struct drm_device *dev)
 	if (dev == NULL)
 		return;
 
+	drm_kms_helper_poll_fini(dev);

Context delta: Line numbers differ (3670 vs 3676, 3679 vs 3685) due to different base commits, but the code hunks are byte-for-byte identical. This is a legitimate context-only delta — the PR is based on a slightly different kernel tree version than the lore patch's base-commit: 1a1757b76427f6201bfe0bf1bea9f7574f332a93.

The include statement addition (+#include <drm/drm_probe_helper.h>) and documentation update are also identical.

Upstream Patch Status

Commit Community Verdict
drm/atomic-helper: tear down HPD/polling in drm_atomic_helper_shutdown() Decision Pending — Posted 2026-07-30; no maintainer decision yet. Sashiko AI review raised concerns about race conditions and potential regressions, but no human maintainer has responded. Last activity: 2026-07-30.

Evidence from lore thread:

  • Patch posted on 2026-07-30 (4 days ago as of 2026-08-04)
  • No maintainer replies (no Reviewed-by:, Acked-by:, applied, or NAK)
  • Sashiko AI bot review flagged potential issues (TOCTOU race, kernel warning during unload) but this is not a maintainer decision
  • No newer revisions found (this is v2; v1 was a different approach)
  • Not found in torvalds/linux or stable trees (too recent)

Recommendation: This patch is still under community review. The FROMLIST: prefix is correct — it indicates the patch has been posted to the mailing list but not yet accepted upstream.

qcom-next/topics Presence

Commit Status
Revert "FROMLIST: drm/msm/dp: add .shutdown..." ⚠️ Not in qcom-next/topics
FROMLIST: drm/atomic-helper: tear down HPD/polling... ⚠️ Not in qcom-next/topics

From integration_presence_report.md:

  • Overall status: FAIL
  • Present commits: 0/2
  • Missing commits: 2/2
  • Both commits are missing from qcom-next (ref 8d5dbc1b17ad) and all topic branches in https://github.com/qualcomm-linux/kernel-topics

Analysis: This is expected for a new PR that has not yet been merged. However, per the skill instructions, commits should ideally be present in qcom-next or a topic branch before merging into the main integration tree. This PR appears to be introducing new work rather than integrating existing topic-branch commits.


Final Summary

  1. Lore link present: Yes — https://lore.kernel.org/r/20260730-dpshutdown-v2-1-441fc5543bed@oss.qualcomm.com (commit 2/2 only; commit 1/2 is a revert with no lore link, which is acceptable)

  2. Lore link matches PR commits: Yes — commit 2/2 diff is byte-for-byte identical to the lore patch (context line numbers differ due to different base commits, but code hunks match exactly)

  3. Upstream patch status:In review — Posted 2026-07-30 (4 days ago); no maintainer decision yet; Sashiko AI raised concerns but no human maintainer has responded

  4. PR present in qcom-next/topics: Fail — 2/2 commits are missing from both qcom-next and all topic branches (per integration_presence_report.md)


Overall Recommendation

Commit 2/2 (FROMLIST patch):Approve for merge — The patch faithfully represents the lore source and is correctly prefixed as FROMLIST:. The upstream status is "pending review" which is appropriate for a FROMLIST: commit.

Commit 1/2 (Revert): ⚠️ Request improvement — Add a rationale paragraph to the commit message explaining why the revert is needed (e.g., "This driver-specific workaround is no longer needed because the issue is now fixed at the DRM core level in commit 2/2 of this series").

Integration presence concern: Both commits are missing from qcom-next and topic branches. If the workflow requires commits to be present in a topic branch before integration, this PR should first land in an appropriate topic branch (e.g., drm-msm-next or drm-core-next) before being merged into the main integration tree.

Deterministic Integration Presence

Integration Presence Report

This report is generated by Jarvis before validate-patch runs.
It is the authoritative source for whether PR changes are already present
in qcom-next or in the kernel topic branches.

Kernel repo: /local/mnt/workspace/sgaud/Qgenie/image_pipeline/kernel
qcom-next ref: 8d5dbc1b17adf8fe86a41adcda686785e73f5414
topics remote: topics -> https://github.com/qualcomm-linux/kernel-topics
topics fetch: fetched

Commit Subject qcom-next topics Final
1/2 [PATCH 1/2] Revert "FROMLIST: drm/msm/dp: add .shutdown to mask HPD missing - no subject, patch-id, or full tree-content match found missing - no subject, patch-id, or full tree-content match found missing
2/2 [PATCH 2/2] FROMLIST: drm/atomic-helper: tear down HPD/polling in missing - no subject, patch-id, or full tree-content match found missing - no subject, patch-id, or full tree-content match found missing

Final Status

overall_status: FAIL
present_commits: 0/2
partial_commits: 0/2
missing_commits: 2/2
topics_checked_for_commits: 2/2
final_summary: PR present in qcom-next/topics: Fail - 2/2 commit(s) are missing from both qcom-next and topics

@qlijarvis

Copy link
Copy Markdown

PR #1639 — checker-log-analyzer

PR: #1639
Checker run: https://github.com/qualcomm-linux/kernel-config/actions/runs/30903931298

Checker Result Summary
Checker Result Summary
checkpatch Merge conflict - unable to run
dt-binding-check Merge conflict - unable to run
dtb-check Merge conflict - unable to run
sparse-check Merge conflict - unable to run
check-uapi-headers Merge conflict - unable to run
check-patch-compliance Merge conflict - unable to run
tag-check ⚠️ Commit 1/2 missing prefix before Revert
qcom-next-check N/A Not applicable (target: tech/mm/drm)

Detailed report: Full report

Checker analysis — click to expand

🤖 CI Checker Analysis (checker-log-analyzer)

PR: #1639 - drm/msm/dp: HPD shutdown fixes
Source: https://github.com/qualcomm-linux/kernel-config/actions/runs/30903931298
Target branch: tech/mm/drm

Checker Result Summary
checkpatch Merge conflict - unable to run
dt-binding-check Merge conflict - unable to run
dtb-check Merge conflict - unable to run
sparse-check Merge conflict - unable to run
check-uapi-headers Merge conflict - unable to run
check-patch-compliance Merge conflict - unable to run
tag-check ⚠️ Commit 1/2 missing prefix before Revert
qcom-next-check N/A Not applicable (target: tech/mm/drm)

❌ Merge Conflict (All Checkers)

Root cause: The PR cannot be merged with the base branch tech/mm/drm due to a file creation conflict in drivers/gpu/drm/bridge/lontium-lt9611c.c.

Failure details:

Automatic merge failed; fix conflicts and then commit the result.
Merge failed, manual merge

Normal merge conflict for 'drivers/gpu/drm/bridge/lontium-lt9611c.c':
  {local}: created file
  {remote}: created file
automerge returned non-zero; check logs for conflicts

Analysis:
This is a "both added" conflict where both the PR branch and the base branch independently created the same file drivers/gpu/drm/bridge/lontium-lt9611c.c. This type of conflict occurs when:

  • The base branch tech/mm/drm added this file after the PR branch was created
  • The PR branch also needs this file or has changes that conflict with it

Fix:
Rebase the PR branch onto the latest tech/mm/drm:

git fetch origin tech/mm/drm
git rebase origin/tech/mm/drm

# During rebase, resolve the conflict in drivers/gpu/drm/bridge/lontium-lt9611c.c
# Choose the appropriate version or merge both changes manually
git add drivers/gpu/drm/bridge/lontium-lt9611c.c
git rebase --continue

# Force push the rebased branch
git push --force-with-lease

Impact:
All kernel checkers failed at the merge stage before any actual checks could run. The patch content itself was never validated.


⚠️ tag-check — Subject Prefix Issue

Root cause: Commit 1/2 is a Revert commit without a required prefix before the word Revert.

Failure details:

Commit 1/2: "Revert "FROMLIST: drm/msm/dp: add .shutdown to mask HPD IRQ before system shutdown""

Analysis:
According to the tag-check rules for branches other than qcom-next and qcom-next-staging, every commit subject must start with a valid prefix tag. For Revert commits, the prefix must come before the word Revert.

Current subject:

Revert "FROMLIST: drm/msm/dp: add .shutdown to mask HPD IRQ before system shutdown"

The subject starts with Revert but has no prefix tag before it.

Fix:
Add an appropriate prefix before Revert. Since this is reverting a FROMLIST: commit, use either UPSTREAM: or FROMLIST: depending on the revert's upstream status:

git rebase -i <base_sha>   # mark commit 1/2 as 'edit'

# If the revert itself was posted upstream:
git commit --amend -m "FROMLIST: Revert \"FROMLIST: drm/msm/dp: add .shutdown to mask HPD IRQ before system shutdown\""

# OR if the revert is already merged upstream:
git commit --amend -m "UPSTREAM: Revert \"FROMLIST: drm/msm/dp: add .shutdown to mask HPD IRQ before system shutdown\""

git rebase --continue

Note: Commit 2/2 (FROMLIST: drm/atomic-helper: tear down HPD/polling in drm_atomic_helper_shutdown()) correctly has the FROMLIST: prefix and is compliant.


Verdict

BLOCKED - Cannot merge until the following issues are resolved:

  1. Critical: Resolve the merge conflict in drivers/gpu/drm/bridge/lontium-lt9611c.c by rebasing onto the latest tech/mm/drm
  2. Required: Add a prefix tag before Revert in commit 1/2 (e.g., FROMLIST: Revert ... or UPSTREAM: Revert ...)

Once these issues are fixed, re-trigger the CI to run all kernel checkers on the actual patch content.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants