Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,29 @@ properties:
apple,fast-die-effort lets the OS enforce it. The T6050 driver
registers DVFS only when this is present.

apple,all-core-frequency-max-mhz:
description:
CPU frequency ceiling in MHz applied to this cluster by apple-clpc
outside the low-power platform profile (both balanced and performance
profiles, on AC and battery) when all online CPUs of this cluster are
busy across the 100 ms CLPC power window. Must match an OPP in this
cluster's operating-points-v2 table.

apple,slow-cluster-busy-max-mhz:
description:
CPU frequency ceiling in MHz applied to this cluster by apple-clpc
outside the low-power platform profile (both balanced and performance
profiles, on AC and battery) only while a faster cluster is busy. A
cluster with only this ceiling remains uncapped under slow-cluster-only
workloads. Must match an OPP in this cluster's operating-points-v2
table.

apple,sustained-frequency-min-mhz:
description:
Minimum CPU frequency floor in MHz for this cluster under apple-clpc
sustained all-core CPU power regulation (apple,sustained-power-mw).
Must match an OPP in this cluster's operating-points-v2 table.

'#performance-domain-cells':
const: 0

Expand Down
39 changes: 36 additions & 3 deletions Documentation/devicetree/bindings/power/apple,pmc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -283,9 +283,12 @@ patternProperties:
apple,smc:
$ref: /schemas/types.yaml#/definitions/phandle
description:
The SMC, whose package power reading the low-power platform profile
holds the CPU clusters to, and which the performance profile tells
about High Power mode on Macs that have it.
The SMC, whose package power reading (apple,power-key-id) the
low-power platform profile holds the CPU clusters to, whose CPU
cluster rail readings (apple,sustained-power-key-ids) the sustained
all-core CPU power limit regulates against, and which the
performance/low-power profiles notify on Macs that support those
records.

apple,high-power-mode:
type: boolean
Expand All @@ -310,6 +313,31 @@ patternProperties:
apple,power-key-id reading at it with the CPU clusters' ceilings
(and, with apple,low-power-gpu-cap, the GPU's power budget).

apple,sustained-power-key-ids:
$ref: /schemas/types.yaml#/definitions/string-array
minItems: 1
maxItems: 4
items:
pattern: "^[A-Za-z0-9#!]{4}$"
description:
Four-character SMC keys of the CPU cluster power rails (each a
float in watts) summed by the sustained all-core CPU power limit to
exclude GPU and display power. Required with apple,sustained-power-mw.

apple,sustained-power-mw:
$ref: /schemas/types.yaml#/definitions/uint32
description:
Sustained all-core CPU power target in milliwatts applied outside
the low-power platform profile (both balanced and performance
profiles, on AC and battery). Requires apple,smc and
apple,sustained-power-key-ids. While all-core load holds a faster
cluster, the driver polls and sums the SMC's
apple,sustained-power-key-ids readings every 100 ms and steps faster
clusters' frequency ceilings between their all-core ceiling and
their sustained frequency floor (apple,sustained-frequency-min-mhz,
or max(low-power ceiling, half of max frequency) if unset),
releasing immediately when all-core load ends.

apple,power-key-id:
$ref: /schemas/types.yaml#/definitions/string
pattern: "^[A-Za-z0-9#!]{4}$"
Expand Down Expand Up @@ -385,6 +413,11 @@ patternProperties:
- apple,gpu-busy-permille
apple,gpu-busy-permille:
- apple,gpu-busy-memory-states
apple,sustained-power-mw:
- apple,smc
- apple,sustained-power-key-ids
apple,sustained-power-key-ids:
- apple,sustained-power-mw

required:
- compatible
Expand Down
27 changes: 27 additions & 0 deletions arch/arm64/boot/dts/apple/t8132-j604.dts
Original file line number Diff line number Diff line change
Expand Up @@ -685,3 +685,30 @@
&aop_spmi1 {
status = "okay";
};

/*
* J604 CLPC per-cluster all-core and sustained CPU-rail limits (applied
* outside the low-power platform profile, i.e. balanced and performance on
* both AC and battery; J604 has no High Power mode):
* - P-cluster all-core ceiling 3936 MHz, sustained floor 3096 MHz.
* - E-cluster ceiling 2808 MHz only while P-cores are busy (avoiding the
* 2892 MHz power cliff while leaving E-only workloads uncapped).
* - Sustained CPU power target 13.5 W summed across the CPU cluster rails
* (PP0b P-cluster + PPbb E-cluster, excluding GPU PP1b and display).
* - Wiring apple,smc also enables the existing low-power SMC PHPC power
* budgeting loop whenever the boot loader passes Low Power mode values.
*/
&cpufreq_e {
apple,slow-cluster-busy-max-mhz = <2808>;
};

&cpufreq_p {
apple,all-core-frequency-max-mhz = <3936>;
apple,sustained-frequency-min-mhz = <3096>;
};

&clpc {
apple,smc = <&smc>;
apple,sustained-power-key-ids = "PP0b", "PPbb";
apple,sustained-power-mw = <13500>;
};
Loading
Loading