Skip to content

drm/asahi: g15: M3 Pro: pin the cd05 and 4118 firmware TEXT, and decline early probes with -ENODEV - #2146

Open
scottjones wants to merge 7 commits into
aurora-silicon:mainfrom
scottjones:upstream/m3pro-g15-firmware-text
Open

scottjones wants to merge 7 commits into
aurora-silicon:mainfrom
scottjones:upstream/m3pro-g15-firmware-text

Conversation

@scottjones

@scottjones scottjones commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Two fixes for M3 Pro (T6030) Macs.

J514S and J516S boot chains on 14.7 can load T6030 firmware whose TEXT digest is not in the admission table, so probe refuses it and there is no render node. This pins the cd05 and 4118 digests once each, with no board key: the J514S and J516S load the same TEXT for both. The golden pins are refreshed.

Before activation the G15 probe returned -EPROBE_DEFER. If the real probe later failed for good, the GPU stayed on the deferred-probe list and anything waiting on that list kept waiting. It now returns -ENODEV; activate() already reprobes unbound devices.

 g15 probe, before MODULE_READY
-  return -EPROBE_DEFER
+  return -ENODEV   (activate() reprobes)

Evidence

  • Built on integration/aurora a7dd26e6d60e with the 7.3 package config, LLVM 18 and Rust 1.85:
    • make W=1 drivers/gpu/drm/asahi/: builds
    • W=1: no warnings the base does not have
    • run-host-tests.py: every tools/asahi test is registered
    • tools/asahi host tests (control and mutation runs): g15-maintained-handoff-tests 2/2, g15-probe-init-tests 2/2, g15-zero-words-tests 2/2
    • Stacked with the other 12 PRs on the same base, the full kernel, modules and DTBs build and package (linux-aurora 7.3.0-0testastip2-1-ARCH, 137 DTBs).
  • Booted as part of the full set: a kernel built from integration/aurora a7dd26e6 plus all 13 branches of this set (before the three small fix-up commits) booted on an M3 MacBook Air (J613), a Neo (J700) and an M1 Pro with no regressions against their baselines (on the M1 Pro, only the checks already known to differ: GPU name and DRAM OPP), and a 25-minute GPU soak was clean on all three. No M3 Pro, M3 Max, J504, J615 or M4 Pro ran this kernel.
  • The cd05 and 4118 digests come from owner reports in What rewrites the GPU firmware TEXT on T6030/T6031 omacom/linux-aurora#247 (issue); with the prefix override those Macs reached firmware READY with a render node. The -ENODEV change is drm/asahi: g15: decline probes before activation with -ENODEV omacom/linux-aurora#470.

Boot firmware

The cd05 and 4118 rows are the images the J514S and J516S load on the 14.7 boot stub. Owners reported them on system firmware 15.5, 26.5.2 and 26.6.2; the system firmware doesn't select which image loads. Admitting T6030 on the 27.2 (26B123) stub is separate work: it needs that stub's GPU firmware measured on an M3 Pro, and a check that its interface matches the one this table supports. This PR doesn't guess either.

Merge Danger

Door: two-way

Blast Radius: M3 Pro

The firmware rows admit two more digests on T6030. Only the J514S and J516S reach this table today (the G15 board check refuses other T6030 boards). The probe change only affects the G15 path before activation.

javanoo6 and others added 5 commits November 17, 2026 06:22
The J514S 14.7 boot chain can load a T6030 firmware build whose full TEXT
digest is not in the admission table. Probe refuses it and no GPU render
node is created.

Desktop use with the explicit prefix override reaches firmware READY and
reduces Hyprland CPU use from several cores to single-digit percentages.
Pin the complete measured digest only for J514S, with its segment sizes
and marker, rather than requiring a persistent bring-up override.

Exercise the production firmware table and exact lookup with the override
disabled. Reject other boards, altered digest suffixes, sizes and markers.

Link: omacom/linux-aurora#247
Signed-off-by: Nikita Konkov <[email protected]>
Signed-off-by: Scott Jones <[email protected]>
The J514S cd05 FirmwareBuild row adds 15 lines to the T6030 firmware
table, which changes the pinned hw.rs file and t6030 module digests.
With that row removed both digests are their previous values, so the
T6030 profile itself is unchanged. Refresh the two pins and record why.

Signed-off-by: Scott Jones <[email protected]>
Some 16-inch M3 Pro (J516S) units on the 14.7 boot chain load a B0 GPU
firmware image whose TEXT digest differs from the pinned J516S row:
TEXT 0x5c000, DATA 0x114000, GKTS marker 0x58e88 and TEXT sha256
cd05af6a828b52e4c2fed20086d3d18a7db42e03a8fd6f8354f9f06e0a61363e. The
build is refused with "loaded GFX TEXT identity mismatch", so there is
no render node and the compositor falls back to llvmpipe. The GPU only
starts with the g15_accept_text_prefix bring-up override.

