Repository navigation
PCI: apple: attach all internal-host power domains and retain them in s2idle - #1311
Merged
RyanTheTide merged 8 commits intoNov 9, 2026
Conversation
Devices with multiple power-domains entries are not attached by the platform bus. Attach each domain with an active device link before touching the controller, while leaving the single-domain attachment to the bus. Preallocate one notifier per attached domain and extend the PCIe-C sleep hold to cover all of them. Internal hosts leave their links running in suspend-to-idle and cannot recover from a power cycle, so veto power-off on every domain until resume. Unwind partial holds on error and abort suspend rather than lose an internal link. Assisted-by: LLM Signed-off-by: Ryan Murray <[email protected]>
The internal host needs both the general-purpose and storage/PHY chains listed by the ADT clock gates. On J616s APCIE_SYS_GP reaches APCIE_GP, while APCIE_PHY_SW reaches both storage chains and ANS. On T8112 APCIE_ST adds the ANS/storage chain that NVMe happens to keep powered today. Keep the J616s interim always-on states until the host can cold-initialize its internal links after resume. Assisted-by: LLM Signed-off-by: Ryan Murray <[email protected]>
…r chain The T8140 ADT gates APCIE_GP, APCIE_SYS_GP, APCIE_ST, APCIE_SYS_ST, ANS and APCIE_PHY_SW for apcie0. APCIE_PHY_SW already has all of the other domains as ancestors, so attach the host to that leaf instead of APCIE_GP alone. This removes its dependency on NVMe keeping the storage and PHY chain on. The host retains this chain during suspend-to-idle while the radio wake path leaves the internal link running. Assisted-by: LLM Signed-off-by: Ryan Murray <[email protected]>
The domain-attachment helper is a no-op without CONFIG_PM. Keep the host usable in that configuration instead of treating its zero return as a missing domain. Assisted-by: LLM Signed-off-by: Ryan Murray <[email protected]>
The internal PCIe controller on T6040 and T8112 needs two power domain chains to stay on while its links are up. Allow up to two entries. Assisted-by: LLM Signed-off-by: Ryan Murray <[email protected]>
# Conflicts: # drivers/pci/controller/pcie-apple.c
…ull power chain" This reverts commit 5c96ab0. The Neo change has not been tested on hardware yet; it comes back as its own change once it has. Assisted-by: LLM Signed-off-by: Ryan Murray <[email protected]>
# Conflicts: # drivers/pci/controller/pcie-apple.c
RyanTheTide
marked this pull request as ready for review
November 9, 2026 19:00
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
Brings in #1311 (PCI: apple: multi power domain support). Conflicts in drivers/pci/controller/pcie-apple.c: - apple_pcie_attach_domains() and the Neo host's bootloader-replay and sleep functions both kept, each with its own return. - apple_pcie_resume_noirq(): the domain hold is released first, then the armed Neo sleep returns to its own resume. The armed suspend returns before any hold is taken, so the release is a no-op there and the commit still powers the APCIe block down; s2idle and other hosts hold and release as in integration. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
…omains Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
…-edac-slpddr-wake Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
…pcie-slpddr Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
…elect Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
…neric Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
…roc-crash Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 9, 2026
…ug-cut-wakes Brings in integration/aurora ac11649 (#1311, PCIe multi power domain support) through #1208. No conflicts. Signed-off-by: Diljit Singh <[email protected]>
This was referenced Nov 10, 2026
Merged
RyanTheTide
deleted the
ctl/t-5958-pcie-apple-multi-power-domain-support-for-the-in
branch
November 16, 2026 05:02
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Internal PCIe hosts leave their links running through suspend-to-idle and cannot retrain them after losing power. A host with several
power-domainsentries also needs explicit genpd attachment; the platform bus only attaches a single domain.Attach every listed domain with
PD_FLAG_DEV_LINK_ON, preallocate one notifier per domain, and veto power-off throughout internal-host s2idle. A failed hold unwinds earlier registrations and aborts suspend. The existing PCIe-C retention path uses the same helper. Single-domain hosts retain platform-bus attachment. CONFIG_PM=n keeps its no-op attachment behavior.Describe both independent power chains for J616s and T8112. The T8140 change (APCIE_PHY_SW) is not part of this PR; it comes separately once it has run on hardware. The T6000 ADT audit shows its existing APCIE_GP_SYS chain is complete, so its DT is unchanged. Keep the interim J616s always-on states until internal-link cold resume is implemented.
Validation:
power-domains: genpd shows the host attached to bothapcie_gpandapcie_st(both on, device active). rtcwake s2idle (PMU RTC) x6: 6/6 entered and resumed, 0 failures, Wi-Fi reassociated in 5-9 s, Bluetooth powered, NVMe 2.1-2.3 GB/s direct reads, 3 PCIe functions present after every cycle, no PCIe/genpd warnings. FLEET regression suite (full, incl. 12 system-sleep cycles and 3 more rtcwake s2idle): same results as fleet44 (glmark -0.2%); the only kernel WARNs are the knowntb_cfg_read: -107from the Thunderbolt XDomain state work during suspend, unrelated to this host. 0 new AVCs.power-domains = <&ps_apcie_sys_gp>, <&ps_apcie_phy_sw>:apcie_sys_gpandapcie_phy_sw(both on, device active).The binding now allows a second power domain (7f520fa2); dt-checks pass.
🤖 Generated with Claude Code