Skip to content

arm64: dts: apple: t8152: CPU idle driver on every M6 - #2333

Draft
RyanTheTide wants to merge 2 commits into
integration/aurorafrom
dtfill/t8152-cpuidle
Draft

RyanTheTide wants to merge 2 commits into
integration/aurorafrom
dtfill/t8152-cpuidle

Conversation

@RyanTheTide

Copy link
Copy Markdown
Contributor

Problem

The Mac mini M6 (J873g) has no cpuidle node, so cpuidle-apple never binds. The CPUs idle through the default WFI without a cpuidle driver, and s2idle cannot freeze the tick or suspend timekeeping. #2107 adds the node to the J804 board file only.

Change

Add cpuidle { compatible = "apple,t8152-cpuidle", "apple,t8140-cpuidle"; } to t8152-peripherals.dtsi. Both the J873g tree and t8152.dtsi (J804, J833ct) include that file. As on T8140, the OS cannot request core power-down and WFI is the only state. The driver's T8140 profile already handles that: it does not touch CYC_OVRD on anything newer than M3.

The binding change is LiamRay11's commit from #2107, carried unchanged (same patch-id), so this can land before or after #2107. If both land, the J804 board file's own cpuidle node merges into this one.

Testing

cpp + dtc before and after: J873g, J804 and J833ct each gain only /cpuidle. dt-validate -m with this branch's bindings reports nothing new on any of them (J873g keeps its 31 existing warnings).

Still to run

  • @sithglan (J873g):
    • cat /sys/devices/system/cpu/cpuidle/current_driver shows cpuidle-apple.
    • /sys/devices/system/cpu/cpu*/cpuidle/state*/usage climbs.
    • One s2idle cycle with N1 and USB up, woken by the power key.
    • Idle power from sensors (PSTR) before and after, if the SMC exposes it.
Details
  • The driver binds by the apple,t8140-cpuidle fallback (drivers/cpuidle/cpuidle-apple.c match table). With no T8152 entry in its CYC_OVRD machine list, both of its states are WFI.
  • Evidence: traces/kernel/20261119-dtfill-m5m6/ (dts-t8152idle, valm-t8152idle-*).

Assisted-by: LLM (Claude:Opus 5.5)

LiamRay11 and others added 2 commits November 19, 2026 23:52
As on T8140, the OS cannot request core power-down on T8152 (M6) and
WFI is the only idle state. Allow "apple,t8152-cpuidle" with the
T8140 compatible as its fallback, which the driver already matches.

Signed-off-by: LiamRay11 <228416644+LiamRay11@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The J873g (Mac mini, M6) has no cpuidle node, so cpuidle-apple never
binds there: the CPUs idle through the default WFI without a cpuidle
driver, and s2idle cannot freeze the tick or suspend timekeeping. The
J804 board file in #2107 adds the node for that board only.

The cores and their idle behaviour are the SoC's: as on T8140, the OS
cannot request core power-down and WFI is the only state, which the
T8140 profile of the driver already handles (CYC_OVRD is left alone on
anything newer than M3). Put the node in t8152-peripherals.dtsi, which
both the J873g tree and t8152.dtsi (J804, J833ct) include.

Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
@sithglan

Copy link
Copy Markdown
Contributor

J873g row. Kernel: #2178's head + this PR's two commits (eaf01a40812f, 35b329e1ba2c here), with CONFIG_ARM_APPLE_CPUIDLE=y. The J873g's configs had it off until now, so a board that wants this also needs the config line.

  • /sys/devices/system/cpu/cpuidle/current_driver: apple_idle (cpuidle-apple's driver name), governor menu.
  • cpu0/cpuidle/state0 and state1 are both WFI, as expected on T8140+. state1 had 1,080,308 entries since boot, and the sum over all CPUs and states rose by 3,606 in 5 s of idle.
  • s2idle cycle: not possible on the J873g today. Its kernel configs (this one and the private desktop one) build without CONFIG_SUSPEND, so there's no /sys/power/mem_sleep. The board also describes no RTC for an alarm wake. Waking with the power key also needs someone at the machine. Enabling suspend on the J873g is a bring-up of its own.
  • Idle power: macsmc-hwmon exposes 136 inputs on the J873g, all temperatures plus the fan, and no PSTR or other power key. So there's no before/after power figure from sensors.

No cpuidle warnings in dmesg.

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.

3 participants