Add this build as a J516S-only row. Rows still pin on the machine they
name; nothing changes on the J514S or on other machines. Extend the
maintained-handoff host test to check the new row and refresh the
zero-words golden pins for hw.rs and the T6030 module, which change by
exactly this one row.

Measured on a J516S (apple,j516s apple,t6030; os-fw 14.7, system-fw
15.5, iBoot2 iBoot-10151.140.19.700.2) with linux-aurora
7.2.11.aurora14-1 and the override: the admission line reports the
identical sizes, marker and digest, and the GPU reaches READY with
renderD128 present.

Link: omacom/linux-aurora#247
Link: omacom/omarchy#17739
Signed-off-by: joel cristobal <[email protected]>
Signed-off-by: Scott Jones <[email protected]>
Some 14-inch (J514S) and 16-inch (J516S) M3 Pro units on the 14.7 boot
chain load a third B0 GPU firmware image: TEXT 0x5c000, DATA 0x114000,
GKTS marker 0x58e88 and TEXT sha256
411833a7ded773feeac4a181552e3ff5582eaf4435f2dd8f620c1ed0b31df1b0. No
row pins it, so probe fails with "loaded GFX TEXT identity mismatch",
there is no render node and the compositor falls back to llvmpipe.

Three machines have reported it in issue omacom/linux-aurora#247, all on the 14.7 stub with
system firmware 26.6.2: a J514S and a J516S (both iBoot-10151.140.19.700.2,
mBoot-18000.161.10), which logged the identical sizes, marker and digest,
and a second 14-inch M3 Pro. With g15_accept_text_prefix=0x411833a7ded773fe
all three reached firmware READY with renderD128 present. The boot
chain matches the J514S cd05 reports, so the chain alone does not
select the image.

Add one row per board, J514S then J516S, so each pin still names the
machine it was measured on; nothing changes for other machines. Extend
the maintained-handoff host test: both boards pin to their own row with
the override disabled, other boards are refused, and an altered digest
suffix, TEXT or DATA size or marker is refused. Refresh the zero-words
golden pins for hw.rs and the T6030 module; with the two rows removed
both are their previous values.

Link: omacom/linux-aurora#247
Signed-off-by: Scott Jones <[email protected]>
Before the module's final activate() step, the G15 probe returned
-EPROBE_DEFER. That put the GPU on the driver core's deferred-probe list.
activate() then runs the real probe through driver_attach(), but if that
probe fails for good, for example because the firmware is rejected, the
driver core does not take the device off the list. It stays in
/sys/kernel/debug/devices_deferred until the deferred-probe work next
runs, so anything that waits on that list keeps waiting.

Return -ENODEV instead. activate() already reprobes every unbound device
once MODULE_READY is set, and a device added later sees it set, so
nothing needs the deferred list to retry. The display and PMP waits
inside the real probe still return -EPROBE_DEFER.

g15-probe-init-tests.py now checks that every probe before activation
returns -ENODEV, and adds a mutant that defers again.

Signed-off-by: Scott Jones <[email protected]>

