Skip to content

soc: apple: clpc: take High Power mode from the device tree - #2310

Draft
RyanTheTide wants to merge 3 commits into
integration/aurorafrom
sweep/soc-gates-clpc
Draft

RyanTheTide wants to merge 3 commits into
integration/aurorafrom
sweep/soc-gates-clpc

Conversation

@RyanTheTide

Copy link
Copy Markdown
Contributor

Problem

drivers/soc/apple/clpc.c:2045 (0abc2f3) sent macOS's High Power mode record (SMC key zETM) on the performance platform profile only when the machine compatible was apple,j714s. The gate came from f04da7c. Every other M5 Pro or M5 Max MacBook Pro offers the same mode, and each needed its own entry. #2214 adds the K116s that way.

Change

  • dt-bindings: apple,high-power-mode (boolean) on the PMC's performance-controller node. It means the Mac offers High Power mode.
  • dts: set on the T6050 MacBook Pros J714s, J714c, J716s, J716c, K114s, K114c, K116s and K116c. M4 Pro and M4 Max MacBook Pros offer the mode too. The Mac mini (J873s) and Mac Studio (J775c, J775d) are left without it.
  • clpc: high_power follows the node property. The per-SoC table keeps only high_power_record, which says whether this SoC's SMC takes the record. It is on for T6050, where the record was traced. A comment explains why T6040/T6041 keep it off: their SMC's record has not been checked, and a write the SMC refuses would make every switch to the performance profile fail.

On the J714s nothing changes. The K116s now has the property, but its dts still removes the CLPC's apple,smc link, so it sends no record until that link is enabled (#2214's dts change). After this PR, #2214's driver change is not needed.

The High Power mode support was written by Diljit Singh.

Testing

  • Build, release config, LLVM: make W=1 drivers/soc/apple/clpc.o. No new warnings. make dtbs: no warnings.
  • DT before and after (base 0abc2f3): the only change on the eight MacBook Pros is apple,high-power-mode; in performance-controller@1. J873s, J775c and J775d are unchanged.

Still to run

None of our lab Macs is a T6050. J616s (T6040) has no platform profile, Neo (T8140) has no low-power profile, and M1 Pro and M2 have no CLPC node, so none of them is reached. A J714s owner can check it: echo performance > /sys/firmware/acpi/platform_profile; grep -h "smc high power" /sys/kernel/debug/*/status should show smc high power: on.

DT diff (built dtbs)
t6050-j714s  > apple,high-power-mode;   (also j714c j716s j716c k114s k114c k116s k116c)
t6050-j873s  no change
t6050-j775c  no change
t6050-j775d  no change

Assisted-by: LLM (Claude:Opus 5.5)

Whether a Mac offers macOS's High Power mode is a property of the board
(its cooling and power delivery), not of the SoC: on the same M5 Pro and
Max the MacBook Pros offer it. Describe it on the performance controller
node so the CLPC driver can turn it on without a board list.

Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
Every M5 Pro and M5 Max MacBook Pro offers macOS's High Power mode, as the
M4 Pro and M4 Max MacBook Pros do: the 14-inch and 16-inch J714s, J714c,
J716s, J716c and the K114s, K114c, K116s, K116c. Set apple,high-power-mode
on their CLPC node.

The Mac mini and Mac Studio boards (J873s, J775c, J775d) are left without
it.

Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
The performance platform profile sends macOS's High Power mode record
(zETM) to the SMC only when the machine compatible is apple,j714s. Every
other M5 Pro or Max MacBook Pro offers the same mode through the same SMC
record, and each new one needed another entry (#2214 adds the K116s).

Which boards offer the mode is now the CLPC node's apple,high-power-mode
property. The per-SoC table keeps only whether the SMC takes the record
(T6050, where it was traced); T6040/T6041 keep it off with the reason in
a comment, because a record their SMC refuses would fail every switch to
the performance profile.

On the J714s nothing changes. The K116s still has no CLPC SMC link in its
device tree, so it stays without the record until that link is enabled.

The High Power mode support was written by Diljit Singh.

Fixes: f04da7c ("soc: apple: clpc: J714s: tell the SMC about High Power mode")
Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
@RyanTheTide

Copy link
Copy Markdown
Contributor Author

Early note on this draft (no full review yet):

  1. drivers/soc/apple/clpc.c:2050 (and the check at clpc.c:1509): high_power_record is still a per-SoC switch (on for T6050, off for T6040/T6041) on top of the new apple,high-power-mode property. Let the DT carry the whole decision: set apple,high-power-mode only on boards whose SMC takes the record, and drop the per-SoC flag, or probe the SMC for the key at probe time and enable the record only when the SMC exposes it.

Assisted-by: LLM (Claude:Opus 5.5)

@RyanTheTide

Copy link
Copy Markdown
Contributor Author

Closing: the high-power record should be chosen by the device tree property alone (or a probe of the SMC key), without a per-SoC flag next to it.

@RyanTheTide RyanTheTide reopened this Nov 22, 2026
@RyanTheTide

Copy link
Copy Markdown
Contributor Author

Reopened and kept as a draft; the comment above lists what it still needs before review.

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