Repository navigation
Conversation
This was referenced Nov 15, 2026
Open
Merged
…2s, for up to 1.5x faster and steadier light GPU submits on M5 Ultra The M5 Ultra's CPU nodes have no cpu-map and name no cache, so Linux sees thirty CPUs in one package with no clusters, and one L2 shared by all thirty. Two things follow on the J775D (Mac Studio): - 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: every CPU reports cpu_capacity 1024. - With no last-level cache to group the CPUs by, the scheduler's cache-sharing domain is the whole package: a wakeup may pick any idle CPU of the thirty, on either die. 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. Add one L2 cache node per cluster and point each CPU's next-level-cache at its cluster's: the ADT gives each CPU an l2-cache-size of 8 MiB in the M clusters and 16 MiB in the P clusters. It gives no L1 sizes and no L2 geometry, so the nodes carry the level and the size only. They sit in /cpus as l2-cache-N, as in t6002.dtsi and t6022.dtsi. Both are in one commit because the gain needs both. With the cpu-map alone the clusters and capacities appear, but every CPU still reports its L2 as shared by all thirty, and the rows below read as without it (18.4-23.0 us at depth 8, on integration's head of 2026-11-10). 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 a cpu-map and no cache nodes; this commit leaves it unchanged. Testing, on J775D, integration/aurora's head of 2026-11-14 (the merge of aurora-silicon#1901) with the J775D GPU described (its own pull request), two boots with and two without this commit, three passes of each row a boot: - cpu_capacity reads 754 on the twenty M cores and 1024 on the ten P cores (1024 on all thirty without); cluster_cpus_list reads six lists of five (thirty lists of one without); each CPU's L2 reads 8 MiB or 16 MiB shared by its own five (no size, shared by all thirty, without). - A light compute submit with 8 in flight takes 16.8-17.6 us against 20.1-23.5, and with 64 in flight 13.7-14.5 us against 16.1-24.0. A 720p fill with 4 in flight takes 43.3-45.4 us against 50.5-70.3. By the median of the six passes these are 1.31x, 1.52x and 1.40x. A single-triangle render with 8 in flight takes 31.9-32.5 us against 30.9-37.6, and with 32 in flight 29.1-29.9 us against 28.2-38.0: steadier rather than faster. Single submits and the heavy compute rows are unchanged, and a semaphore hop between two queues takes 42.3-46.5 us against 45.0-49.1. - The GPU's compute and chained-submit checks, 46 concurrent clients and a 628-case render CTS subset (571 pass, 57 not supported) read the same either way, with no GPU recovery, fault or timeout in the kernel log. 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>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What is missing
GPU coprocessor nodes disabled, with no mailboxes and no reservations. The Mac Studio boots without a render
node and its desktop session cannot start.
t6050-ultra.dtsihas nocpu-mapand names no cache, so Linux sees thirty CPUs in onepackage with one L2 shared by all thirty.
parse_dt_topology()readscapacity-dmips-mhzonly while it walkscpu-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 1024), and a wakeupmay pick any idle CPU of the thirty, on either die. 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:
t6050-ultra.dtsi). Acpu-mapin 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.dtsiandt6022.dtsilist theirs. One L2 node acluster and each CPU's
next-level-cache: 8 MiB in the M clusters, 16 MiB in the P clusters, the ADT'sl2-cache-size. One commit because the gain needs both: with the
cpu-mapalone every CPU still reports its L2as shared by all thirty and the rows below do not move.
apple,agx-g17dwith theapple,agx-g17sfallback, added to the entry ewb's 4c7fdf1 made forthe M5 Max's
apple,agx-g17c: his entry becomes a list of two names, the form the G13 and G14 parts use. Thedriver 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
sgxrange, twofirmware 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 withapple,agx-g17das well.t6050-j775d-gpu.dtsi, in the shape of dj'st6050-j714s-gpu-panel.dtsi(32a31cf): thegpualias,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
t6050-j775d.dtsincludest6050-ultra.dtsiand 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.
apple,agx-g17sand anapple,agx-g17cnode take the entries they took before; no existing device tree uses thenew name.
t6050-max.dtsi) has acpu-mapand no cache nodes and is left asit is. dj, J714s may show the same thing (one L2 "shared" by every CPU in
/sys/devices/system/cpu/cpu0/cache/index2/shared_cpu_list); if it does, the same L2 nodes would be a smallchange there. satchlj's open arm64: dts: apple: port the boot-tested J775c compatibility layout #1619 gives the J775c (Mac Studio, M5 Max) per-cluster L2 nodes in its own files;
the node names here follow
t6002.dtsiandt6022.dtsi, and can follow his instead if reviewers prefer onescheme.
Depends on
today, and the cluster commit needs nothing.
(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 withouta conflict.
Validation
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-t8142entry). On 59b02d5:dt_binding_check DT_SCHEMA_FILES=gpu/apple,agx.yamlis clean on the head and with this pullrequest.
dtbs_checkon all eleven T6050 boards reports the same 18 distinct lines with and without it (allalready 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):
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 (MAINTAINERSalready covers
arch/arm64/boot/dts/apple/).tools/asahi/run-host-tests.pyon a Linux host, on integration/aurora at fc05050: 321 of 321 runs pass, onthe head and on the head plus this pull request and the other linux pull request below; no run differs.
dt_binding_check DT_SCHEMA_FILES=gpu/apple,agx.yamlis clean on the head and with this pullrequest.
dtbs_checkon all eleven T6050 boards reports the same 55 lines with and without it (all already onthe head: the display mux lists of J716c and J714s, J716c's operating points, J714s's DART
reg-names, the PCIeport0nodes), 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 7c71d6d with this pull request:
carried a compute-timestamp change that is no longer in this set): the loader reports "T6050 G17D 26A428
enabled", the driver probes
2300000000.gpuwith both firmware roles' initdata acknowledged, and a render nodeappears, 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.
cpu_capacityreads 754 on the twenty M cores and 1024 on the ten P cores (1024 on all thirty without);cluster_cpus_listreads six lists of five (thirty lists of one without); each CPU's L2 reads 8 MiB or 16 MiBshared by its own five (no size, shared by all thirty, without).
us against 16.1-24.0. A 720p fill with 4 in flight takes 43.3-45.4 us against 50.5-70.3. By the median of the six
passes these are 1.31x, 1.52x and 1.40x.
29.1-29.9 us against 28.2-38.0: steadier rather than faster.
against 45.0-49.1.
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.
dfb_ready_querycommit (mergedsince, 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:
dj's mesa usb: xhci: plat: fix the modpost break in xhci-plat-test (KUNIT_ALL_TESTS=m), add missing KUnit module descriptions #347 is in; no GPU recovery, fault or timeout.
1920x1080@60 (no DisplayPort monitor was connected). Integration has no 26B123 build for the M5 Ultra, so the GPU
driver refuses the firmware at probe and the boot goes on without the GPU.
one-entry G17D 26B123 build (neither part of this pull request) on top, both firmware roles' initdata are
acknowledged and the GPU checks, the 628-case subset (571 pass, 57 not supported) and the desktop on HDMI read
the same as on the 27.0 stub with that kernel. This uses drm/asahi: M5: InitData for the macOS 27.2 and 27.3 firmware (G17S bring-up on J716s) #1173's 27.2 values as they are.
Not tested
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.