(cherry picked from commit 6447458 on omacom/linux-aurora, omacom/linux-aurora#470)
[7.3 base: the probe-init test also runs with the G16 registration here, so
 its pre-activation probe count follows the registration order; the new
 mutant is added to this base's expected-failure table.]
@RyanTheTide

Copy link
Copy Markdown
Contributor

The production boot stub pins at macOS 27.2 (26B123), so please retarget this to 27.2. This pins T6030 firmware TEXT that 14.7 boot chains load; please pin the images the 27.2 stub loads on the J514S and J516S.

@scottjones

Copy link
Copy Markdown
Contributor Author

Thanks Ryan. Before I retarget these I want to check I'm reading it right, because as far as I can tell the installer doesn't put 27.2 on any of these boards yet.

At aurora-installer 99f180f, the 26B123 pin has "boards": {}. Its only entries are the experimental j714c, j714s, j716c, j716s, j775c, j775d and j873s, all not_hardware_qualified. The release still ships supported_fw 13.5 and 14.8.3, and the per-device minimums put these PRs on:

PR Boards Installer minimum today
this one J514S, J516S 14.8.3
#2149 J613, J615 14.8.3
#2150 J616s 26.6.2
#2152 v14.7 DCP the M3 boards above, 14.8.3
aurora-silicon/aura#292 J475c 13.4

The "14.7" chains are the 14.8.3 stub: it reports the same iBoot string as 14.7.

The startup firmware doc says a Mac below macOS 27.2 keeps its older entry, and that moving an existing install goes through a slot, since M1 to M3 stub containers are 2.5 GB and a 26.0+ stub needs 6 GB. The slot executor isn't wired yet.

So retargeting these to 27.2 only would drop GPU, camera or display support for current installs on these boards, and those installs can't move to 27.2 until slots land and the owner updates macOS.

Did you mean adding 27.2 support alongside the shipped stubs once slots land, or is there a policy change I've missed? I'm happy to add 27.2 paths in follow-ups once there's a way to test them.

@RyanTheTide

Copy link
Copy Markdown
Contributor

Thanks for tracking down the J514S/J516S images and for the -EPROBE_DEFER fix, which looks right.

On the pins: drivers/gpu/drm/asahi/g15/hw.rs:182,198,214,230 add each of the two TEXT digests (cd05 and 4118) twice, once per board, with machine: Some("apple,j514s") or Some("apple,j516s"). The digest identifies the firmware, and that is what admission needs. Binding the same image to the boards it was seen on means a third T6030 board loading the identical image would be refused.

We select by a hardware or firmware property rather than by the list of machines it was tested on. Could each digest be pinned once for T6030 (machine: None), unless an image really is board-specific? If one is, a short comment saying why would cover it.

This sits alongside the earlier retarget-to-27.2 question, so the two could be handled together.

@RyanTheTide

Copy link
Copy Markdown
Contributor

Merge-train adversarial review (MERGETRAIN-LINUX2) at 147001c: BLOCKERS.

Not merging until the blockers below are fixed or answered; the details give file:line and a failure case.

Full review

#2146 drm/asahi: g15: M3 Pro: pin the cd05 and 4118 firmware TEXT, and decline early probes with -ENODEV @147001c3

VERDICT: BLOCKERS

Blockers:

  1. drivers/gpu/drm/asahi/g15/hw.rs:180-241 adds new per-board admission rows: each of the two TEXT digests is pinned twice, with machine: Some("apple,j514s") (:182, :214) and Some("apple,j516s") (:198, :230). identity.rs:97-99 turns that into an of_machine_is_compatible() gate per row (glue.c:216-219).
    • The rows themselves prove the duplication is not needed. J514S cd05 (:189-192) and J516S cd05 (:205-208) have byte-identical digests, and so do the two 4118 rows (:221-224, :237-240). The image identifies the firmware, and the board adds nothing.
    • This breaks the no-board-gates rule. Ryan's 11-19 comment asked for one machine: None row per digest (or a comment saying why an image is board-specific), and the author has not answered or changed anything since (head 11-17).
    • The host test then hard-codes the board split (g15-maintained-handoff-tests.py: BUILDS.len() == 7, Pinned(3)/Pinned(4)/Pinned(5)/Pinned(6), J514C/J516C refused). It needs to shrink to two rows as well.

Code checks out:

  • g15/mod.rs:205-210: -ENODEV before MODULE_READY is correct.
  • activate() (:236-243) stores MODULE_READY with Release, then asahi_g15_reprobe() runs driver_attach() (glue.c:345-358) and reprobes every unbound device.
  • A probe that sees the flag unset and returns -ENODEV before the store is retried by that attach. A device added later sees the flag set.
  • The real probe's own -EPROBE_DEFER waits (PMP, display) still defer.
  • With -EPROBE_DEFER, a later terminal failure left the GPU on the deferred list. The deferred-probe work would also retry probe_g15 again.
  • The host test adds a mutant (pre-activation-defers) that keeps this from regressing.

Nits:

  • 35bf7a1 and 147001c carry Assisted-by: Claude:claude-opus-5-5, and 147001c and daec11f carry Co-Authored-By: Claude Opus 5.5 (already pushed).
  • In 147001c the human Signed-off-by sits above the cherry-pick note, so git parses no trailers.
  • hw.rs:194-196: the J516S cd05 comment ("load a different B0 TEXT image") reads as if it differed from J514S cd05. It is the same digest. Once the rows collapse into one, the comment should say it differs from the da26 image.
  • The 27.2 retarget question (Ryan 11-17; scottjones 11-18 says the installer still ships 14.8.3 for J514S/J516S and the slot executor is not wired) is still open. Ryan should rule on it explicitly before merge. It is not a code defect.
  • The golden-digest pins (g15-zero-words-tests.py) churn with every hw.rs row edit. Expected, but it means this PR's test refresh has to be redone after blocker 1.

Missing rows:

  • No M3 Pro or M3 Max has run this kernel. The digests come from owner reports in omacom#247, and those reached READY only with g15_accept_text_prefix.
  • Needed: J514S and J516S on the cd05 and the 4118 image each, default cmdline (no prefix override), showing "GPU firmware build: ..." pinned, a render node, and a GL desktop.
  • The -ENODEV change affects every G15 bind (T6030 and T6031). Needed: one M3 Max (J514C/J516C) boot showing the adapter binds after activation, with devices_deferred empty of the GPU, plus one forced-refusal boot (unknown digest) showing the GPU absent from devices_deferred.

@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.

Formal §1–§6 pre-PR review at 147001c39e7f4e0efce47d1e139641abfa791add (against live integration/aurora 70a00e583b03): REQUEST_CHANGES.

Audit Summary

  • Code check (drivers/gpu/drm/asahi/g15/mod.rs:205-210 & tools/asahi/g15-probe-init-tests.py): The pre-activation -EPROBE_DEFER -> -ENODEV fix is clean and sound (activate() reprobes unbound devices once MODULE_READY is set). Not superseded on integration/aurora; mergeable: clean; host-tests green.

Blockers (§1, §4, §5)

  1. §1 Per-board gating with duplicated byte-identical firmware rows (drivers/gpu/drm/asahi/g15/hw.rs:180-241, tools/asahi/g15-maintained-handoff-tests.py):
    • Adds 4 new FirmwareBuild rows pinning the two identical TEXT digests (cd05af6a... and 411833a7..., same text_size: 0x5c000, data_size: 0x114000, marker: 0x58e88) twice each with machine: Some(kernel::c_str!("apple,j514s")) and machine: Some(kernel::c_str!("apple,j516s")).
    • identity.rs enforces of_machine_is_compatible() on machine: Some(...), refusing any other T6030 board running the identical firmware image. As previously requested in review, collapse to one machine: None row per digest (unless a digest is genuinely board-specific with an inline justification) and update g15-maintained-handoff-tests.py and g15-zero-words-tests.py accordingly.
    • (Note: please also resolve the open maintainer alignment on 14.7 vs. macOS 27.2 / 26B123 stub targeting alongside the row update.)
  2. §4 AI trailers inside commit messages + PR body disclosure:
    • Three commits carry prohibited AI commit trailers:
      • daec11fda43a: Co-Authored-By: Claude Opus 5.5 <[email protected]>
      • 35bf7a1895f4: Assisted-by: Claude:claude-opus-5-5
      • 147001c39e7f: Assisted-by: Claude:claude-opus-5-5 and Co-Authored-By: Claude Opus 5.5 <[email protected]>
    • Per §4, commits must carry human identity and human Signed-off-by: only (zero Co-Authored-By: or Assisted-by: trailers in commits). Disclose AI assistance at the end of the PR body with a plain Assisted-by: line (replacing the 🤖 Generated with [Claude Code] footer).
  3. §5 Missing exact-head M3 Pro (T6030) hardware & regression evidence:
    • The PR body notes that no M3 Pro ran this kernel (the only listed boot was an earlier 13-branch stack on a7dd26e6 on J613/J700/M1 Pro). Provide an exact-head boot on affected M3 Pro hardware (default command line, without g15_accept_text_prefix) confirming firmware READY + renderD128 plus the regression row (0 SELinux denials, 0 failed units, 0 new kernel errors).

@scottjones
scottjones force-pushed the upstream/m3pro-g15-firmware-text branch from 147001c to e38d990 Compare November 23, 2026 23:25
The J514S and the J516S load the same cd05 and 4118 B0 TEXT on the
14.7 boot chain: the TEXT digests (entropy bytes zeroed), sizes and
markers match. Pinning each image once per board keyed the firmware
identity on the board compatible, though nothing the identity checks is
board-specific. Replace the four per-board rows with one
board-independent row per image, as review asked.

The maintained-handoff test now checks that both images pin on the
J514S, the J516S and a bare T6030, and that the T6030 table holds the
expected five rows with the cd05 and 4118 rows board-independent. The
zero-words golden pins for hw.rs are refreshed for the smaller firmware
table.

Signed-off-by: Scott Jones <[email protected]>
@scottjones
scottjones force-pushed the upstream/m3pro-g15-firmware-text branch from 9998063 to 60c5423 Compare November 24, 2026 05:06
@github-actions github-actions Bot added area:gpu Area from CODEOWNERS (bot) blast:m3 Macs affected, from Merge risk (bot) changes-requested A reviewer requested changes (bot) door:two-way Revertible or not, from Merge risk (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
@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown

Merge readiness at 89faf622: not ready yet

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

Areas: area:gpu

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

DjDeveloperr
DjDeveloperr previously approved these changes Nov 25, 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 60c5423d8bf9: the code is ready; it needs only a row at this head.

Blockers: none in the code. Missing row: one J514S or J516S boot at this head on the 14.7 stub with the GPU admitted (a render node, the cd05 or 4118 image named in dmesg). Thanks for reworking it.

Checked: no Apple material. 60c5423d fixes the per-board point: the two digests are pinned once each for any T6030, with no board key. The early-probe decline returns -ENODEV. CI green.

@DjDeveloperr
DjDeveloperr dismissed their stale review November 25, 2026 05:12

Superseded by the review at 60c5423

@github-actions github-actions Bot added merge-conflict Conflicts with the base branch (bot) and removed changes-requested A reviewer requested changes (bot) needs-review No approving review from Core or Omarchy Mac yet (bot) merge-conflict Conflicts with the base branch (bot) labels Nov 25, 2026
@github-actions github-actions Bot added the merge-conflict Conflicts with the base branch (bot) label Nov 25, 2026
@RyanTheTide

Copy link
Copy Markdown
Contributor

Could you merge current main into this branch and push the merge normally? At 7a4afed5b4d1, g15/hw.rs, g15-maintained-handoff-tests.py and g15-zero-words-tests.py conflict.

Main already returns -ENODEV before activation and contains four board-qualified copies of the two 14.7 firmware records. The remaining change is to keep one record per firmware identity and update the tests, preserving the newer 27.2 handoff behavior. That should leave a small diff for review.

@github-actions github-actions Bot added merge-conflict Conflicts with the base branch (bot) and removed merge-conflict Conflicts with the base branch (bot) labels Nov 26, 2026
main pinned the cd05 and 4118 B0 TEXT images once per board (J514S,
J516S). This branch pins each of them once for any T6030, since the
image is not board-specific. The two FirmwareBuild conflicts in
g15/hw.rs keep this branch's board-free rows. main's other changes to
the file (the CONFIG_DRM_ASAHI_G15 cfg lines for the T8122 runtime)
are kept.

The host tests take this branch's expectations for the conflicting
cases. g15-zero-words-tests.py keeps main's comment on the cfg lines
and pins the merged hw.rs (eff5ef8e).

g15-maintained-handoff, g15-zero-words and g15-probe-init host tests
pass.

Signed-off-by: Ryan Murray <[email protected]>
@RyanTheTide

Copy link
Copy Markdown
Contributor

The 24-hour window from the 11-25 ask has passed, so as maintainers we merged main into your branch with a normal push (no force push): 89faf622, parents 60c5423d and main a851ca0e.

How the conflicts were resolved:

  • g15/hw.rs: main pinned cd05 and 4118 once per board (J514S, J516S; your c5e990a among them). Both conflicting FirmwareBuild hunks keep this branch's single board-free rows, which is what this PR is for. main's other change to the file, the two #[cfg(CONFIG_DRM_ASAHI_G15)] lines for the T8122 runtime, is kept.
  • g15-maintained-handoff-tests.py and g15-zero-words-tests.py: the conflicting cases take this branch's expectations. The zero-words golden for the merged hw.rs is refreshed to eff5ef8e, and main's comment about the cfg lines is kept.
  • g15/mod.rs and g15-probe-init-tests.py merged without conflicts.

The three G15 host tests (maintained-handoff, zero-words, probe-init) pass at the merge. Your rows ran the same change before the merge. The only difference in the tables is main's cfg lines, which don't change any row. If you'd rather resolve it differently, push on top and we'll re-check.

@github-actions github-actions Bot added ci-failing A check failed at the PR head (bot) needs-review No approving review from Core or Omarchy Mac yet (bot) and removed merge-conflict Conflicts with the base branch (bot) labels Nov 26, 2026

@aurora-silicon-review aurora-silicon-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Verdict: HOLD at 89faf622 pending exact-head CI and hardware evidence.

Checked: The forward merge leaves one T6030 record per measured image, preserving full digest, sizes and marker as the identity checks. The host test covers both reported boards and the generic T6030 lookup, including refusal of mutated identity fields. The activation behavior is already in main and is outside the remaining diff. GitHub now reports the head mergeable.

Blockers: Attach the current-head build and a T6030 row showing normal pinning through render-node creation on the affected 14.7 boot chain, without the prefix override. The older stacked rows did not include an affected M3 Pro. Retain the fast-track policy for this outside contribution.

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:gpu Area from CODEOWNERS (bot) blast:m3 Macs affected, from Merge risk (bot) door:two-way Revertible or not, from Merge risk (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.

5 participants