Skip to content

arm64: dts: apple: t602x: describe the encoder DMA apertures as one block - #2373

Open
ludagoo wants to merge 1 commit into
aurora-silicon:mainfrom
ludagoo:ave/t602x-dma
Open

ludagoo wants to merge 1 commit into
aurora-silicon:mainfrom
ludagoo:ave/t602x-dma

Conversation

@ludagoo

@ludagoo ludagoo commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Base: integration/aurora 0abc2f385e54. One commit (8b313f4d5640 on branch ave/t602x-dma, ludagoo/linux), independent of the driver PRs.

The t602x trees describe two ranges next to each video encoder, *020000 and *044000, as DARTs. On the M2 Max (J475c) apple-dart rejects the *044000 nodes: the stream count it reads there is 385 at 40d044000 and 350 at 507044000, above its limit of 256. The *020000 nodes probe as DARTs. T600x describes the same two ranges as one apple,t6000-ave-dma block, with the encoder's DARTs at *030000 and *040000. (T603x and T8122 use a third form: *020000 as apple,dart-smmu and *044000 as apple,dapf, both disabled. T8112 has no node for either range.)

This does the same as T600x on t6020 (ave0), t6021 (ave0, ave1) and t6022 (ave0 to ave3, both dies): one dma-controller node with the two ranges, the interrupt and the power domain the old nodes had, and the encoders' iommus keep only the two real DARTs. Every node stays disabled. The binding already allows this compatible with exactly these two ranges; a maintainer may prefer an apple,t6020-ave-dma compatible in front, which the binding does not have today.

Tested

  • Mac Studio (M2 Max, J475c), kernel 7.3.0 with the T6021 encoder PRs: both encoders ran H.264 and HEVC with only the *030000 and *040000 DARTs attached, several hundred sessions, no DART faults. The blocks stay disabled there. With them enabled on that board, apple-ave-dma binds and holds the VENC sys domains on (see the J475c PR); this PR enables nothing. media/dts: apple: enable the T6000 AVE DMA fault reporter with runtime PM #1861 (draft) describes the same effect on T6000 ("once the device bound genpd counted it as active and kept the encoder's power domain up for good") and adds runtime PM to apple-ave-dma; with that, a board could enable these blocks.
  • scripts/dtc/apple-dt-check.sh 0abc2f385e54 <this commit> (dtschema 2026.9): all 137 Apple device trees build, 1404 CHECK_DTBS warning lines at base and head, none new and none removed. Re-run for this version on the eight t602x trees only (all 8 build with CHECK_DTBS, 481 schema findings at base and here, none new and none removed); the device tree files are byte-identical to the ones the full check ran on.
  • checkpatch.pl --strict: clean.

t6020 and t6022 were not booted.

Overlap: #2252 (t602x scaler, draft) and #1861 touch the same files and merge cleanly with this commit.

Not done yet

  • No board enables these blocks. Nothing binds apple-ave-dma on t602x unless a board does.

…lock

The t602x trees describe the ranges at *020000 and *044000 next to
each encoder as two more DARTs. On the M2 Max (J475c) apple-dart
rejects the *044000 nodes: the stream count it reads from them is 385
at 40d044000 and 350 at 507044000, above its 256 limit. The *020000
nodes probe as DARTs.

T600x describes the same two ranges as one apple,t6000-ave-dma block,
with the DARTs at *030000 and *040000. Do the same on t6020 (ave0),
t6021 (ave0, ave1) and t6022 (ave0 to ave3), and drop the two ranges
from the encoders' iommus. The binding allows exactly these two
ranges. A maintainer may prefer an apple,t6020-ave-dma compatible in
front; the binding has none today.

The encoders on J475c ran with only the *030000 and *040000 DARTs and
showed no DART faults. t6020 and t6022 were not booted.

Assisted-by: Grok 4.7
Assisted-by: Claude Opus 5.5
Signed-off-by: Lucas Goossen <[email protected]>
@RyanTheTide

Copy link
Copy Markdown
Contributor

Thanks, this is a clean correction. The two ranges that apple-dart rejects become one apple,t6000-ave-dma block, as on T600x, on all three t602x SoCs, with nothing enabled.

We built all eight t602x device trees at 0abc2f385e54 and at this head. All of them build, and the dtc warnings are identical before and after. The code looks good to us. The only open question is the binding: whether to put an apple,t6020-ave-dma compatible in front of apple,t6000-ave-dma. That one is for the maintainer review, and no hardware row is needed for it.

Once this is merged, #2376 can drop its copy of the commit.

@ludagoo

ludagoo commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor Author

Thanks for the review. The updates are pushed; replies to each of your comments below.

Re: binding: apple,t6020-ave-dma in front?

Thanks for building all eight. No change from me. The blocks are the same layout as T600x's, which is why they use apple,t6000-ave-dma; if the maintainer wants an apple,t6020-ave-dma in front, I will add it together with the binding update.

