Skip to content

drm/apple: J716c external displays and display sleep on firmware 27.2 - #2187

Open
erikwb wants to merge 3 commits into
integration/aurorafrom
j716c/dcpext-27-2
Open

erikwb wants to merge 3 commits into
integration/aurorafrom
j716c/dcpext-27-2

Conversation

@erikwb

@erikwb erikwb commented Nov 18, 2026

Copy link
Copy Markdown
Contributor

Lets the M5 Max (J716c) drive external displays, including the paired 4K240 mode, and take part in a deep sleep on the macOS 27.2 (26B123) firmware.

Firmware 27.2 renumbered the IOMobileFramebufferAP methods (A4xx and A500 up by 50); the build-selected method tables already carry that for the table-driven calls. Three things still assumed 27.0 on the J716c's display engines. Together with the loader change in aura #282 (which gives the external engines the stub's apple,firmware-compat), this makes them work on a 27.2 stub. 27.0 sends exactly what it sent.

Change

  • Paired mode set (a mode too wide for one engine, run on two): its calls through dcp_peer_video_call_stream() named 27.0 IDs; the first one (set_display_device, A411) panicked both engines on 27.2. iomfb_v27_tag() translates an ID through the engine's table, with +50 for other A4xx IDs on 27.2.
  • Other literal IDs on the firmware 27 paths: the primary's paired mode set (A413) and power step (A484, on 27.2 another method, so the second engine never started), the paired background swap (A408), the sleep's power and A500 steps, the display stage calls and A442 now go through the same translation. The J714s's A407 swap form keeps its ID, and its diagnostic refuses a pair whose engines take different swap forms.
  • Display sleep transport: admitted on compat 27.0.0 only, so on 27.2 every deep sleep was refused ("display 0: no provider"). It now admits 27.2.0, whose endpoint transport is the 27.0 one.

The paired DSC hand-off calls (A360..A373) and A375 are sent unchanged; their 27.2 numbering is not known, and the paired 4K240 mode runs with them.

Testing

On a J716c (M5 Max, 128 GB) with an MSI MPG 322U X24 pair on a Thunderbolt 5 dock, one kernel (this branch with #1956, #1957, #2162, #2177 and #2185 on integration/aurora 59b02d5) and aura main plus #280, #281 and #282:

  • 27.2 stub: internal panel at 3456x2234@120 and both monitors at 3840x2160@240 (each a pair of engines), no display processor crash. A 30 s RTC deep sleep enters and resumes with all three displays back; the GPU (Vulkan coherency test) and the ANE (H17 add-128, 1000/1000) pass after the wake.
  • 27.0 stub: the same three displays at the same modes, and the same deep sleep resumes.
  • Before: on 27.2 every external engine panicked at its first call, and with that fixed, the paired mode's second engine stayed black.
  • Not tested: other T6050 boards (the sleep transport change is J716c-only; the ID translation is a no-op on 27.0 and on machines without a 27.2 table).

🤖 Generated with Claude Code

… build

The paired mode set (a mode too wide for one engine, run on two) sends
its IOMFB calls through dcp_peer_video_call_stream(), naming them by
their 27.0 IDs. Firmware 27.2 renumbered the IOMobileFramebufferAP
methods, and an ID the firmware does not know panics it: on a 27.2 stub
the paired prepare's set_display_device went out as A411 and crashed
both engines.

Translate each call's ID through the engine's build-selected table
(iomfb_v27_tag()): a method the tables name takes this build's ID, and
on 27.2 another A4xx ID (A449) moves up by 50 with the rest of
IOMobileFramebufferAP. Other IDs, and every ID on 27.0, are sent as
before.

Developed with Claude Code.

Signed-off-by: Erik Bourget <erik@ebourget.net>
Besides the paired calls, the firmware 27 paths name some calls by their
27.0 IDs: the primary's paired mode set (A413) and power step (A484), the
paired background swap (A408), the sleep's power and A500 steps, the
display stage calls and A442. On 27.2, which renumbered
IOMobileFramebufferAP, several of those IDs are other methods: the
paired mode's power step ran one and failed, and the second engine of a
4K240 mode never started.

Translate each of them through the engine's build-selected table
(iomfb_v27_tag()). The J714s's A407 swap keeps its ID, which only its
27.0 table names, and its diagnostic now refuses a pair whose engines
take different swap forms. 27.0 sends what it sent.

Developed with Claude Code.

Signed-off-by: Erik Bourget <erik@ebourget.net>
The J716c's display processors take part in a deep sleep through the
firmware 27 endpoint transport, which was admitted on a 27.0
compatibility build only. On a 27.2 stub no processor registered for the
sleep, and every deep sleep was refused ("display 0: no provider").

Admit 27.2.0 as well. Its endpoint transport is the 27.0 one, and the
IOMFB calls the sleep makes are sent with the build's IDs.

Developed with Claude Code.

Signed-off-by: Erik Bourget <erik@ebourget.net>
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