Repository navigation
pmdomain: apple: wait for the T604x ANE_SYS parent on power-on - #1139
RyanTheTide wants to merge 1 commit into
Conversation
On the J616s (T6040) ANE_SYS sometimes comes back from s2idle with the register at 0x0b4f: target 0xf, actual 0x4 (clock-gated) and bit 11 set, so its upstream (the SoC fabric) is not available yet. That is the condition T6000 GFX already shows on noirq resume, but T6000 GFX is the only domain that gets the separate bounded parent wait. ANE_SYS gets the plain 100 us budget, fails with PS ane_sys: Failed to reach power state 0xf (requested 0xf, now: 0xb4f) and genpd ignores the error on that path, so the ANE firmware is booted on a sys domain that is still clock-gated. In a J616s run of 80 s2idle wakes this line came right before 3 of the 10 H16 firmware startup stalls that the ANE driver then had to restart. Give ANE_SYS the same treatment as T6000 GFX: wait up to 10 ms for bit 11 to clear, then the usual 100 us for the actual state. A parent that never comes back still fails and logs. Match ANE_SYS by its label as well as its offset: 0x3c0 is also atc1_cio in another T604x PMGR block. The existing KUnit cases cover the wait itself. Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Assisted-by: LLM
|
J616s run 11-08 06:31-06:42 (lane ANEX): test kernel 7.3.0-aurora-fleet23anex2 (fleet23 + this commit), 30 s2idle cycles with an ANE program loaded: 30 resumes ok, 0 |
|
J616s A/B on 2026-11-09, 15 RTC s2idle wakes per arm (kit v13c suspend path):
The 🤖 Generated with Claude Code |
|
The Neo (T8140) shows the same signature ( 🤖 Generated with Claude Code |
What
On the J616s (T6040, M4 Pro) the ANE_SYS power domain sometimes comes back from s2idle with its PMGR register at
0x0b4f: target0xf, actual0x4(clock-gated) and bit 11 set, which means its upstream (the SoC fabric) is not available yet. Every domain except T6000 GFX gets only a 100 us budget, so this logsand genpd ignores the error on the resume path. The ANE firmware is then started on a sys domain that is still clock-gated.
T6000 GFX shows the same register pattern on noirq resume and already gets a separate bounded wait for bit 11 (e8643ee). This change gives T604x ANE_SYS the same wait: up to 10 ms for bit 11 to clear, then the usual 100 us for the actual state. A parent that never comes back still fails and logs. ANE_SYS is matched by compatible, offset and label, because
0x3c0is alsoatc1_cioin another T604x PMGR block. No other domain changes.One commit,
drivers/pmdomain/apple/pmgr-pwrstate.c.Why it matters
Tests
pmgr-pwrstate(arm64,.kunitconfig.pmgr-pwrstate): 10/10.ane_sys: Failed to reach, H16 startup stalls and restarts against the fleet23 numbers. Draft until then.🤖 Generated with Claude Code