@RyanTheTide RyanTheTide left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review at 8b313f4. This binding change removes per-window properties from existing AVE nodes and changes their compatible hierarchy. Please state the DT/driver update order and prove that the compatible fallback still sets up DMA with last release's bootloader and driver, where mixed revisions are supported. Include one direct 13.5 T8112 stream and a 27.2 T8112 control so a DT-only regression cannot be hidden by the newer driver stack.

@DjDeveloperr DjDeveloperr left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pre-PR checklist (§1–§6) review at 8b313f4d5640a499dc060b5c2b1ead2f1de43f4e (dt-checks: SUCCESS, host-tests: SUCCESS; not superseded on integration/aurora).

Technical verification

The DTS changes across t6020-peripherals.dtsi, t6021-peripherals.dtsi, and t6022-peripherals.dtsi are technically sound and match Documentation/devicetree/bindings/iommu/apple,ave-dma.yaml and t6000-peripherals.dtsi:

  • Each encoder's *020000 and *044000 regions are merged into a single dma-controller node (compatible = "apple,t6000-ave-dma", "apple,ave-dma") preserving the exact register ranges, AIC IRQ numbers/die IDs, and ps_venc*_sys* power domains, with status = "disabled".
  • <&m2_dart_ave*_2 0> and <&m2_dart_ave*_3 0> are removed from m2_ave*'s iommus; no other board DTS in integration/aurora references those labels.
  • Note: the earlier review comment asking for T8112 13.5/27.2 streams does not apply to this t602x AVE DTS change.

Blockers

  1. §4 Attribution (hard blocker) — AI trailers present in git commit message (8b313f4d5640):
    • The commit message contains:
    • Per §4 of the pre-PR checklist, git commits must carry human identity and a human Signed-off-by: only, with zero AI/Assisted-by: trailers in commit messages.

Checklist (§1–§6)

  • §1 No model gating: Pass (standard DT hardware description; no model gates).
  • §2 Production-ready: Pass (no cmdline params or hacks; nodes remain disabled).
  • §3 Safety: Pass (removes invalid DART nodes that fail apple-dart stream-count validation).
  • §4 Clean-room and attribution: Fail — AI Assisted-by: trailers in commit 8b313f4d5640 and missing plain Assisted-by: line in the PR body (see Blocker #1).
  • §5 Evidence: Partial (non-blocking given all modified nodes stay disabled, though worth refreshing when re-pushing): apple-dt-check.sh and checkpatch --strict passed and J475c (T6021) ran encoders with the two real DARTs, but t6020/t6022 were not booted and full §5 boot regression counts (0 SELinux denials, 0 failed units, 0 new kernel errors) on a standalone/live-head boot are not yet recorded.
  • §6 Naming: Pass.

@github-actions github-actions Bot added area:platform Area from CODEOWNERS (bot) changes-requested A reviewer requested changes (bot) needs-hw-row No hardware row at the PR head (bot) needs-review No approving review from Core or Omarchy Mac yet (bot) needs-template PR body lacks Tested or Risk (bot) labels Nov 24, 2026

@DjDeveloperr DjDeveloperr left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: FINISH, then merge at 8b313f4d5640

Blockers:

  1. Commit 8b313f4d carries two Assisted-by: trailers. We keep commits to the human author and sign-off. The snippet below drops them; then force-push your branch.
git fetch origin
FILTER_BRANCH_SQUELCH_WARNING=1 git filter-branch -f --msg-filter "grep -viE '^(assisted-by:|(co-authored-by|signed-off-by):.*(claude|copilot|codex|gemini|cursor|openai|anthropic)|[^a-z]*generated with)' | git stripspace" origin/main..HEAD
git push --force-with-lease
  1. Missing row: one M2 Pro or Max (T602x) boot at this head with the encoder probing and an encode running.

Checked: thank you for the T602x encoder work. No Apple material, DT only: the DMA apertures are described as one block.

@DjDeveloperr
DjDeveloperr dismissed their stale review November 25, 2026 00:31

Superseded by the review at 8b313f4

@github-actions

github-actions Bot commented Nov 25, 2026 •

Copy link
Copy Markdown

Merge readiness at 8b313f4d: not ready yet

Check Detail
CI at head ok 3 checks passed
Review no needs one approving review from Core or Omarchy Mac (not the author)
Requested changes no requested by DjDeveloperr
Hardware row at head no no line with the head SHA 8b313f4d, a Mac and a result in the PR body or a comment
Conflicts ok none
PR text adopt when you next edit add a 'Risk:' line (door and Macs) (guide)

Areas: area:platform

Updated by pr-readiness on pushes, edits, reviews and comments, and on a schedule. Rules: merge policy · labels.

@DjDeveloperr

Copy link
Copy Markdown
Contributor

For the whole series (#2373 to #2376), here's what's left, so it's in one place:

Then one M2 Max encode run at each head.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:platform Area from CODEOWNERS (bot) changes-requested A reviewer requested changes (bot) needs-hw-row No hardware row at the PR head (bot) needs-review No approving review from Core or Omarchy Mac yet (bot) needs-template PR body lacks Tested or Risk (bot)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants