Repository navigation
t6041-j575c: USB-C displays on all four back ports - #1871
Open
7robertodantas wants to merge 1 commit into
Open
7robertodantas wants to merge 1 commit into
7robertodantas wants to merge 1 commit into
Conversation
The J575c drove a USB-C display on typec1 only: dcpext1 had a single route, and the tree deleted the display crossbars of ATC0, ATC2 and ATC3. macOS drives a display on each of its four back Type-C ports, and the J575c ADT has the four crossbars (atc0-3-dpxbar) and the external display processors dcpext0-3 at the J614c/J616c's addresses. iBoot starts dcpext2 here too (iop-dcpext2-nub), and aura's t6041_exts fills its firmware memory. Describe the ports as the J614c/J616c does, with the fourth one added: - dcpext1 gets a route to each of typec0-3 (t6041-j575c-usbc.dtsi), and atcphy0-3 are mode switches. The ATC0, ATC2 and ATC3 crossbars are no longer deleted. - dcpext2 is described with a route to each of typec0-3 (t6041-j575c-usbc-dcpext2.dtsi), as t6041-j616c-usbc-dcpext2.dtsi with the fourth route. With HDMI on dcpext0, two USB-C displays can then run at the same time, each on any back port. - The display gate's J575c USB-C chain enables the four crossbars and the four routes, and a new J575c chain enables dcpext2 with its four routes. The DT and the gate change together: dcpext1's crossbars must be enabled by the gate, and the old gate list names nodes the old tree deletes. Tested on a J575c with aura main (3351432), one USB-C to HDMI adapter (pin assignment D) at 2560x1440, and HDMI connected throughout: - dcpext1 drives typec0, typec1 and typec3, boot-attached and after replugs, on the first link training attempt. - dcpext2 (with dcpext1's routes removed in a test-only tree) drives typec0, typec1 and typec3 the same way. - typec2 is unreliable on both processors and in both plug orientations: link training fails with "DPTXPort: firmware reports link fault 22", and the driver retries. It came up after one or two retries twice, and kept failing for over a minute once, also when attached at boot. macOS 27.2.1 on the same machine does not drive a display on typec2 with this adapter either (both orientations, "no HDMI cable" on the monitor), while typec0, typec1 and typec3 work, so this is the port or the adapter, not this change. Its PHY tunables match the ADT. Not tested: two USB-C displays at once (one adapter). Assisted-by: LLM Signed-off-by: Roberto Dantas <7robertodantas@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.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.
Summary
The J575c (Mac Studio, M4 Max) drove a USB-C display on typec1 only (#1546): dcpext1 had a single route, and the
tree deleted the display crossbars of ATC0, ATC2 and ATC3. macOS drives a display on each of the four back Type-C
ports. The J575c ADT has the four crossbars (
atc0-3-dpxbar) and the external display processorsdcpext0-3at theJ614c/J616c's addresses, and iBoot starts dcpext2 here too (
iop-dcpext2-nub).This describes the ports as the J614c/J616c does (#1684), with the fourth port added:
t6041-j575c-usbc.dtsi), and atcphy0-3 are mode switches. The ATC0,ATC2 and ATC3 crossbars are no longer deleted.
t6041-j575c-usbc-dcpext2.dtsi), ast6041-j616c-usbc-dcpext2.dtsiwith the fourth route. With HDMI on dcpext0, two USB-C displays can run at the sametime, each on any back port.
dcpext2 with its four routes.
The DT and the gate change are one commit. dcpext1's crossbars must be enabled by the gate, and the old gate list
names nodes the old tree deletes, so either half alone would break typec1's display.
The loader side needs no change: aura's
t6041_extsfills dcpext2's firmware memory (aura f0adc275). The aurabuild in a Stage 2 has to be at least that recent; with an older one dcpext2 keeps its placeholder and the gate
leaves its chain off, and dcpext1 works as before.
dcpext3 (a third USB-C processor) can follow the same way once #1793 adds a fourth T6041 gate chain. This PR does
not depend on #1793, but both edit the T6041 chain table in
display-gate.c, so the second to merge may need asmall rebase.
Testing
J575c (macOS 27.2.1 installed). Kernel: integration/aurora 17a7c5f + this change, the same diff as the commit
here, which is rebased onto 5d112b1 without conflicts. aura main 3351432, U-Boot 250385f8. One USB-C to HDMI adapter (pin assignment D, two DP lanes beside USB3) to a 2560x1440 monitor. HDMI
to a second monitor (dcpext0) the whole time.
With a single display the first free processor, dcpext1, always takes it. To exercise dcpext2, a test-only tree
deleted dcpext1's routes and the connector endpoints that point at them, and enabled the four crossbars in the DT
(dcpext1's chain normally enables them). That tree is not part of this PR.
typec2: link training fails with
DPTXPort: firmware reports link fault 22 on target 0:2on both processors andin both plug orientations. The driver retries every ~4 s. It came up after one retry (dcpext1) and after two
(dcpext2). It kept failing for over a minute once, also when attached at boot, while the same adapter worked at once
on typec3. macOS 27.2.1 on the same machine does not drive a display on typec2 with this adapter either: the
monitor reports no HDMI signal, in both orientations, before and after login, while typec0, typec1 and typec3 work
there too. So this is the port or the adapter on this unit, not this change. typec2's PHY tunables also match its ADT
(the one typec2-specific
tunable_AUSPLL_COREword, 0x49, is copied correctly).Checks:
CHECK_DTBS=yfor t6041-j575c, t6041-j614c and t6041-j616c: no warnings. checkpatch: 0 errors.Not tested: two USB-C displays at once (one adapter); typec2 with another adapter or cable.
AI disclosure: an LLM (Claude) helped compare the ADT with the tree, write this change and its description, and run
the tests. I reviewed the result and ran every hardware step on my Mac Studio.
🤖 Generated with Claude Code