Repository navigation
Conversation
f14a6b8 to
a0994c9
Compare
|
J873g results, on #2178's stack (which carries #2139's AVD with this provider) plus a TEST-only commit that logged every transition.
I'm taking this out of draft. |
|
No blockers. I checked drivers/pmdomain/apple/pmgr-psd.c and the binding. The ack-then-state poll is atomic and bounded (10 ms against the measured 240-500 us). The early state read before writing the target clears any stale acknowledge. An always-on domain is powered before pm_genpd_init() so its initial state is consistent. The provider and genpd are torn down in the right order on error and unbind. GENPD_FLAG_IRQ_SAFE matches the DART consumers.
HW row: J873g on the default command line: a USB4 device hot-plugged on a rear port (CIO services go from cold to on, the device enumerates, then back to cold within a few seconds of unplug), the USB controllers on services 175/176 working with Assisted-by: LLM (Claude:Opus 5.5) |
On T8152 the video decoder, the USB4 routers and their PHYs and the USB controllers are powered through PMGR2 PSD services instead of PMGR power-state registers. Each service has a 0x100-byte block with a target state, an acknowledge bit and the current state. Describe one service per node as a power domain, with an optional apple,always-on for a service whose consumers cannot restore what another agent set up in its blocks yet. Signed-off-by: Thomas Glanzmann <thomas@glanzmann.de>
a0994c9 to
9dbf0f0
Compare
|
Assisted-by: LLM (Claude:Opus 5.5) |
Provide each T8152 PMGR2 PSD service as a power domain. Power-on requests state 0 and power-off the cold state 6. The driver waits for the acknowledge before it reads the state, because reading the state consumes the acknowledge. A service marked apple,always-on is powered at probe and kept on. Otherwise the domain starts in the state the hardware reports, so genpd powers off a service that nothing uses. The consumers include IRQ-safe devices, the DARTs, so the domains are IRQ-safe and a transition is polled atomically, as the PMGR power states are. On the J873g the AVD service (50) reaches state 0 in 390-500 us and the cold state in about 240 us; the timeout is 10 ms. The AVD and the USB4 routers' CIO services, which so far each had their own variant of this, and the USB controllers (services 175 and 176) use it. It has its own Kconfig symbol, APPLE_PMGR_PSD, on by default with ARCH_APPLE and built in by the shared asahi.config profile. Signed-off-by: Thomas Glanzmann <thomas@glanzmann.de>
9dbf0f0 to
c02baf4
Compare
|
@RyanTheTide fixed in The J873g row (rear-port USB4 hotplug, services 175/176 with Assisted-by: LLM (Claude:Opus 5.5) |
|
J873g rows. The kernel was the #2178 stack (
Kernel AVD, service 50 (not always-on).
CIO services, rear USB4 ports.
Services 175/176 (USB controllers' DARTs): not done, and the description was wrong about them.
Regression line.
The M6 is back on its default kernel. Assisted-by: LLM (Claude:Opus 5.5) |
On T8152 several blocks are powered through PMGR2 PSD services rather than PMGR power-state registers: the video decoder (service 50), the USB4 routers and their PHYs (the CIO services), and, by the ADT, the USB controllers (175, 176). So far #2139 and #2178 each carried their own variant of a PSD power domain: one compatible per user, AVD always on, CIO with power-off. As agreed on #1797, this replaces them with one generic per-service provider.
apple,t8152-psd): one node per service, its 0x100-byte block asreg,#power-domain-cells = <0>, an optionallabel, and an optionalapple,always-onfor a service whose consumers can't yet restore what another agent set up in its blocks.apple,always-onservice is powered at probe and kept on. Any other starts in the state the hardware reports, so genpd powers off a service nobody uses.Users:
apple,always-on, so the decoder and its DART power off when idle.base + 0x100 * servicelike services 50-89: a test node there aborts on the first access (see the rows in the comments), so their blocks still have to be found. They will needapple,always-onuntil the T8152 ATC PHY support (J873g: USB3 on the front ports (T8152 in the ATC PHY driver, M6 Mac mini) #1799'satc.crework) can restore the USB2 PHY the loader set up.Checks:
pmgr-psd.obuilds with no W=1 warnings,dt_binding_checkpasses for the new schema, checkpatch is clean. Hardware results for the AVD power-off and the CIO services are in the comments.Assisted-by: LLM (Claude:Opus 5.5)