Repository navigation
iommu/apple-dart, soc: apple: rtkit-helper: take a live MTP handoff by its properties, not by board - #2525
Conversation
|
Claude Opus 5.5 on @satchlj's behalf. Hardware result on MacBook Air M2 (J413, T8112), macOS 27.2 (26B123) stub: pass. The change is now part of phellos's default. Tested in phellos's upstream-first build, and it is now the default (one-shot
🤖 Generated with Claude Code |
|
Claude Opus 5.5 on @satchlj's behalf: hardware run.
Build: phellos (MacBook Air M2, J413, macOS 27.2 / 26B123 stub), default rebuilt 2026-11-20 = linux |
|
J615 row (15-inch MacBook Air M3, T8122), 27.2 stub. Setup: Stage 1 aura tip-dev; one-shot Stage 2 = aura 1.0.0b13.1 + the J615 DTB with
The DART kept the bypass stream (no refusal) on the J615's T8122 DART, so the property path covers the J615 with no board check. With the one-stage trackpad power command the 27.2 trackpad answered Not tested yet: s2idle with the adopted session on the J615; key presses from a person (all interfaces report ready, input devices registered). |
DjDeveloperr
left a comment
There was a problem hiding this comment.
The code review is clean. I'm requesting changes only for the DCO. None of the four commits (2ae85bd, 64ea0f8, 6230f01, 94ed951) has a Signed-off-by: line, and we don't merge without one. Running git rebase --signoff integration/aurora and pushing the branch fixes it. I'll merge as soon as CI is green on the new head.
What I checked:
- Property contract with u-boot#67 and #2550:
apple,rtkit-keep-runningis a boolean on the MTP helper node (&mtp), and only the boot stage reads it. Linux still reads only what U-Boot publishes:apple,rtkit-handoff = "mtp-live-v1", the buffer inventory, andapple,bypass-handoff-streamson the DART. The binding text says exactly that. - Boards without the property keep today's behaviour:
- With no
apple,rtkit-handoffthere is no adoption, so the rtkit-helper change does nothing. - A DART with no
apple,bypass-handoff-streams, or a zero one, is left alone. - The DART still refuses a stream other than 1, or one whose TCR doesn't read back as bypass (
apple-dart.c:5841-5843). That hardware check is the right replacement for the address gate.
- With no
- s2idle for the other adopted sessions (J713, J614s, T8132, T8140): this is safer than before. Their ASC suppliers stay awake (
rtkit-helper.c:555), and a lost RUN is reported instead of ignored (:569). Firmware-driven sleep still returns before any of this (:541). Post-merge rows: one s2idle round trip with an adopted session on a J713 and on a J614s. apple-dt-check.sh: the variant mapping does what it says, for one level of include.
CI on 94ed951: Host tests, Device tree checks and SEP source checks are all green. Hardware: satchlj's J413 row and Ryan's J615 row, both on this head.
Merge order after the re-sign: this PR first, then u-boot#67, then #2550.
…y its properties, not by board A boot stage that leaves the MTP running hands it over with apple,rtkit-handoff on the MTP and apple,bypass-handoff-streams on its DART. Two checks still named the J613: the DART probe accepted the bypass stream only on the J613's T8122 DART at 0x2fa808000, and the helper kept the adopted session's ASC awake over s2idle only on the J613. The 27.2 MTP firmware on the MacBook Air M2 (J413) cannot be restarted either, and U-Boot hands it over the same way through the T8112 DART at 0x24e808000. - apple-dart: inherit the stream when the DART supports bypass, the stream is 1, and its TCR reads back as bypass. The register is the hardware's own record of the handoff, so it replaces the board and address match. - rtkit-helper: keep an adopted session's ASC awake over s2idle on every board. A session is adopted only through apple,rtkit-handoff, which says it cannot be restarted. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Satya Benson <satya@benson.earth>
Add apple,rtkit-keep-running to the rtk-helper binding: the helper's firmware cannot be restarted once quiesced, so a boot stage that starts it hands its first epoch to the OS running instead of stopping it. U-Boot used to pick these by board (J613) and by SoC plus OS firmware version (T8112 on 27.x); it now reads this property. - t8122-j613: set it, as U-Boot's J613 check did. - t8112-j413-fw27 (new): J413 with macOS 27 system firmware. It sets the property and the trackpad's two-stage power command (apple,power-method = <2>), which U-Boot used to patch in, following t8122-j613-25g83. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Satya Benson <satya@benson.earth>
The helper no longer checks the board, so the harness's of_machine_is_compatible() stub was unused and failed -Werror. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Satya Benson <satya@benson.earth>
…its base board A firmware-profile variant such as t8122-j613-25g83 or t8112-j413-fw27 includes its board's .dts, so a new variant repeats every existing warning of that board under a new DTB name and fails the check. Report a variant's warnings under the base board's name instead. A warning only the variant has still shows up as new. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Satya Benson <satya@benson.earth>
94ed951 to
45a78bf
Compare
|
Claude Opus 5.5 on @satchlj's behalf: thanks, Dj. All four commits now carry @RyanTheTide: #2550 is stacked on this branch, so it will need a rebase onto 45a78bf ( |
DjDeveloperr
left a comment
There was a problem hiding this comment.
Thanks for the sign-offs. All 4 commits now carry Signed-off-by, and the tree is byte-identical to the head I reviewed (c3cde4cb), so I'm approving.
One thing still blocks the merge: dt-checks is red on 45a78bf. This isn't your change. The "DART power domains, base vs head" step (added 11-19 in 6539f98) reports t8112-j413-fw27 /soc/iommu@24e808000 - apple,t8112-dart okay: no power-domains (new). That node comes from t8112-j413.dts through the include, and the base J413 DTB already lacks the domain. The checker counts it as new only because the fw27 DTB itself is new. I've asked for the checker to compare an included board's DTB against its base, or for that J413 DART to get its domain. Either fix turns this green with no change to this PR. I'll merge as soon as dt-checks passes on this head, and u-boot#67 right after.
|
On the red dt-checks on 45a78bf (run 44735951410): it's the DART power-domain check,
So this only needs a fresh dt-checks run. A re-run of the old run reuses the old merge commit, so it needs a new event, for example a close and reopen. Assisted-by: LLM (Claude:Opus 5.5) |
|
Claude Opus 5.5 on @satchlj's behalf: post-merge row.
Boot: one-shot under the SoC watchdog, trial boot
Not checked (needs someone at the machine): actual key presses and trackpad touches in Linux, and the keyboard at the GRUB menu on this U-Boot. Wake by lid open or key press was not checked either; the wake here was by RTC. 🤖 Generated with Claude Code |
Claude Opus 5.5 on @satchlj's behalf.
Take a live MTP handoff by its device-tree properties and the DART's own state, not by board.
Why: a boot stage that keeps the MTP running hands it over with
apple,rtkit-handoffon the MTP andapple,bypass-handoff-streamson its DART. Two checks still matched the J613 by name:0x2fa808000;The 27.2 MTP firmware on the MacBook Air M2 (J413) cannot be restarted either. U-Boot (aurora-silicon/u-boot, T8112 27.x live handoff PR) hands it over the same way through the T8112 DART at
0x24e808000.Change:
apple-dart: inherit the stream when the DART supports bypass, the stream is 1, andTCR(stream)reads back as bypass. That register is the hardware's own record of the handoff.rtkit-helper: keep an adopted session's ASC awake over s2idle on every board. A session is adopted only throughapple,rtkit-handoff, which means it cannot be restarted.Behaviour change elsewhere: other boards whose helper adopts a session (J614s, T8132 live MTP) now also keep the ASC awake over s2idle. Not tested on those boards.
Second commit (
64ea0f87), for aurora-silicon/u-boot#67: a bootloader-facing property,apple,rtkit-keep-running, on the rtk-helper binding. It means the helper's firmware cannot be restarted once quiesced, so a boot stage hands its first epoch over running. Set int8122-j613.dts(replacing U-Boot's J613 board check) and in the newt8112-j413-fw27.dts, which is J413 with macOS 27 firmware. That file also sets the trackpad'sapple,power-method = <2>, which U-Boot used to patch in. Linux does not read the new property. Tested on J413 27.2 with that DTB in a one-shot Stage 2 (see u-boot#67); not built throughmake dtbs_check.CI fixes:
6230f01ddrops the now-unused board stub fromj613-mtp-s2idle-tests. That stub had failed-Werrorsince the first commit.94ed951bmakesapple-dt-check.shreport a firmware-profile variant's warnings (a.dtsthat includes another board's.dts) under its base board's name. Without it,t8112-j413-fw27.dtbre-reported J413's 30 existing warnings as new. A warning only the variant has still counts.Testing
🤖 Generated with Claude Code