Repository navigation
soc: apple: clpc: Low Power mode CPU ceiling from the device tree (J614s/J614c 2616, J616s/J616c 2808 MHz) - #1796
Conversation
|
@DjDeveloperr still clean against integration/aurora with CI green, and it's in the daily kernel I run on my J614c (power-saver caps the P clusters at 2616 MHz, as the J614c's ADT has it). Anything you'd like changed? |
|
Thanks for catching the 14"/16" difference, and for running it daily on the J614c. One structural change before this goes in. We select behaviour by a hardware property, not by a list of machines, and this value is already a per-machine hardware property: the ADT's
Suggested shape: a DT property on the CLPC node (for example If you add the property, we can run power-saver rows on our M4 Pro and A18 Pro, and on the M1 Pro and M2 where the ADT has a value. |
44e3272 to
25ab204
Compare
|
Thanks, that's a better shape. Reworked as you suggested, rebased on current
Tested on the J614c with the same change on my daily kernel:
A loader that fills the property from the ADT would cover the other machines without Thanks for the offer to run power-saver rows on your M4 Pro, A18 Pro, M1 Pro and M2. 🤖 Generated with Claude Code |
|
Thanks, this is the shape we were after, and the J614c numbers are clear. One coordination point: #1906 adds a second property for the same ADT key ( |
macOS's Low Power mode CPU ceiling is a property of each machine, not of its SoC: the ADT's cpu-low-power-frequency-max is 2616 MHz on the 14-inch J614s and J614c and 2808 MHz on the 16-inch J616s and J616c. Add apple,low-power-frequency-max-mhz to the performance controller node, for the board to give that value. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Jos Dehaes <jos.dehaes@gmail.com>
The T6041 low-power profile took macOS's Low Power mode CPU ceiling from the J616c's ADT, 2808 MHz, for every M4 Max, and the M4 Pro got no profile. The ceiling is the machine's own: the 14-inch J614s and J614c have 2616 MHz there. Read the ceiling from the CLPC node's apple,low-power-frequency-max-mhz and offer the low-power profile wherever it is set, so no machine compatible decides it. T6040 and T6041 get no SoC default; T6050 keeps 2808 MHz for its boards that don't give their own. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Jos Dehaes <jos.dehaes@gmail.com>
Give each M4 Pro and M4 Max MacBook Pro its ADT's cpu-low-power-frequency-max: 2616 MHz on the 14-inch J614s and J614c, 2808 MHz on the 16-inch J616s and J616c. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Jos Dehaes <jos.dehaes@gmail.com>
25ab204 to
4b8f126
Compare
|
Thanks. The dt-checks failure was mine: a On the name: I've proposed 🤖 Generated with Claude Code |
#1727 gave the M4 Max macOS's Low Power mode, with the CPU ceiling from the J616c's ADT (
cpu-low-power-frequency-max = 2808MHz) for everyapple,t6041machine. The ceiling is a property of each machine: the macOS 26.6.2 ADTs have 2616 MHz on the 14-inch J614s and J614c, and 2808 MHz on the 16-inch J616s and J616c. So in power-saver the J614c's P clusters ran one table step higher than macOS lets them, and the M4 Pro got no profile at all.Change
Following the review, the ceiling is now a device tree property instead of a machine table in the driver:
apple,low-power-frequency-max-mhzon the CLPC node (performance-controller@1). It's in MHz, the ADT's own unit, so a loader can copycpu-low-power-frequency-maxas is.low_power_machineand itsof_machine_is_compatible()check are gone. T6040 and T6041 have no SoC default, so a board without the property gets no profile. T6050 keeps its 2808 MHz as a fallback for boards that don't set the property, because I don't have the M5 boards' ADT values.Testing
J614c (MacBook Pro 14" M4 Max), os-fw 26.6.2, with this change on my daily kernel (integration plus T6041 PRs), built with
CONFIG_ACPI=y(see below).The J614c DTB validates against the binding (
dt-validate). The CLPC node hasapple,low-power-frequency-max-mhz = <2616>.scaling_max_freq:Back to balanced restores 4512 MHz.
From the first version of this PR, with the same 2616 MHz ceiling: an all-core spin (16 threads) for 14 s, on battery, SMC "Total System Power" after 7 and 10 s:
Idle is 4.7 W in both. Boost was off in that run, hence 4104 MHz (the top non-boost frequency) in balanced. It's on in the run above.
I couldn't test the J614s, J616s or J616c; their values come from their ADTs.
Note: the profile only registers with
CONFIG_ACPI_PLATFORM_PROFILE, which lives underdrivers/acpi/and is only built withCONFIG_ACPI=y. The aurora package config still has# CONFIG_ACPI is not set, so with the shipped kernel no machine gets a platform profile. With no ACPI tables, anCONFIG_ACPI=ykernel logs "ACPI: Interpreter disabled" and boots from the DT as before.🤖 Generated with Claude Code