Skip to content

drm/asahi: g17: identify the M5 Max 27.3 (26C5035r) firmware (on #1173) - #1602

Open
joshuaswarren wants to merge 12 commits into
aurora-silicon:integration/aurorafrom
joshuaswarren:w7c/up-g17-m5max-fw
Open

joshuaswarren wants to merge 12 commits into
aurora-silicon:integration/aurorafrom
joshuaswarren:w7c/up-g17-m5max-fw

Conversation

@joshuaswarren

@joshuaswarren joshuaswarren commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

On top of #1173. Only the last commit is new; the first ten are Rolando Trevino's from that PR.

The GPU of the 14-inch M5 Max MacBook Pro (K114c, T6050) loads the G17C build of the macOS 27.3 (26C5035r) firmware. The driver only accepts firmware builds it has identified, and this one was not in the table. This identifies it in hw/t6050.rs next to the 27.0 (26A428) G17C entry and points it at the V26C5035_M5 variant from #1173.

I measured the identity from the loaded G17C TEXT on the machine: size 0xa4000, entropy records at the same offsets as the G17S 27.3 build, and the normalized digest came out the same on three boots.

Tested on a 14-inch M5 Max MacBook Pro with #1601 and the K114c device tree handoff: the driver logs GPU firmware: 27.3 (26C5035r), G17C, both initdata blocks are acknowledged and /dev/dri/card1 and renderD128 appear. A Wayland triangle renders and fdinfo shows 42 ms vertex and 39 ms fragment time. Hyprland runs on the GPU with Mesa from the matching branch.

It needs #1173 to merge first; only the last commit is for review here.

Validated on, and reach

Validated on: 14-inch M5 Max MacBook Pro (K114c, T6050) with #1601 and the K114c device-tree handoff: the driver logs GPU firmware: 27.3 (26C5035r), G17C, /dev/dri/card1 and renderD128 appear, a Wayland triangle renders, and Hyprland runs on the GPU.

Applies beyond the M4: No. It identifies one firmware build in hw/t6050.rs. It needs #1173 first; only the last commit is new here.

m tester run (omarchy-m-testing.org): feature rows GPU. The tester needs the hardware; no tester run is linked to this change.

@RyanTheTide

Copy link
Copy Markdown
Contributor

Thanks Joshua, the identification work here is solid. We're holding this one for now: the M5 boot path is targeting the stable 27.2 release (Stage 1 in CTXR mode, where every core comes up at EL2), so the G17C entry we want is the 27.2 build, not 26C5035r. Same direction as on aura#172. It also still sits on #1173, which has to merge first. When you have the 27.2 G17C identity, a rebase onto #1173 with that entry is what we'd merge.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-18T20:37:07.385424Z
We couldn’t complete this review. Comment @codex review to try again.
5588117 Draft marked ready
🔒 Security Review ❌ Failed 2026-11-18T20:37:12.953724Z
We couldn’t complete this review. Comment @codex security review to try again.
5588117 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@chatgpt-codex-connector

Copy link
Copy Markdown

The account paying for this security review has reached its Codex usage limits. The payer can check the Codex usage dashboard. For personal accounts, using credits requires enabling “Use credits for security reviews” in Code review settings. If you do not manage the paying account, contact this repository's admins.

@RyanTheTide

Copy link
Copy Markdown
Contributor

(No new comment needed; the open ask on the PR stands: the 27.2 G17C identity on top of #1173 once #1173 is rebased.)

@joshuaswarren

Copy link
Copy Markdown
Contributor Author

[Joshua's agent] This PR has the same conflict as #1173 against release/7.3.0-40 and integration/aurora (details and plan in #1173 (comment)). I am porting #1173 and this commit onto the release branch and will link the stacked result here.

@joshuaswarren

Copy link
Copy Markdown
Contributor Author

[Joshua's agent] Dropped: the stacked port I promised here (with #1173) was not made and will not be opened from me. Nothing was built or booted for it, and it needs M5 Max boots I have no slot for. This PR still carries the ten commits of #1173 plus the one that identifies the 26C5035r firmware, so it is reviewable only after #1173 is rebased.

@joshuaswarren

Copy link
Copy Markdown
Contributor Author

[Joshua's agent] Back to draft: this no longer applies to integration/aurora. The base has since gained the common26 layout machinery this stack predates, so it needs a rework onto that, not a rebase. No review needed until it returns.

@joshuaswarren
joshuaswarren marked this pull request as ready for review November 18, 2026 20:37
@joshuaswarren

joshuaswarren commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor Author

Reworked onto the base's common26 layout machinery as the draft note asked; head e97b6fb. What changed: the M5 firmware InitData layouts (26B123 and 26C5035r profiles, policy and status-config relocation, the two new J714 boards) and the t6050 identification for the 27.2 and 27.3-beta1 builds, now expressed through the base's RootProfile scheme instead of the old stack's per-variant field. The 27.3-beta1 M5 Max has its own board record (J716C_26C5035: 4 clusters, 40 cores, the Max perf tables), so a real Max probes through instead of matching the Pro board. The drm module builds for arm64 with rustc 1.96.0 and bindgen 0.73.2; every ported table is byte-identical to the source stack. Two commits, one per file group, plus one review fixup commit that folds into them.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@chatgpt-codex-connector

Copy link
Copy Markdown

The account paying for this security review has reached its Codex usage limits. The payer can check the Codex usage dashboard. For personal accounts, using credits requires enabling “Use credits for security reviews” in Code review settings. If you do not manage the paying account, contact this repository's admins.

satchlj and others added 6 commits November 19, 2026 08:49
Describe die-0 ATC0, ATC1 and ATC3 in the shared T6050 files using
acioN names and the integration ATC2 resource layout. ATC0/1/3
addresses and interrupts come from the retained J775c ADT description
(e579145cd); no open J716c display branch is a dependency.

Replace the disabled usb4_3_acio description with acio3 and update its
existing board references. Keep tunables, DROMs, PD endpoints and
activation in board files. Expose the existing acio2 to the other Max
boards disabled, preserving current J714c/J714s/J716c activation and
PCIe-tunnel wiring. The current integration driver foundations and
original authorship remain in ancestry.

Signed-off-by: Satya Benson <satya@benson.earth>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit cd3e03d)
Signed-off-by: Diljit Singh <hey@djdev.me>
Keep the required NHI DROM property on disabled shared instances. Existing board DROMs override the placeholder; no unit identity is embedded in the shared resource descriptions.

Signed-off-by: Satya Benson <satya@benson.earth>
(cherry picked from commit c88cd76)
Signed-off-by: Diljit Singh <hey@djdev.me>
Restore the adopted-host Clock PM policy from candidate44.
Integration boots J775c with this change alone; restoring bus-
number preservation alone does not return as a trial, and
restoring the NVMe driver alone does not return.

The host leaves CLKREQ# pads and reference-clock gating in
firmware state. Removing L0s/L1 capability bits does not mask
PCIE_LINK_STATE_CLKPM. Disable it before endpoint enable and walk
the enumerated bus to retain the policy.

Adapted from Satya Benson candidate44 PCIe adoption changes.
Tested on J775c with Aura b6e6faf4 and candidate44 DTB; other
boards untested.

Signed-off-by: Satya Benson <satya@benson.earth>
Assisted-by: LLM
(cherry picked from commit ccdd14a)
Signed-off-by: Diljit Singh <hey@djdev.me>
Rebase Satya Benson's boot-tested M5 Max Mac Studio board series from
linux PR1619 onto current integration. Consolidate its incremental board
fixups and historical merge cleanups while retaining the original author,
copyright notices and compatibility contract.

Keep the one-die CPU/cache topology, board PCIe/N1/NVRAM/fan and USB/PD
wiring, installed-loader GPU paths/fallback, disabled MTP DART, three
ANE suppliers and omission of the desktop internal-panel DCP. Retain the
original disabled inventory and ANE trial wrapper without claiming new
hardware qualification.

Resolve the ANE binding against the current T8142/T8132 constraints:
retain the explicit T6050 backend/full-inventory distinction and known
0x210/0x220 platform types. Preserve K114c's active ATC2 guards in the
shared router definitions. Do not weaken the modern GPU binding; the
legacy-loader GPU warning gate remains visible.

The original PR1619 and its branch remain open and unchanged.
Source head: 0075a00.
Shared-router and Clock PM dependencies are separate preceding commits.

Based on the J775D board by Jeff Queisser and the single-die J716c work
by Erik Bourget; their foundations remain in integration ancestry.

Signed-off-by: Satya Benson <satya@benson.earth>
Assisted-by: LLM
Signed-off-by: Diljit Singh <hey@djdev.me>
The shared T6050 router declarations default their status to disabled. J714s and J716c previously enabled their board-specific mailbox and router definitions implicitly, which now inherit the disabled property. Explicitly enable the six existing board nodes to preserve their prior effective status.

Signed-off-by: Diljit Singh <hey@djdev.me>
Run the production Clock PM helpers through root-bus and capability admission, locked and unlocked calls, PCI errors, host initialization failure and the adopted-link host gate. Reject mutations that change the mask or remove the gate. Document the rebase and the outstanding loader and hardware qualification limits.

Signed-off-by: Diljit Singh <hey@djdev.me>
DjDeveloperr and others added 5 commits November 19, 2026 08:49
Resolve the staged board descriptions into t6050-j775c.dts, retaining symbolic references and the final device policy. Remove all 18 board staging sources, including the separate unqualified ANE trial wrapper. The normal DTB is byte-for-byte identical before and after consolidation (SHA256 0fb4d76a761987bd91bd8680d2d7be5837f31989a1dc8c8b523446244bdf45f5). No hardware is newly enabled. Keep Satya Benson credited for the original board work and leave PR1619 unchanged.

Signed-off-by: Diljit Singh <hey@djdev.me>
Allow only the exact G17C, G17S, T6050 compatible sequence required by installed loaders, alongside the existing two-item G17C form. Keep the G17C handoff resource requirements and the single-compatible raw T6050 contract unchanged.

Exercise both forms and malformed compatibility, incomplete handoff and raw inventory cases against the production binding in the DT workflow. Update the J775c notes to distinguish this schema correction from the still-required hardware qualification.

Signed-off-by: Diljit Singh <hey@djdev.me>
…6B123, 26C5035r)

The M5 Pro and Max firmware builds of macOS 27.2 (26B123) and 27.3 beta 1
(26C5035r) grow the power policy and the status config against 26A428, and
the 26C5035r build inserts one HW data word. Carrying those layouts needs
per-build InitData tables; the profile scheme had them only for 26A428.

Port the M5Layout subsystem from the wAP rebase onto the current tip:
- fw/variant.rs: the M5Layouts enum and the m5_layouts field, with the
  V26B123_M5 and V26C5035_M5 variants (V26C5035r acknowledged on a J716s
  under aura; 27.2 has not run on metal yet).
- fw/m5/initdata.rs: the M5Layout and M5StatusConfigMap/M5PolicyMap
  subsystems with the two new profiles (J714G17S26B123, J714G17S26C5035);
  the encoders take the build's layout; the policy and status-config maps
  relocate the build's fields in place (relayout_m5_policy); the M5Graph
  consts for the two builds and the J714_26B123/J714_26C5035 boards.
- initdata/m5.rs: the submission history reads through the status-config
  map; build_m5 lays the policy out for the build before the controller
  defaults run.

Const-graph rule learned on the way: a per-build Config override must be a
full literal, because a struct-update from the base would inherit the base's
build list, whose 26C5035r entry names the override.

Proof: drivers/gpu/drm/asahi/aurora.o builds for arm64 with the pinned
bindgen (rustc 1.96.0); the const assert blocks of the ported tables
evaluate during that build.
The 27.2 (26B123) and 27.3 beta 1 (26C5035r) builds of the M5 Pro and Max
get their own per-build configurations, naming the boards whose graphs
carry the builds' layouts (the previous commit's work). The 26C5035r
entropy, boot-filled ranges and TEXT digests were measured on two J714s
boots and one J716s boot under aura; the 27.2 records came from the 27.2
boots.
CONFIG_MAX_26C5035 named J714_26C5035, whose ..J714 base makes it the Pro
board (2 clusters, 20 cores): a real M5 Max (J716C, 4 clusters, 40 cores)
was refused at the probe after its firmware identified. Give the build its
own board (J716C on the M5_GRAPH_26C5035 graph) and name it.

Also from the review: drop the dead V26B123_M5/V26C5035_M5 variant consts
and the unread Variant::m5_layouts field (layout flows config.m5 ->
board.graph -> profile), and remove the comment artifacts in t6050.rs
(the pasted single-build comments before the multi-build lists and the
orphaned 26B123 doc above CONFIG_26C5035).
@joshuaswarren

Copy link
Copy Markdown
Contributor Author

Head correction on this PR: the branch head is 0d4abd4, not e97b6fb as my 11-18 comment said. 0d4abd4 is that rework plus the review fix "the M5 Max 27.3-beta1 build takes the J716C board" (J716C_26C5035 board record instead of the Pro match). Both checks (dt-checks, host-tests) were cancelled mid-run today at 17:48Z after 2h55m; I reran both at 17:58Z (runs 44548421453, 44548421412). No other changes were pushed. The open ask from RyanTheTide (27.2 G17C identity, reworked off #1173 onto the common26 layout) is covered by a6a3f97 + 83257af on this head.

@RyanTheTide

Copy link
Copy Markdown
Contributor

Thanks for the rework. Selecting by firmware build with its own board record (J716C_26C5035) is the right shape. Three things before review:

  1. Overlap: the rework now adds the 27.2 (26B123) G17S identity and J714 InitData (hw/t6050.rs, g17/fw/m5/initdata.rs). drm/asahi: t6050: identify the K114/K116 27.2 (26B8125) G17S firmware (on #1173) #1650 (27.2 G17S) and drm/asahi: t6050: identify the M5 Max's 27.2 (26B123) G17C firmware (on #1650) #2185 (27.2 G17C, on drm/asahi: t6050: identify the K114/K116 27.2 (26B8125) G17S firmware (on #1173) #1650) cover 27.2 in the same files. Please drop the 27.2 part and stack this on drm/asahi: t6050: identify the M5 Max's 27.2 (26B123) G17C firmware (on #1650) #2185, so it adds only the 27.3-beta1 (26C5035r) entries and J716C_26C5035.
  2. Scope: as on drm/apple: complete the 27.3 DCP method table, swap size and completion tag #1816, our pinned builds target 27.2, and admitting the 27.3 beta waits for a 27.3 row. Please keep this as a draft until then. It also needs a K114c 27.3 row at the new head, because the triangle/Hyprland run predates the rework.
  3. Base: the branch carries arm64: dts: apple: support M5 Max Mac Studio (J775c) #2102's eight commits, and CI was cancelled. After arm64: dts: apple: support M5 Max Mac Studio (J775c) #2102 merges, please rebase down to the drm/asahi commits and refresh the body, which still says "on drm/asahi: M5: InitData for the macOS 27.2 and 27.3 firmware (G17S bring-up on J716s) #1173".

Aurora asked for stable 27.2 only, matching the firmware pin. The 27.3-beta1 (26C5035r) scope moves intact to wAN/m5max-fw-273-held on this fork. Removed: the 26C5035r build entries in the M5 Pro and M5 Max firmware lists and their two per-build override configs in hw/t6050.rs; the V26C5035 layout variant and its captured-InitData note in g17/fw/variant.rs; the J714G17S26C5035 root profile, the 26C5035r graph, the J714_26C5035 and J716C_26C5035 boards, the 26C5035r layout, HW-data bands and forced-idle word, and the beta wording in doc comments in g17/fw/m5/initdata.rs. 268 deletions against 20 adjusted match arms and comments. Not built here; Aurora runs dt-checks and host-tests on push.
@joshuaswarren

Copy link
Copy Markdown
Contributor Author

Reworked to stable 27.2 only per your call (message 1757). The full 27.3-beta1 (26C5035r) scope is preserved on wAN/m5max-fw-273-held (0d4abd4) on this fork for the later beta-support PR.

Removed in 7617bd0 (268 deletions, 20 adjusted lines):

  • hw/t6050.rs: the 27.3 (26C5035r) build entries in the M5 Pro and M5 Max firmware lists, and the two per-build override configs CONFIG_26C5035 / CONFIG_MAX_26C5035; build-list comments now name 27.2 only.
  • g17/fw/variant.rs: the M5Layouts::V26C5035 variant and the captured-beta acknowledgment note in the M5Layouts docs.
  • g17/fw/m5/initdata.rs: the J714G17S26C5035 root profile and every match arm over it, the M5_GRAPH_26C5035 graph, the J714_26C5035 / J716C_26C5035 boards, the M5_LAYOUT_26C5035 layout with its HW-data bands and forced-idle word, the matching layout assertions, and beta wording in the 26B123 doc comments.

Kept: the full stable 27.2 (26B123) support — 26B123 build identification, layouts, configs and boards — unchanged.

Not built in this container; Aurora's dt-checks and host-tests run on this push. #1173 gets the same stable-only call on its side.

@RyanTheTide

Copy link
Copy Markdown
Contributor

Thanks for 7617bd0, and for keeping the 27.3-beta scope on its own branch for later.

With the beta removed, this PR and the #1173 → #1650 → #2185 chain now add the same thing: the 27.2 (26B123) M5 identities, layouts and boards in hw/t6050.rs and g17/fw/m5/initdata.rs. Only one of them can land. #2185 is CLEAN with green CI and J716c rows and carries #1173 and #1650 unchanged. Could you compare the two and say whether anything in this head is missing from #2185 (a board, a layout band, a config)? If nothing is, the simplest path is to close this one and add any difference on top of #2185; if something is, a short list here is enough and it can go in as a small PR on top of it.

@joshuaswarren

Copy link
Copy Markdown
Contributor Author

@RyanTheTide compared 7617bd0320c8 against 19e76b606ad9 (#2185) source-side before answering, normalizing whitespace/comments only. Checked pairwise and equal: the G17S 26B123 build record (sizes 0xa4000/0x184000, entropy and boot-filled ranges, text digest), the 26A428 G17S and G17C records, the J714 and J716C board payloads, the 21 non-firmware/non-board CONFIG fields, and the stable definitions M5_26B123_INITDATA_VERSION_WORD, ABI_ALLOCATION_SIZES_26B123_M5, M5_LAYOUT_26B123, M5_26B123_POLICY_BANDS, M5_26B123_POLICY, M5_26B123_POLICY_CONTROLLER_WORDS, M5_26B123_POLICY_CONTROLLER_WORDS_G17D, M5_26B123_STATUS_CONFIG_BANDS, M5_26B123_STATUS_CONFIG_INSERTED and M5_26B123_STATUS_CONFIG. #2185 differs structurally, not materially: it picks the graph and policy map from the identified firmware build (m5_layouts) instead of a per-build config override (CONFIG_26B123), so the Pro config is not duplicated; and it adds the G17C 26B123 identity this PR lacks. Nothing stable remains to port from this head.

One caveat before closing: #2185 at 19e76b606ad9 still carries the inherited G17S 26C5035r (27.3 beta 1) build record. Please confirm the beta scope (keep it there, or split it out to match the pinned-27.2 stance) — then we are content to close this PR in favour of #2185. The full 27.3-beta support stays preserved on our fork at wAN/m5max-fw-273-held (0d4abd4e9f83) for the later beta PR, so closing here loses nothing.

@RyanTheTide

Copy link
Copy Markdown
Contributor

Thanks for the careful comparison. It settles the overlap: everything stable in 7617bd0 is already in #2185, and #2185 also has the G17C 26B123 identity.

You're right about the caveat. #2185 at 19e76b6 still has the inherited G17S 26C5035r record (M5Layouts::V26C5035, J714G17S26C5035, M5_LAYOUT_26C5035), and that doesn't match the stable-27.2 scope we asked of this PR. We're checking how to split it out of that chain and will confirm here. Please keep this PR open until then. After that it can close in favour of #2185, and the beta support can come back later as its own PR from wAN/m5max-fw-273-held.

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

Reviewed 7617bd0 against #2185 (19e76b6).

I confirmed Joshua's comparison: nothing stable on this head is missing from #2185. This PR can't merge as it stands, for three reasons:

  1. drivers/gpu/drm/asahi/hw/t6050.rs:209: after 7617bd0 the G17C list has only the 27.0 (26A428) entry. So the title no longer holds: the M5 Max on the pinned 27.2 stub still doesn't probe with this PR. #2185 has that entry (hw/t6050.rs:214 there).
  2. The branch still carries the eight #2102 commits (583dd2c..f21ee13: acio routers, DROM placeholders, pcie-apple.c Clock PM, the J775c board, the G17C binding). #2102 is a draft, and those commits have to land through it, not here.
  3. The 26B123 G17S identity, layouts and boards duplicate #2185. Joshua checked them pairwise; the only difference is structural (CONFIG_26B123 override here, m5_layouts there).

Next step: none from Joshua for now. As Ryan asked, keep this open until the #2185 chain decides on the inherited 26C5035r record. Then close it in favour of #2185, and bring the 27.3-beta work back from wAN/m5max-fw-273-held as its own PR once there's a K114c 27.3 row.

Assisted-by: Claude Opus 5.5

@joshuaswarren

Copy link
Copy Markdown
Contributor Author

[Joshua's agent] Agreed on both. #1602 stays open until the G17S 26C5035r record is split out of #2185; once that lands we close this in favour of #2185 at its updated head, and any beta-27.3 work returns later as its own PR from wAN/m5max-fw-273-held. Nothing else is pending on this branch.

@RyanTheTide

Copy link
Copy Markdown
Contributor

@joshuaswarren, a tidy-up pass over the open PRs here. These of yours need something:

If any of these are no longer needed, closing them helps; otherwise a merge or rebase onto integration/aurora is usually all they need. Thanks!

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.

4 participants