Skip to content

soc: apple: clpc: J714s: tell the SMC about High Power mode (performance profile lifts the fan ceiling) - #2056

Merged
DjDeveloperr merged 1 commit into
integration/aurorafrom
m5-parity6/t6050-clpc-high-power
Nov 16, 2026
Merged

DjDeveloperr merged 1 commit into
integration/aurorafrom
m5-parity6/t6050-clpc-high-power

Conversation

@DjDeveloperr

@DjDeveloperr DjDeveloperr commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

On the M5 Pro (J714s) the performance platform profile set no limit, matching macOS's High Power mode, which sets none either. But the SMC was never told about it, so under a sustained load the fans kept Automatic's ceiling, well below their maximum. In macOS, High Power mode lets them run up to it.

What macOS does (J714sAP, 27.0 26A428 under aura, same CPU+GPU load in each mode)

  • At every power-mode change, thermalmonitord writes a 120-byte record to the SMC key zETM:
    • byte 0: a record type, 0x1d;
    • byte 1: a version, 1;
    • byte 2: a count of the records written;
    • byte 112: a float, 1.0 while High Power mode is on and 0.0 otherwise.
  • It's the only SMC write that the SMC accepts and that changes with the mode. Other keys written at the same moment are refused by the SMC, or carry no mode, and nothing else touches the fans.
  • Under the load the fans plateau at about 4950/5350 rpm in Automatic. In High Power mode they climb past 6100/6600 within a minute, and fall back to the Automatic plateau after the switch back.

Change

  • On a change to or from performance, the CLPC writes that record. So performance is High Power mode as the SMC sees it, and low-power and balanced are Automatic.
  • A failed write leaves the profile as it was.
  • The SMC is found through the existing apple,smc phandle. The lookup is factored out of the PHPC reader, and the write runs under the sample lock as that read does.
  • Only on the J714s, where it was traced and tested (high_power_machine).
  • debugfs status gains a line with what the SMC was last sent.
  • With power-profiles-daemon's platform_profile driver (the class-device support in alarm-aurora's 0.30-1.1), the desktop's power-mode switch reaches this path.

Validation (J714s)

11-16, lab boot 7.3.0-m5-par6: the M5 default's source (intg8) plus this PR and #2055, built natively on the M5, one test boot. The load was 18 FMA threads plus headless GPU ALU compute, the same load as the macOS runs. The profile was switched with powerprofilesctl (power-profiles-daemon 0.30-1.1 with the class patch), the desktop's own path. Fan readings are fan1/fan2 rpm (actual and target).

phase fans debugfs
balanced, 0-90 s 2316/2502 → plateau 4951/5347 from 70 s smc high power: off
performance, 90-182 s 5474/5911 at +10 s, 6679/7213 at +30 s, 7245/7824 from +40 s (maximum 7826) on (3 records sent)
balanced again 6581/7107 at +10 s, back to 4951/5347 by +40 s off (4 records sent)
  • macOS on the same Mac and load: 4951/5347 in Automatic, 7246/7806 in High Power mode.
  • The zETM record alone is enough: the other records written at the same moment are not needed for the ceiling.
  • The die stayed at about 109 °C throughout (the fast-die limit holds it). The FMA loop averaged 119.9 Gfma/s.
  • No oops, no MMU/DART faults; the default came back byte for byte.

🤖 Generated with Claude Code

The performance platform profile set no limit, as macOS's High Power mode
sets none, but the SMC never heard of it: under a sustained load the fans
kept Automatic's ceiling, well below their maximum.

macOS tells the SMC its power mode through the 120-byte zETM record that
thermalmonitord writes at every mode change: a record type (0x1d), a
version (1), a count of the records written, and at byte 112 a float that
is 1.0 while High Power mode is on and 0.0 otherwise. It is the only SMC
key that changes with the mode. The CLPC now writes that record when the
profile changes to or from performance, so performance is High Power mode
and low-power and balanced are Automatic, as the SMC sees them. A failed
write leaves the profile as it was.

Only on the J714s, the machine it was traced and tested on. debugfs
status shows what the SMC was last sent.

Signed-off-by: Diljit Singh <[email protected]>
@DjDeveloperr
DjDeveloperr marked this pull request as ready for review November 16, 2026 09:31
@DjDeveloperr
DjDeveloperr merged commit d5a8a25 into integration/aurora Nov 16, 2026
7 checks passed
@RyanTheTide
RyanTheTide deleted the m5-parity6/t6050-clpc-high-power branch November 17, 2026 23:53
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.

1 participant