Skip to content

arm64: dts: apple: t6050-j775d: Give the Mac Studio (M5 Ultra) a working GPU, and its M and P core capacities (754/1024) to the scheduler - #1973

Open
funkzy wants to merge 3 commits into
aurora-silicon:integration/aurorafrom
funkzy:m5-ultra
Open

funkzy wants to merge 3 commits into
aurora-silicon:integration/aurorafrom
funkzy:m5-ultra

Conversation

@funkzy

@funkzy funkzy commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

What is missing

  • No GPU. The GPU driver has the M5 Ultra's configuration, but the J775D device tree leaves the GPU and both
    GPU coprocessor nodes disabled, with no mailboxes and no reservations. The Mac Studio boots without a render
    node and its desktop session cannot start.
  • No CPU clusters. t6050-ultra.dtsi has no cpu-map, so Linux sees thirty CPUs in one package with no
    clusters. parse_dt_topology() reads capacity-dmips-mhz only while it walks cpu-map, so the M and P
    capacities from arm64: dts: apple: t6050: Give the M and P cores their capacities #1399 never reach the scheduler: every CPU reports cpu_capacity 1024, and cluster_cpus_list
    reads thirty clusters of one. The cpu-map commit for the one-die parts (68c10dd) says "The two-die
    description keeps its flat layout for now"; this fills it in.

What this adds

