Repository navigation
rtc: apple-pmu: wake s2idle through the alarm IRQ - #1443
Closed
DjDeveloperr wants to merge 2 commits into
Closed
DjDeveloperr wants to merge 2 commits into
DjDeveloperr wants to merge 2 commits into
Conversation
Associate the retained PMU alarm interrupt with its wakeup source instead of keeping the thread live through suspend. The IRQ core can then report a wake before the alarm is acknowledged over SPMI, and replay the pending interrupt after device resume. Clear the association on all probe failures and removal. Signed-off-by: Diljit Singh <hey@djdev.me>
The PM core falls back to the platform begin/end callbacks for suspend-to-idle when no s2idle callbacks are installed. Do not arm the platform watchdog, save the platform sleep state or set the firmware-suspend flag for that path. Otherwise device callbacks cut the debug link and prepare for a firmware commit which s2idle never invokes. Only stop the platform watchdog when that preparation ran. Signed-off-by: Diljit Singh <hey@djdev.me>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 10, 2026
Add the EL2 platform sleep provider and coordinate the CPU clusters, interrupt controller, memory, power domains and device firmware across suspend-to-RAM. Keep the USB host and DRAM when their retained-power path is available, and restore the camera's complete ISP DART state at each power-up. Bring the Neo sleep series together with its device resume, refusal, RTC, radio wake, display, audio, PCIe and debug-link fixes. Keep platform preparation out of explicit suspend-to-idle and let the PMU alarm IRQ wake that state. Retain the selected deep default if ANS lacks replay tunables; the existing readiness check still refuses the unsafe transition. Preserve the conservative SMC warning and outbox waits. Match only the measured T8140 provider; other SoCs require their own supported provider. Consolidated from Diljit Singh's Neo sleep series through the fin6 source tree, the two standalone RTC/state fixes in #1443, and the isolated ANS selection policy correction. Integration's AWDL, NVMe crash-session and RTKit state-query changes are retained alongside the sleep interfaces. Describe the ISP power-domain tuples separately for T8140 and T8142, with matching examples. Keep the ATC sleep-result constant available to consumers when the PHY implementation is unreachable. Signed-off-by: Diljit Singh <hey@djdev.me>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 10, 2026
Add the EL2 platform sleep provider and coordinate the CPU clusters, interrupt controller, memory, power domains and device firmware across suspend-to-RAM. Keep the USB host and DRAM when their retained-power path is available, and restore the camera's complete ISP DART state at each power-up. Bring the Neo sleep series together with its device resume, refusal, RTC, radio wake, display, audio, PCIe and debug-link fixes. Keep platform preparation out of explicit suspend-to-idle and let the PMU alarm IRQ wake that state. Retain the selected deep default if ANS lacks replay tunables; the existing readiness check still refuses the unsafe transition. Preserve the conservative SMC warning and outbox waits. Match only the measured T8140 provider; other SoCs require their own supported provider. Consolidated from Diljit Singh's Neo sleep series through the fin6 source tree, the two standalone RTC/state fixes in #1443, and the isolated ANS selection policy correction. Integration's AWDL, NVMe crash-session and RTKit state-query changes are retained alongside the sleep interfaces. Describe the ISP power-domain tuples separately for T8140 and T8142, with matching examples. Keep the ATC sleep-result constant available to consumers when the PHY implementation is unreachable. Compile the real Apple DWC3 object in CI for built-in/module glue with ATC absent and built-in glue with modular ATC. Assert the resolved Kconfig values before compilation and retain per-profile compiler/config receipts. Signed-off-by: Diljit Singh <hey@djdev.me>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 10, 2026
Add the EL2 platform sleep provider and coordinate the CPU clusters, interrupt controller, memory, power domains and device firmware across suspend-to-RAM. Keep the USB host and DRAM when their retained-power path is available, and restore the camera's complete ISP DART state at each power-up. Bring the Neo sleep series together with its device resume, refusal, RTC, radio wake, display, audio, PCIe and debug-link fixes. Keep platform preparation out of explicit suspend-to-idle and let the PMU alarm IRQ wake that state. Retain the selected deep default if ANS lacks replay tunables; the existing readiness check still refuses the unsafe transition. Preserve the conservative SMC warning and outbox waits. Match only the measured T8140 provider; other SoCs require their own supported provider. Consolidated from Diljit Singh's Neo sleep series through the fin6 source tree, the two standalone RTC/state fixes in #1443, and the isolated ANS selection policy correction. Integration's AWDL, NVMe crash-session and RTKit state-query changes are retained alongside the sleep interfaces. Describe the ISP power-domain tuples separately for T8140 and T8142, with matching examples. Keep the ATC sleep-result constant available to consumers when the PHY implementation is unreachable. Compile the real Apple DWC3 object in CI for built-in/module glue with ATC absent and built-in glue with modular ATC. Assert the resolved Kconfig values before compilation and retain per-profile compiler/config receipts. Reconcile with the merged M5 foundation while retaining outer-consumer progress, event/report ordering, optional region C and firmware-owned DART interfaces. Leave all T6050 restart profiles disabled until independently qualified. Signed-off-by: Diljit Singh <hey@djdev.me>
DjDeveloperr
added a commit
that referenced
this pull request
Nov 10, 2026
Add the EL2 platform sleep provider and coordinate the CPU clusters, interrupt controller, memory, power domains and device firmware across suspend-to-RAM. Keep the USB host and DRAM when their retained-power path is available, and restore the camera's complete ISP DART state at each power-up. Bring the Neo sleep series together with its device resume, refusal, RTC, radio wake, display, audio, PCIe and debug-link fixes. Keep platform preparation out of explicit suspend-to-idle and let the PMU alarm IRQ wake that state. Retain the selected deep default if ANS lacks replay tunables; the existing readiness check still refuses the unsafe transition. Preserve the conservative SMC warning and outbox waits. Match only the measured T8140 provider; other SoCs require their own supported provider. Consolidated from Diljit Singh's Neo sleep series through the fin6 source tree, the two standalone RTC/state fixes in #1443, and the isolated ANS selection policy correction. Integration's AWDL, NVMe crash-session and RTKit state-query changes are retained alongside the sleep interfaces. Describe the ISP power-domain tuples separately for T8140 and T8142, with matching examples. Keep the ATC sleep-result constant available to consumers when the PHY implementation is unreachable. Compile the real Apple DWC3 object in CI for built-in/module glue with ATC absent and built-in glue with modular ATC. Assert the resolved Kconfig values before compilation and retain per-profile compiler/config receipts. Reconcile with the merged M5 foundation while retaining outer-consumer progress, event/report ordering, optional region C and firmware-owned DART interfaces. Leave all T6050 restart profiles disabled until independently qualified. Signed-off-by: Diljit Singh <hey@djdev.me> Arm SEP wake completion before releasing the held receive IRQ. This preserves an early wake notification instead of clearing it after RX has resumed. Native abort recovery and final qualification stay open.
Contributor
Author
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.
The J700's PMU alarm did not return a suspend-to-idle test. Associate its alarm interrupt with the device wake source and remove IRQF_NO_SUSPEND, so the IRQ core can wake the system before the thread acknowledges the alarm through SPMI. Balance the wake-IRQ association on probe failures and removal.
Also keep explicit s2idle out of Apple platform preparation. The PM core calls the platform begin/end callbacks for s2idle when there are no s2idle callbacks. Begin previously saved pins, armed the deep watchdog and set the firmware-suspend flag unconditionally, causing a debug-link cut and deferred SEP preparation even though s2idle never invokes the platform commit. Gate that preparation on PM_SUSPEND_MEM, clear the stale cut marker in RAM, and disarm WD2 only for the firmware transition that owns it. Keep the PM outcome flags through resume callbacks.
Stacked on #1437 (and #1398), tested on J700 with the Fedora 44 config:
Only the J700 hardware result is claimed. Other SoCs are not added to the platform driver. The rare-reset and SEP cancellation failures remain separate work; these targeted rows do not replace the retained fin6 40/40 soak or claim final production validation. No raw register probes, input wake masking, long power runs, merges, releases or pin bumps.
Exact source/builds and traces: migration/neo-continuation-20261108/final-validation/{rows/fin8-s2idle.,rows/fin9-s2idle.,rows/fin8-platform-camera.txt,RESULT.md,LIVE.md}.
🤖 Generated with Codex