Skip to content

j616s: PMP boots and stays up (endpoint 7, pmp-gfx report) - #402

Merged
RyanTheTide merged 2 commits into
integration/aurorafrom
j616s/pmp-ep7-20261024
Oct 23, 2026
Merged

RyanTheTide merged 2 commits into
integration/aurorafrom
j616s/pmp-ep7-20261024

Conversation

@RyanTheTide

Copy link
Copy Markdown
Contributor

The M4 Pro (T6040, J616s) PMP now boots and keeps running under Linux. Two fixes, one per commit.

soc: apple: pmp: start endpoint 7 on every T6041 PMP
The T6040 PMP firmware advertises system endpoint 7 and asks for a 0x2000 byte buffer on it. Without that endpoint started and served, the IOP power state is never acknowledged and the probe fails with -62. Our RTKit already handles this exchange as CoreAnalytics for the J713 PMP, so this only opens the gate for T6041 on every board. Niklas Sheth found the same dependency in GravityLinux (877c574). This reuses our existing code instead of carrying his.

arm64: dts: apple: t6040: Do not claim the GPU's PMP report entry at boot
With endpoint 7 fixed, the firmware starts ("io.cpp:54: PMP started") and then dies 20 to 70 ms later with an SError. The cause is the always-on pmp-gfx report entry, which tells the PMP the GPU is on when nothing powers it. Leaving the entry unclaimed keeps the PMP alive. The entry gets a label so a future GPU node can take it as a power domain.

Tested on Ryan's J616s with a native tether boot of integration/aurora + j616s/usb-20261023 + these two commits + local tether DT commits:

  • before: -62 at probe, CPU clusters capped by the fail-safe limiter
  • endpoint 7 only: PMP starts, firmware crash at the same PC every boot
  • both: PMP running for minutes, no "PMP not running" warning, cpufreq at 4512/2592 MHz, m4test pmp pass

The clean branch was build-checked (J616s DTB) on top of ac6b017; the Rust change was built and booted in the combined tree.

🤖 Generated with Claude Code

The M4 Pro (T6040, J616s) PMP firmware advertises system endpoint 7 and
asks for a 0x2000 byte buffer on it during its RTKit boot. Unless the
endpoint is started and the buffer is given, the firmware never
acknowledges the IOP power state and the probe fails with
"IOP power acknowledgment failed: -62".

The endpoint 7 handling RTKit already has for the J713 PMP (CoreAnalytics:
type 0 buffer request, type 1 reply with a 4K or 1M unit) is the same
exchange, so only the gate changes: the T6041 configuration starts
endpoint 7 on every board, while T8132 keeps the retained-J713 check.

Verified on a J616s: before, -62 after the EP01/EP04 buffer replies; with
endpoint 7 served, "PMP firmware and endpoint ready" and the firmware
logs "io.cpp:54: PMP started".

Niklas Sheth found the same endpoint 7 dependency for the M4 Pro PMP in
GravityLinux (877c574, rtkit endpoint-7 hunks); this uses our existing
CoreAnalytics path instead of carrying that code.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
…boot

The pmp-gfx report entry tells the PMP that the GPU (soc-device 13) is
on. It was marked always-on, so the PMP report driver claimed it at
boot although this tree has no GPU node and nothing powers the GPU.

On a J616s the PMP firmware then crashes 20 to 70 ms after it logs
"io.cpp:54: PMP started": an SError (ESR 0xbe000000) in the firmware,
at the same PC on every boot. The PMP stays dead for the rest of the
boot and the CPU clusters keep their fail-safe frequency caps.

With the entry left unclaimed, the PMP keeps running and the CPUs get
their full frequency ladder. The CPU cluster entries stay always-on.
Label the entry so that the GPU node can take it as a power domain;
the GPU driver then claims it only while it has the GPU powered.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
@RyanTheTide
RyanTheTide merged commit 311471f into integration/aurora Oct 23, 2026
@RyanTheTide
RyanTheTide deleted the j616s/pmp-ep7-20261024 branch October 23, 2026 14:20
RyanTheTide added a commit that referenced this pull request Oct 26, 2026
…r binds

The T6040 PMC description still excludes PMP agent 0 from the earlier
bring-up, when the firmware did not run and iBoot's top-state floor would
have stayed in force. PMP startup is now supported and the GPU's report
entry follows its power lifetime, but the PMC cannot honour that demand
while the agent remains disabled.

Use the existing apple,pmp supplier dependency before enabling static
PMP, CLPC and AP voters, as in the Neo voter integration. The T6040 match
data continues to restrict them to the established DCS/SOC rail mask;
no display rail, voltage, power ceiling or new control is introduced.

Confirm live PMP votes, idle release and sustained GPU/CPU thermal
behaviour on J616s before qualifying this candidate.

Link: #219
Link: #402
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
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