Skip to content

arm64: dts: apple: t602x: add the CPU energy model (enables EAS on M2 Pro/Max) - #932

Merged
RyanTheTide merged 1 commit into
aurora-silicon:integration/aurorafrom
JJRPF:t6020-energy-model
Nov 10, 2026
Merged

RyanTheTide merged 1 commit into
aurora-silicon:integration/aurorafrom
JJRPF:t6020-energy-model

Conversation

@JJRPF

@JJRPF JJRPF commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

T602x (M2 Pro/Max) has no CPU energy model, so energy-aware scheduling stays off even though apple-soc-cpufreq already registers the model from the OPP table: the cluster OPP tables carry no opp-microwatt, while T8103, T600x, T8112, T8132 and T8140 do. This adds opp-microwatt to every OPP of both core types in t602x-common.dtsi (+23 lines).

Method (derived, not measured on T602x)

T8112 (M2) has the same cores, Blizzard and Avalanche, on the same process, and its opp-microwatt was measured with the SMC cluster power meters. Its per-OPP power is fitted to P = (a + b f) V^2 f per core type, using T6020's voltage for each OPP (from the ADT's pmgr voltage-states: E cluster voltage-states1, P cluster voltage-states5; cluster 1's voltage-states13 is within 6 mV). The fit gives T6020's OPPs, within 6% rms of T8112's measurements for both core types. The energy per cycle rises from each OPP to the next, so no OPP is marked inefficient and cpufreq keeps choosing among all of them; only the scheduler's placement changes. The script is tools/t6020-cpu-em.py in JJRPF/Aurora-DeepIdle.

Result (J414s, MacBook Pro 14" M2 Pro, headless, nothing attached)

  • Same boot, kernel.sched_energy_aware 1 vs 0, 12 paired rounds of 20 s: with the energy model, system power is 0.230 W lower (lower in 12 of 12, sd 0.09 W) and SoC (heatpipe) power 0.156 W lower. This was on a PMP boot; the CPUs sat in CPU PD 79% of the time.
  • Earlier cross-boot comparison without the PMP, one boot each: -0.178 W total, but the SoC difference (-0.037 W) was not significant. An earlier paired run gave 61 mW. So the saving depends on the rest of the idle configuration; with the PMP it is clear.
  • Builds: all six T602x boards (t6020-j414s/j416s/j474s, t6021-j414c/j416c/j475c) build with W=1 and no new warnings (the alias_paths warning at t602x-common.dtsi:14 is already there).
  • Not tested: the 1-busy-core-per-OPP measurement T8132: add the CPU energy model (enables EAS on M4) #524 used on T8132 (this branch uses T8112's measurements instead); the placement effect under load; CHECK_DTBS.

Raw data and the A/B harness: JJRPF/Aurora-DeepIdle, data/idle_erikwb/, tools/idle-ab.py.

This change was developed with Claude Code (Claude Sonnet 5.5, Anthropic) at the owner's direction.

🤖 Generated with Claude Code

https://claude.ai/code/session_01RuRMQncGu3ukpyW44vHHjQ

@RyanTheTide RyanTheTide left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The commit has no Signed-off-by. Please add yours (DCO, Documentation/process/submitting-patches.rst).

… Pro/Max)

T602x has no CPU energy model, so energy-aware scheduling stays off even though
apple-soc-cpufreq already registers the model from the OPP table: the cluster
OPP tables carry no opp-microwatt, while T8103, T600x, T8112, T8132 and T8140
do. Add opp-microwatt to every OPP of both core types.

The values are derived, not measured on T602x: T8112 (M2) has the same cores,
Blizzard and Avalanche, on the same process, and its opp-microwatt was
measured with the SMC cluster power meters. Its per-OPP power is fitted to
P = (a + b f) V^2 f per core type with T6020's voltage for each OPP (from the
ADT's pmgr voltage-states), and the fit gives T6020's OPPs, within 6% rms of
T8112's measurements for both core types. The energy per cycle rises from each
OPP to the next, so no OPP is marked inefficient and cpufreq keeps choosing
among all of them; only the scheduler's placement changes.

Same-boot A/B on a J414s (M2 Pro), headless idle, kernel.sched_energy_aware 1
vs 0, 12 paired rounds of 20 s: system power is 0.230 W lower with the energy
model (lower in 12 of 12; SoC power 0.156 W). All six T602x boards build with
W=1 and no new warnings.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01RuRMQncGu3ukpyW44vHHjQ
Signed-off-by: Justin Pfister <[email protected]>
@JJRPF
JJRPF force-pushed the t6020-energy-model branch from a174b73 to 27e8000 Compare November 9, 2026 11:42
@JJRPF

JJRPF commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor Author

@RyanTheTide I have added my sign off to the commit.

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