Three commits, J775D only:

  1. The CPU clusters (t6050-ultra.dtsi). A cpu-map in the shape of the one-die description's: six clusters
    of five, MPIDR Aff1 0, 1, 2 for die 0's M0, M1 and P and 0x10, 0x11, 0x12 for die 1's, as the ADT's cluster-id
    and die-id give them, listed flat as t6002.dtsi and t6022.dtsi list theirs. The caches are dj's: arm64: dts: apple: t6050: Describe the CPU caches #2654
    (1bd5f40, "Describe the CPU caches") gives each cluster its L2 and points each CPU's next-level-cache at
    it, and each cluster here is the set of CPUs that share one of those L2s. This commit adds the cpu-map only and
    leaves his L2 nodes, labels and CPU macros as they are.
  2. Binding: apple,agx-g17d with the apple,agx-g17s fallback, added to the entry ewb's 4c7fdf1 made for
    the M5 Max's apple,agx-g17c: his entry becomes a list of two names, the form the G13 and G14 parts use. The
    driver matches the family name and tells the parts apart by the GPU's ID registers; the name is there so the
    device tree says which part it is. The Ultra's GPU node has the M5 Pro's hand-off shape (one sgx range, two
    firmware mailboxes, six reserved regions, no operating-point tables), so the M5 Pro hand-off entry, which since
    sithglan's 8f418a4 applies to a node whose only compatible is apple,agx-g17s, applies to a node with
    apple,agx-g17d as well.
  3. t6050-j775d-gpu.dtsi, in the shape of dj's t6050-j714s-gpu-panel.dtsi (32a31cf): the gpu alias,
    the six reservations the boot loader fills, the two firmware mailboxes in place of the inventory's coprocessor
    nodes, GPX and AFR held on, and the GPU node's handoff properties. The J775D ADT gives the same addresses and
    interrupts as J714s's: both firmware roles and their mailboxes are on die 0. It differs from the J714s file in
    two things: no panel or display part (the Studio's display chain is described already), and the part's name.
    Everything stays disabled in the source; the boot loader enables the nodes after checking the ADT and the GPU
    firmware build.

The GPU part now reads much the same in four board files (J714s, J716c, K114c and this one). It could be one shared
file that they include; this leaves the others as they are. dj, say if you would rather have that here.

Who runs the changed code

  • Only t6050-j775d.dts includes t6050-ultra.dtsi and the new file. The ten other T6050 board device trees
    (J714c, J714s, J716c, J716s, J775c, J873s, K114c, K114s, K116c, K116s) and T8142's J704, J813 and J815 are
    byte-identical with and without the three commits.
  • The binding allows one more name and applies the M5 Pro hand-off entry to it. A node whose only compatible is
    apple,agx-g17s and an apple,agx-g17c node take the entries they took before; no existing device tree uses the
    new name.
  • No driver change. The one-die description (t6050-max.dtsi) has its cpu-map already and is left as it is.

Depends on

  • Nothing to build or boot: a loader that does not know the Ultra's GPU firmware build leaves the GPU off, as
    today, and the cluster commit needs nothing.
  • For the GPU to come up: the loader pull request that admits the Ultra's build in the T6050 GPU handoff
    (aura, "kboot: T6050: hand the M5 Ultra's GPU to Linux instead of refusing its firmware build").

Overlaps

dj's draft #2102 (J775c support) touches the same binding and t6050-j775d.dts; it merges with this branch without
a conflict.

Validation

Rebased onto integration/aurora at a84637d (the merge of dj's #2654). #2654 conflicted with the cluster commit
in t6050-ultra.dtsi: the file is now a84637d's as dj wrote it, plus this branch's cpu-map, and this branch's
own L2 nodes and next-level-cache overrides are gone (git range-diff: the cluster commit changed, the other two
unchanged). On a84637d:

  • The head merges cleanly with integration's tip.
  • dtschema 2026.9: dt_binding_check DT_SCHEMA_FILES=gpu/apple,agx.yaml is clean on the head and with this pull
    request. dtbs_check on all eleven T6050 boards reports the same 17 distinct lines with and without it (all
    already on the head), none new and none on J775D; the J775D GPU node validates against the binding with its
    status set to "okay". t6050-j775d.dtb is the only DTB that changes; the ten other T6050 DTBs are byte-identical.
  • scripts/checkpatch.pl --strict: 0 errors, and on commit 3 only the generic new-file note.

Earlier, rebased onto integration/aurora at 59b02d5 (from 1f38ff8, and that from fc05050) without a conflict;
the three diffs are unchanged but for the binding's context (the new apple,agx-t8142 entry). On 59b02d5:

  • dtschema 2026.9: dt_binding_check DT_SCHEMA_FILES=gpu/apple,agx.yaml is clean on the head and with this pull
    request. dtbs_check on all eleven T6050 boards reports the same 18 distinct lines with and without it (all
    already on the head), none new and none on J775D, whose GPU node also validates against the binding with its
    status set to "okay".

Earlier, on integration/aurora at 7c71d6d (the merge of #1901):

  • Each commit builds with integration's own configuration, in order, with 0 errors and no dtc warning; the full
    build has the same warnings with and without the series (this pull request and that day's other M5 Ultra
    commits, among them a compute-timestamp change that is no longer in this set).
  • scripts/checkpatch.pl --strict: clean on the three, but for the generic new-file note on commit 3 (MAINTAINERS
    already covers arch/arm64/boot/dts/apple/).
  • tools/asahi/run-host-tests.py on a Linux host, on integration/aurora at fc05050: 321 of 321 runs pass, on
    the head and on the head plus this pull request and the other linux pull request below; no run differs.
  • dtschema 2026.9: dt_binding_check DT_SCHEMA_FILES=gpu/apple,agx.yaml is clean on the head and with this pull
    request. dtbs_check on all eleven T6050 boards reports the same 55 lines with and without it (all already on
    the head: the display mux lists of J716c and J714s, J716c's operating points, J714s's DART reg-names, the PCIe
    port0 nodes), none on J775D. The J775D GPU node also validates against the binding with its status set to
    "okay", as the boot loader leaves it.

Hardware (Mac Studio, M5 Ultra, J775D)

integration/aurora at a84637d, with and without this pull request, one boot each: 27.0 stub, default command
line, read-only test root. Both kernels also carry one local fix that is not part of this pull request:
integration oopses at boot on the J775D in apple_drm_bind, because an HDMI processor without HDMI audio gets a
CEC-only AV endpoint and av_service_connect() dereferences its NULL audio owner, so there is no /dev/dri and the
GPU module never loads. The fix keeps such an endpoint out of the audio service calls and can go up on its own.

a84637d a84637d + this pull request
Render node absent (card0 only; the desktop does not start) renderD128 present
Render CTS subset (628 cases) not run (no render node) 571 Pass, 57 NotSupported
cpu_capacity 1024 on all 30 CPUs 754 on 20, 1024 on 10
cluster_cpus_list 30 groups of one six groups of five (0-4, 5-9, 10-14, 15-19, 20-24, 25-29)
L2 (cache/index2, from #2654) 8 MiB shared by 0-4, 5-9, 15-19 and 20-24; 16 MiB shared by 10-14 and 25-29 the same
Failed units iwd.service, systemd-networkd-persistent-storage.service the same two
Kernel error lines 3 the same 3, plus Cannot enable BOOST and store_boost: Cannot enable BOOST!, each twice

Both failed units fail on the read-only test root in every boot. The two BOOST lines come from power-profiles-daemon
writing cpufreq/boost when it starts with the desktop, which the base boot doesn't reach; starting it by hand on
the base boot logs the same two lines, so there are 0 new kernel errors. ALARM has no SELinux, so there is no AVC
count. No GPU recovery, fault or timeout in either kernel log.

Earlier, integration/aurora at 7c71d6d with this pull request:

  • Through aura main plus the loader pull request above, the kernel uploaded over USB (that boot's kernel also
    carried a compute-timestamp change that is no longer in this set): the loader reports "T6050 G17D 26A428
    enabled", the driver probes 2300000000.gpu with both firmware roles' initdata acknowledged, and a render node
    appears, where integration's head has none. The GPU's compute and chained-submit checks, 46 concurrent clients and
    a 628-case render CTS subset (571 pass, 57 not supported) pass, with no GPU recovery, fault or timeout in the
    kernel log. The same in each of five further boots through a loader that also hands over the display, four of
    them without that change.
  • Rebased onto integration/aurora at fc05050 (the merge of drm/asahi: g17: let a refused render take back idle render pools #1948), with only the other linux pull request
    below, through aura main plus the pack's aura pull requests, one boot: the driver probes the GPU with both
    firmware roles' initdata acknowledged and a render node appears; the compute and chained-submit checks, 46
    concurrent clients and the 628-case subset (571 pass, 57 not supported, two runs) pass, with no GPU recovery,
    fault or timeout in the kernel log; all 30 CPUs are up; the desktop runs on the GPU on HDMI and DisplayPort.
  • On integration/aurora at 1f38ff8 with this pull request and sithglan's 27.2 dfb_ready_query commit (merged
    since, in drm/apple: iomfb: firmware 27.2: the AP link's release is A550 #2063), through aura main at 03d120dc plus the pack's aura pull requests:

Not tested

  • Any board other than J775D (none includes the changed files).
  • Suspend, and a long soak.

Part of the M5 Ultra platform pack

Each pull request below stands on its own; together they bring the Mac Studio (M5 Ultra, J775D) up from public
branches to the desktop.

Assisted-by: LLM (Claude:Opus 5.5)

@RyanTheTide

Copy link
Copy Markdown
Contributor

No blockers.

Checked: the cpu-map lists the 30 CPU labels declared in arch/arm64/boot/dts/apple/t6050-ultra.dtsi:30-59 in six clusters of five that match the MPIDR Aff1 groups (and the cpufreq domain each CPU points at), every CPU's next-level-cache points at its own cluster's L2 (t6050-ultra.dtsi:235-353), and the M/P L2 sizes match the cluster types. The new t6050-j775d-gpu.dtsi keeps the mailboxes, reservations and GPU node disabled for the loader to enable, so a loader without the handoff leaves the GPU off as before. The binding change (Documentation/devicetree/bindings/gpu/apple,agx.yaml:28-31, :272-275) only widens the accepted names: a [g17d, g17s] node fails const: apple,agx-g17s and matches contains: apple,agx-g17d, so the one-MMIO/two-mailbox schema applies to it, while [g17c, g17s] and bare g17s nodes take the entries they took before. The loader side (aura#261-#264) is merged. The branch merges cleanly with current integration/aurora.

  1. Nit: the GPU mailbox compatible apple,t6050-j775d-ascwrap-v6 (t6050-j775d-gpu.dtsi:72, :86) is a board name on a block that is identical on every T6050 board (the J714s, J716c and K114c files already use it). Not introduced here, but adding a fourth user makes it harder to change; a follow-up that renames it to the SoC compatible (and moves the shared GPU part into one included file, as the description suggests) would fix both.

HW row: J775D on current integration/aurora with this branch, default command line: render node present, the 628-case subset at 571 pass / 57 not supported, cpu_capacity 754/1024 and six cluster_cpus_list groups of five, plus 0 AVC denials, 0 failed units and 0 new kernel errors against the same base without the branch.

Assisted-by: LLM (Claude:Opus 5.5)

…eduler gets the M5 Ultra's M and P core capacities (754 and 1024, not 1024 on all thirty)

The M5 Ultra's CPU nodes have no cpu-map, so Linux sees thirty CPUs in
one package with no clusters. parse_dt_topology() reads
capacity-dmips-mhz only while it walks cpu-map, so the M and P core
capacities that t6050-base.dtsi gives every T6050 CPU (dj's aurora-silicon#1399) never
reach the scheduler: on the J775D (Mac Studio) every CPU reports
cpu_capacity 1024, and cluster_cpus_list reads thirty clusters of one.

Describe the six clusters the way the one-die description does, commit
68c10dd ("arm64: dts: apple: t6050: Describe the CPU clusters"):
MPIDR Aff1 0, 1 and 2 are die 0's M0, M1 and P clusters and 0x10, 0x11
and 0x12 are die 1's, five cores each, as the ADT's cluster-id and
die-id give them. The clusters are listed flat, cluster0-2 on die 0 and
cluster3-5 on die 1, as the M1 and M2 Ultra descriptions (t6002.dtsi,
t6022.dtsi) list theirs; the topology parser does not support clusters
of clusters. The boot loader prunes the entries of cores it did not
start. The capacities in t6050-base.dtsi are kept as they are.

The caches are described already: dj's commit 1bd5f40 ("arm64:
dts: apple: t6050: Describe the CPU caches") gives each cluster its L2
and points each CPU's next-level-cache at it, and each cluster here is
the set of CPUs that share one of those L2s.

Only t6050-j775d.dts includes t6050-ultra.dtsi, so the J775D is the only
board whose device tree changes: the ten other T6050 board device trees
(J714c, J714s, J716c, J716s, J775c, J873s, K114c, K114s, K116c, K116s)
are byte-identical with and without the series. The one-die description
(t6050-max.dtsi) has its cpu-map already; this commit leaves it
unchanged.

Testing, on J775D, integration/aurora's head of 2026-11-21 (a84637d,
the merge of aurora-silicon#2654), one boot with and one without the series, both
with a local display fix that is not part of it: cpu_capacity reads 754
on the twenty M cores and 1024 on the ten P cores (1024 on all thirty
without), and cluster_cpus_list reads six lists of five (thirty lists of
one without). Each CPU's L2 reads the same either way: 8 MiB or 16 MiB,
shared by its own cluster's five.

Signed-off-by: Jeff Queisser <funkzy@users.noreply.github.com>
…d), so the Mac Studio's GPU can be described

The M5 Ultra has the T6050's GPU on two dies (G17D). The driver matches
the family name "apple,agx-g17s" and tells the M5 parts apart by the
GPU's ID registers, so the Ultra needs no entry of its own there, but
its device tree should say which part it is.

Allow "apple,agx-g17d" with "apple,agx-g17s" as its fallback, beside the
M5 Max's "apple,agx-g17c" that ewb's commit 4c7fdf1 ("dt-bindings:
gpu: apple: Describe the J716c GPU and panel handoff") added: his entry
becomes a list of two names, the form the G13 and G14 parts already use
(apple,agx-g13c and apple,agx-g13d, apple,agx-g14c and apple,agx-g14d).

The M5 Ultra's GPU node has the M5 Pro's hand-off shape: one "sgx"
range, the two firmware mailboxes and the six reserved regions, and no
operating-point tables. Since sithglan's commit 8f418a4
("dt-bindings: gpu: apple,agx: Tell the two G17S layouts apart") that
entry applies to a node whose only compatible is "apple,agx-g17s", so
apply it to a node with "apple,agx-g17d" as well. A node with only
"apple,agx-g17s" and a "apple,agx-g17c" node take the entries they took
before, and no existing device tree uses the new name.

Signed-off-by: Jeff Queisser <funkzy@users.noreply.github.com>
…ing GPU: describe it for the boot loader's handoff

The GPU driver has the M5 Ultra's configuration, but the J775D device
tree leaves the GPU and both GPU coprocessor nodes of the inventory
disabled, with no mailboxes and no reservations, so the Mac Studio boots
without a render node and its desktop session cannot start.

Add t6050-j775d-gpu.dtsi in the shape of dj's
t6050-j714s-gpu-panel.dtsi, commit 32a31cf ("arm64: dts: apple:
t6050-j714s: Describe the GPU and panel handoff"): the "gpu" alias, the
six reservations the boot loader fills, the two firmware mailboxes in
place of the inventory's coprocessor nodes, GPX and AFR held on, and the
GPU node's handoff properties. The J775D ADT gives the same addresses
and interrupts as J714s's: both firmware roles and their mailboxes are
on die 0. Two things differ from the J714s file:
- no panel or display part: the Studio's display chain is described
  already;
- the part's name, "apple,agx-g17d", with the "apple,agx-g17s" fallback
  the driver and the boot loader match.

The GPU part now reads much the same in four board files: the J714s,
J716c and K114c GPU files and this one. It could be one shared file
that they include; this leaves the others as they are.

Everything stays disabled in the source: the boot loader enables the
nodes after checking the ADT and the GPU firmware build. A loader that
does not know the Ultra's build leaves the GPU off, as today. Only
t6050-j775d.dts includes the new file.

Testing, on J775D, integration/aurora's head of 2026-11-14 (the merge
of aurora-silicon#1901) with this series, in six boots: one through aura main with the
loader's own pull request ("kboot: T6050: hand the M5 Ultra's GPU to
Linux instead of refusing its firmware build"), the kernel uploaded over
USB, and five through a boot loader that also hands over the display. In
each the loader reports the GPU enabled, the driver probes
2300000000.gpu with both firmware roles' initdata acknowledged, and a
render node appears, where integration's head has none; the compute and
chained-submit checks pass, 46 concurrent clients pass, and a 628-case
render CTS subset reads 571 pass and 57 not supported, with no GPU
recovery, fault or timeout in the kernel log. The ten other T6050 board
device trees (J714c, J714s, J716c, J716s, J775c, J873s, K114c, K114s,
K116c, K116s) and T8142's J704, J813 and J815 are byte-identical with
and without the series.

Signed-off-by: Jeff Queisser <funkzy@users.noreply.github.com>
@funkzy funkzy changed the title arm64: dts: apple: t6050-j775d: Give the Mac Studio (M5 Ultra) a working GPU, and up to 1.5x faster light GPU submits arm64: dts: apple: t6050-j775d: Give the Mac Studio (M5 Ultra) a working GPU, and its M and P core capacities (754/1024) to the scheduler Nov 21, 2026
@funkzy

funkzy commented Nov 21, 2026

Copy link
Copy Markdown
Contributor Author

Thanks, Ryan. Here is the J775D row on the rebased head (0a83dd0, below): integration/aurora a84637d, with and without this branch, 27.0 firmware, default command line, read-only test root. Both kernels also carry one local fix, because integration oopses at boot on the J775D in apple_drm_bind. An HDMI processor without HDMI audio gets a CEC-only AV endpoint, and av_service_connect() dereferences its NULL audio owner, so there is no /dev/dri and the GPU module never loads. The fix keeps such an endpoint out of the audio service calls. It isn't part of this PR and can go up as its own. a84637d still needs it: since cc14570, where the oops was seen, integration has changed only the T6050 CPU and cache nodes.

a84637d a84637d + #1973
Render node absent (card0 only; the desktop does not start) renderD128 present
Render CTS subset (628 cases) not run (no render node) 571 Pass, 57 NotSupported
cpu_capacity 1024 on all 30 CPUs 754 on 20, 1024 on 10
cluster_cpus_list 30 groups of one six groups of five (0-4, 5-9, 10-14, 15-19, 20-24, 25-29)
L2 (cache/index2) 8 MiB shared by 0-4, 5-9, 15-19 and 20-24; 16 MiB shared by 10-14 and 25-29 the same
Failed units iwd.service, systemd-networkd-persistent-storage.service the same two
Kernel error lines 3 the same 3, plus 2 distinct lines, each logged twice (below)

Both failed units fail on the read-only test root in every boot. ALARM has no SELinux, so there is no AVC count.

The two extra lines are cpufreq: cpufreq_boost_trigger_state: Cannot enable BOOST and store_boost: Cannot enable BOOST!. power-profiles-daemon writes cpufreq/boost when it starts, and it only starts with the desktop, which the base boot doesn't reach. Starting it by hand on the base boot logs the same two lines. So they come from the base, not from this branch, which leaves 0 new kernel errors.

Two more notes:

  • Rebased onto integration/aurora a84637d (dj's arm64: dts: apple: t6050: Describe the CPU caches #2654 included): the new head is 0a83dd0. dj's "Describe the CPU caches" already gives each T6050 cluster its L2 and points every CPU's next-level-cache at it, so the cluster commit now keeps his L2 nodes, labels and CPU macros exactly as he wrote them and adds only the cpu-map on top, inside cpus after the last CPU, as t6050-max.dtsi has it. Its own six L2 nodes and thirty next-level-cache overrides are gone, and its message no longer quotes the submit-latency rows, which were measured against a base without L2 nodes. The other two commits are unchanged (git range-diff: =). The head merges cleanly with integration. dt_binding_check for gpu/apple,agx.yaml passes, and dtbs_check on the eleven T6050 DTBs adds no diagnostic (17 lines on the base, the same 17 with the branch, none on J775D). t6050-j775d.dtb is the only DTB that changes; the other ten are byte-identical. checkpatch: 0 errors, and one warning, its "does MAINTAINERS need updating?" note for the new t6050-j775d-gpu.dtsi.

  • The mailbox compatible. Agreed, apple,t6050-j775d-ascwrap-v6 is board-named, and the J714s, J716c, K114c and K116s GPU files already use it. I'd rather not widen arm64: dts: apple: t6050-j775d: Give the Mac Studio (M5 Ultra) a working GPU, and its M and P core capacities (754/1024) to the scheduler #1973. As a follow-up I can:

    • add the SoC compatible apple,t6050-ascwrap-v6 to the binding and the driver match, keeping the board-named string accepted for DTBs already built;
    • switch the T6050 boards to the SoC compatible;
    • move the GPU part those five t6050-*-gpu*.dtsi files share into one included file.

    Shall I go ahead?

@RyanTheTide

Copy link
Copy Markdown
Contributor

Re-review of 0a83dd0: No blockers.

From our last comment:

  1. The board-named GPU mailbox compatible (apple,t6050-j775d-ascwrap-v6, t6050-j775d-gpu.dtsi:72, :86): not changed here, which is fine for this PR. Yes, please do the follow-up you describe: add apple,t6050-ascwrap-v6 to the binding and the driver match, keep the board-named string accepted for existing DTBs, switch the T6050 boards over, and move the shared GPU part into one included file.
  2. HW row: resolved. You posted the J775D row on a84637d with and without the branch on the default command line: render node present, 571/57 on the 628-case subset, cpu_capacity 754 on 20 and 1024 on 10, six cluster_cpus_list groups of five, the same failed units, and 0 new kernel errors. (The local apple_drm_bind oops fix you carried has since landed as drm/apple: av: fix a boot oops that leaves no display device when an HDMI port has CEC but no audio #2733.)

Since then only the cluster commit changed. t6050-ultra.dtsi:66-174 now adds just the cpu-map. Its six clusters list exactly the CPUs that share each of #2654's L2s, as the T6050_*_CPU lines at t6050-ultra.dtsi:30-59 have them (cpu0-4 on l2_cache_mc0, through cpu30-34 on l2_cache_pc_die1), and they match the MPIDR Aff1 groups and cpufreq domains. The L2 nodes, labels and CPU macros are #2654's, left as they were. The binding and GPU-file commits are unchanged. Integration has gained 47 commits since a84637d, but none of them touch t6050 DT files or apple,agx.yaml, so the row still applies.

Assisted-by: LLM (Claude:Opus 5.5)

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.

2 participants