Repository navigation
arm64: dts: apple: t8122: PMU RTC alarm and P-core boost states - #2562
Merged
Merged
Conversation
The T8122 nub SPMI bus carries the same Stowe PMIC as the T8112, with the RTC block at the same registers: a 65536 Hz counter, a whole-second comparator and the six-byte rtc_offset cell the SMC RTC already uses. Only the alarm was missing, so the M3 machines had no RTC wakealarm. Describe the nub SPMI controller as an interrupt controller (its AP interrupt is AIC 437) and add the PMU RTC under the PMIC, falling back to the T8112 match data. The binding gets the t8122 compatible. Signed-off-by: Ryan Murray <[email protected]>
The T8122 P cluster only reaches its top five states with one or two cores busy. With four busy P cores each core runs at about 3625 MHz (the 3636 MHz state) whatever state is requested; with two, at about 3950 MHz; with one, at 4053 MHz. The other Apple SoCs mark such states turbo-mode, T8122 marks none. Mark 3720 to 4056 MHz turbo-mode. apple-soc-cpufreq starts with boost on for this SoC, so the default does not change; boost can now be switched off to hold the P cores at the all-core state. Signed-off-by: Ryan Murray <[email protected]>
DjDeveloperr
approved these changes
Nov 20, 2026
DjDeveloperr
left a comment
Contributor
There was a problem hiding this comment.
Approving and merging. Thanks, this is a clean port of the T8112 arrangement.
- PMU RTC: the
nub_spmiinterrupt controller (t8122.dtsi:1028-1031) and thepmu_rtcnode (:1037-1044) matcht8112.dtsiline for line: Stowe on usid 0xe, SPMI interrupt 2 rising, the sharedrtc_offsetcell, andwakeup-source. AIC 437 comes from the J615's ADT, so it's a SoC fact rather than a board one. Theapple,t8122-pmu-rtc/apple,t8112-pmu-rtcfallback means no driver change is needed, and the binding item (apple,j700-pmu-rtc.yaml:44-46) accepts exactly that pair. - Boost states:
turbo-modeon opp16-opp20 (:351-379) changes nothing by default.apple-soc-cpufreq.c:1664-1665starts with boost on for every SoC except T8112, which fits your 4056 MHz default reading and the 3636 MHz cap with boost off. Your clock measurements (4053 MHz on one core, about 3600 on three or four) back up calling these states boost.
Optional follow-up: neither J613 nor J615 has an rtc0 alias, so the PMU RTC is rtc0 only because it probes before the SMC RTC. rtcwake and hctosys default to rtc0, and the SMC RTC has no alarm. An alias pinning rtc0 to &pmu_rtc (plus a label on the SMC RTC node at :1185 if you want it as rtc1) would make the tested setup deterministic. Note that J413 does it the other way round (t8112-j413.dts:26-27).
CI on 1135a0a: Device tree checks and Host tests are green. All commits are signed off.
Post-merge row: one J613 boot with an alarm wake from s2idle. It's the same SoC, but a different board.
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.
Problem
The M3 machines (T8122) have no RTC wake alarm: the only RTC is the SMC one, which has no alarm, so a planned suspend has nothing to wake it. Their P-core boost states are also not marked as such in the device tree.
Change
t8122.dtsi: describe the nub SPMI controller as an interrupt controller and add the PMU RTC under the PMIC. The PMIC is the same Stowe part as on T8112, with the RTC block at the same registers (65536 Hz counter, whole-second comparator, six-byte offset shared with the SMC RTC), so the node falls back toapple,t8112-pmu-rtcand needs no driver change.apple,t8122-pmu-rtcwith that fallback.t8122.dtsi: mark the P-cluster states from 3720 to 4056 MHzturbo-mode. On a J615 these only run with one or two busy P cores; with three or four, every core runs at about 3625 MHz whatever is requested. apple-soc-cpufreq starts with boost on for this SoC, so nothing changes by default; boost can now be turned off.Testing
On a J615 (MacBook Air 15", M3):
cpufreq/boostlimits the P policy to 3636 MHz and lists the five boost states; writing 1 restores 4056 MHz.make dt_binding_check(this binding) andmake CHECK_DTBS=yfor t8122-j613/j615 against the RTC and SPMI schemas: no warnings.Still to run
Details
Assisted-by: LLM (Claude:Opus 5.5)