Skip to content

[26.04_linux-nvidia-bos] NVIDIA: SAUCE: pinctrl: mt8901: sync wake EINT event mask - #636

Closed
kbutala-nv wants to merge 1 commit into
NVIDIA:26.04_linux-nvidia-bosfrom
kbutala-nv:i2c-wakeup-bos
Closed

kbutala-nv wants to merge 1 commit into
NVIDIA:26.04_linux-nvidia-bosfrom
kbutala-nv:i2c-wakeup-bos

Conversation

@kbutala-nv

@kbutala-nv kbutala-nv commented Oct 8, 2026 •

Copy link
Copy Markdown

LP: https://bugs.launchpad.net/bugs/2170130

MT8901 EINT has a separate event mask that controls whether an EINT can be forwarded as a wake event. The current driver clears that mask only for the static SoC list, which covers the ACPI event line.

Firmware-described devices can be marked wake-capable independently, so PM arms their IRQs through the normal irq_set_wake path. Clear the hardware event mask when the IRQ core enables such an EINT as a wake source so keyboard, touchpad, and other firmware-declared EINT wake sources can reach the SPM without adding board-specific EINT numbers.

Restore the hardware event mask when wake is disabled, otherwise a pin that was armed once would remain an SPM wake event until reboot. Keep pins from the SoC static event-unmask list unmasked so permanently required wake events such as the ACPI event line remain armed.

Make event-mask register programming opt-in for SoCs that declare support for it, and re-apply both the static list and dynamically armed wake_mask pins on resume in case the event register state is lost across system sleep.

Fixes: 927eeda ("NVIDIA: SAUCE: pinctrl: mt8901: Enable ACPI wake-event EINT support")

This is needed for internal bug 6839927

@nirmoy nirmoy added the help wanted Extra attention is needed label Oct 8, 2026
@nirmoy

nirmoy commented Oct 8, 2026 •

Copy link
Copy Markdown
Collaborator

BaseOS Kernel Review

Warning

⚠️ Review needs attention

The event-mask behavior appears correct, but its comment inaccurately says event_clr itself is cleared rather than the event-mask bit via that command register.

Findings: Critical 0 · High 0 · Medium 0 · Low 1

🔍 Review artifacts

📦 Build checks — 🟢 4/4 passed

Note

Build reports and debs are retained for 10 days after the PR closes.

  • ⚪ PR explanation: inactive
Review metadata
  • Reviewed head: cd0924659926
  • Overall status: attention needed
  • Build checks: 4/4 passed

This comment is maintained by BaseOS Reviewer and updated when the GitHub watcher publishes a newer review.

@github-actions

github-actions Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

PR Validation Report

Patchscan ✅ No Missing Fixes

All cherry-picked commits checked — no missing upstream fixes found.

PR Lint ✅ All checks passed

Details
Checking 1 commits...

Cherry-pick digest:
┌──────────────┬──────────────────────────────────────────────────────────────────┬────────────┬─────────┬───────────────────────────┐
│ Local        │ Referenced upstream / Patch subject                              │ Patch-ID   │ Subject │ SoB chain                 │
├──────────────┼──────────────────────────────────────────────────────────────────┼────────────┼─────────┼───────────────────────────┤
│ cd0924659926 │ [SAUCE] pinctrl: mt8901: sync wake eint event mask               │ N/A        │ N/A     │ kbutala                   │
└──────────────┴──────────────────────────────────────────────────────────────────┴────────────┴─────────┴───────────────────────────┘

Lint: all checks passed.

@nirmoy

nirmoy commented Oct 8, 2026

Copy link
Copy Markdown
Collaborator
Acked-by: Nirmoy Das <nirmoyd@nvidia.com>

Please add the following Fixes: trailer:

Fixes: 2b5846e74c20c05dbdb391a926a0a2185817b71e ("NVIDIA: SAUCE: pinctrl: mt8901: Enable ACPI wake-event EINT support")

Please also add Launchpad #2170130 as the first line of the PR description.

MT8901 EINT has a separate event mask that controls whether an EINT can
be forwarded as a wake event. The current driver clears that mask only
for the static SoC list, which covers the ACPI event line.

Firmware-described devices can be marked wake-capable independently,
so PM arms their IRQs through the normal irq_set_wake path. Clear the
hardware event mask when the IRQ core enables such an EINT as a wake
source so keyboard, touchpad, and other firmware-declared EINT wake
sources can reach the SPM without adding board-specific EINT numbers.

Restore the hardware event mask when wake is disabled, otherwise a pin
that was armed once would remain an SPM wake event until reboot. Keep
pins from the SoC static event-unmask list unmasked so permanently
required wake events such as the ACPI event line remain armed.

Make event-mask register programming opt-in for SoCs that declare
support for it, and re-apply both the static list and dynamically
armed wake_mask pins on resume in case the event register state is
lost across system sleep.

Fixes: 927eeda ("NVIDIA: SAUCE: pinctrl: mt8901: Enable ACPI wake-event EINT support")
Signed-off-by: Kaushal Rajeev Butala <kbutala@nvidia.com>
@kbutala-nv

Copy link
Copy Markdown
Author
Acked-by: Nirmoy Das <nirmoyd@nvidia.com>

Please add the following Fixes: trailer:

Fixes: 2b5846e74c20c05dbdb391a926a0a2185817b71e ("NVIDIA: SAUCE: pinctrl: mt8901: Enable ACPI wake-event EINT support")

Please also add Launchpad #2170130 as the first line of the PR description.

Done!

@clsotog

clsotog commented Oct 8, 2026

Copy link
Copy Markdown
Collaborator

Acked-by: Carol L Soto <csoto@nvidia.com>

@nirmoy nirmoy added has_2_acks and removed help wanted Extra attention is needed has_1_ack labels Oct 8, 2026
@nvmochs

nvmochs commented Oct 8, 2026

Copy link
Copy Markdown
Collaborator

Merged, closing PR.

7832686f3a7b NVIDIA: SAUCE: pinctrl: mt8901: sync wake EINT event mask

@nvmochs nvmochs closed this Oct 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants