Skip to content

drm/apple: 25G83: identify the board by the panel node, not the machine - #2416

Draft
RyanTheTide wants to merge 1 commit into
mainfrom
hack/drm-board-gates2-c
Draft

RyanTheTide wants to merge 1 commit into
mainfrom
hack/drm-board-gates2-c

Conversation

@RyanTheTide

@RyanTheTide RyanTheTide commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Problem

The T8122 25G83 (macOS 26.6.2 firmware) display paths asked the machine's root compatible which board they ran on:

  • iomfb_v26_6_board() (drivers/gpu/drm/apple/iomfb_v26_6.c ~931) picked the J613 or J615 record, which holds the panel size among other things, by of_machine_is_compatible("apple,j613"/"apple,j615"). This came from aa504d6 and c182567.
  • apple_t8122_25g83_board() (j613_dcp_activate.c), the board half of the 25G83 identity ("a J613, or a J615 with the experimental opt-in"), did the same.
  • dcp_ext26_admitted() (dcp.c ~5766, from 9649e59) and j613_external_gate() (j613_dcp_activate.c, from 2962e43) admitted the native 26.x protocol of the T8122 external processor on a J613 only.

Change

  • The records are keyed by panel. The device trees already name the panel: t8122-j613.dts and t8122-j615.dts put apple,panel-j613 or apple,panel-j615 under &dcp, and the 25G83 dts files include those. iomfb_v26_6_board() now selects the record by the DCP's panel child, as drm/apple: iomfb_v14_7: select the board record by the panel node, not the machine #2360 does for the 14.x records.
  • apple_t8122_25g83_board() reads the same node through the dcp alias. The J615 panel still needs asahi,j615-25g83-experimental.
  • The external processor's native protocol follows its firmware. Both external checks already require the owner's opt-in (/chosen/asahi,j613-25g83-dcpext), the loader's apple,j613-25g83-dcpext-handoff and apple,t8122-dcpext-firmware-ready markers, and the exact firmware version (26.6.2) and UUID. The gate also checks the DT shape of every supplier it enables. The machine check is dropped from both, with a comment saying what admits the path.

Why it is safe: nothing changes on a J613. A J615 changes only if it has the J615 25G83 opt-in, the external opt-in, and a loader that sets the external markers. Then it gets the native external path. Without all three, nothing changes. No other SoC reaches these paths, which all start from an apple,t8122-dcp/-dcpext node with the 25G83 profile.

Not changed: the coldplug scope check in apple_j613_25g83_coldplug() and its log line. They sit next to the J613 scope guards of drivers/soc/apple/j613-display.c and should move together with them.

Original work: Satya Benson (25G83 backend, J615 profile, native26 external path).

Testing

  • arm64 LLVM W=1 build of dcp.o, iomfb_v26_6.o and j613_dcp_activate.o: no new warnings. The two kernel-doc warnings in dcp.c:774 are on the base too.
  • Host tests j613-mux-order (all mutations), dcpext26-admission, dcpext26-changeset, pmp-native26 and display26 pass.
  • No KUnit suite covers these functions.

Still to run

No lab Mac is a J613/J615. On a J613 with the 25G83 DTB, dmesg | grep 25G83 shows "J613/25G83 display handoff accepted" and the panel starts, the same as on the base kernel. "no 25G83 board record for this panel" must not appear.

Hardware rows (combined test kernel, 2026-11-20)

This change was booted in a combined test kernel: integration/aurora 0abc2f3 plus the open gate-sweep drafts plus this and the related drafts (7.3.0-aurora-hk2/pwr1/hk3). It ran once on each lab Mac (M1 Pro J316s, M2 J413, J616s, Neo J700) and was compared against the production kernel on the same Mac, using the same silent row script:

  • kernel errors, failed units and SELinux denials;
  • microphone capture byte counts;
  • camera frame counts;
  • USB speeds;
  • panel brightness steps;
  • every retry/refusal message these drafts touch;
  • 2 s2idle cycles on M1 Pro, M2 and J616s.

M1 Pro, M2 and J616s matched production on every row, apart from the new counters and lines the drafts add. The Neo row found the old-DTB display regression that #2358's follow-up commit fixes.

This PR: No lab Mac reaches these paths (J613/J615); boot-clean regression rows only.

The 25G83 (macOS 26.6.2 firmware) display paths of the T8122 asked the
root compatible which board they ran on:

 - iomfb_v26_6_board() picked the J613 or J615 record (the panel size
   among others) by of_machine_is_compatible("apple,j613"/"apple,j615");
 - apple_t8122_25g83_board(), the board half of the 25G83 identity
   (a J613, or a J615 with the experimental opt-in), did the same;
 - dcp_ext26_admitted() and j613_external_gate() admitted the native
   26.x protocol on the T8122 external processor on a J613 only.

The records hold panel data, and the device trees already name the
panel: the J613 and J615 boards have a panel node under the DCP with
apple,panel-j613 or apple,panel-j615. Select the record by that panel,
as the 14.x records now are, and take the board half of the identity
from the same node, the J615 one still needing its opt-in.

The external processor's native protocol follows its firmware: both
external checks already require the owner's opt-in
(asahi,j613-25g83-dcpext), the loader's handoff and firmware-ready
markers, and the exact firmware version and UUID, and the gate checks
the DT shape of every supplier it enables. Drop the machine check from
both.

No change on a J613. A J615 with the J615 25G83 opt-in, the external
opt-in and a loader that sets the external markers now gets the native
external path too; without any of those nothing changes.

Fixes: aa504d6 ("drm: apple: add the J613 v26 display backend and guarded coldplug")
Fixes: c182567 ("drm/apple: add explicit experimental J615 25G83 profile")
Fixes: 9649e59 ("drm/apple: support retained J613 native26 external displays")
Fixes: 2962e43 ("drm/apple: acquire the J613 native26 external power suppliers")
Signed-off-by: Ryan Murray <[email protected]>
@RyanTheTide

Copy link
Copy Markdown
Contributor Author

No blockers.

I checked the following at d3c7e75:

  • iomfb_v26_6.c:922 and j613_dcp_activate.c:29 look for a child named panel under the DCP. t8122-j613.dts:323 and t8122-j615.dts:21 both name it panel and give it apple,panel-j613/-j615. Those nodes date from 781dcf1 and e01de0e, before the 25G83 profile (6f40687), so every 25G83 DTB has them, an older Stage 2 DTB included.
  • The dcp alias that of_find_node_by_path("dcp") resolves comes from t8122-dcp.dtsi:10.
  • Dropping the machine check from dcp_ext26_admitted() (dcp.c:5762) does not open the native external path anywhere new. dcpext is disabled in t8122-dcp.dtsi. Only j613_external_gate() enables it, and that runs only after apple_t8122_25g83_board() has passed (j613_dcp_activate.c:535 then 604). A J615 without its experimental opt-in therefore still never probes the external processor. J504 and J433/J434 have no dcpext alias, so the gate finds nothing on them.
  • On the in-tree DTs each panel selects the same record as the machine check did. So this is a refactor on J613 and J615, plus the J615 external opt-in that the description lists.

Nit: the coldplug scope check at j613_dcp_activate.c:515 and the log line at :619 still read the root compatible. That is already listed as a follow-up together with drivers/soc/apple/j613-display.c. Please put the follow-up number in the description so it doesn't get lost.

The draft can leave draft. The boot-clean rows on the four lab Macs show no change on boards that don't reach this path.

HW row: J613 with the 25G83 DTB on this head. "J613/25G83 display handoff accepted", panel lit at the native mode, no "no 25G83 board record for this panel", A/B against the base kernel, 0 AVC, 0 failed units, no new kernel errors. Owner-run, since no lab Mac is a J613.

Assisted-by: LLM (Claude:Opus 5.5)

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

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant