Repository navigation
drm/apple: dcp-fabric: keep DP alt mode pipelines free of a second tunnel - #2034
Merged
Merged
Conversation
This was referenced Nov 16, 2026
…nnel On the J714s, dcpext0 and dcpext2 reach both USB-C ports for DP alt mode and for USB4 DP tunnels, dcpext1 has tunnel-only routes, and dcpext3 is the merged-mode peer. Three external displays fit: a DP alt mode display on the left-front port on dcpext0 or dcpext2, and a dock's two tunnels on the other two pipelines, one of them paired with dcpext3. A tunnel takes the free pipeline with the lowest CRTC index, dcpext0 before dcpext1. Once one tunnel sits on dcpext2 (it came while dcpext0 and dcpext1 were taken), the next one goes to dcpext0 even with dcpext1 free. For example, with a DP alt mode display on the left-front port and a dock on the right: left-front DP alt -> dcpext0, dock DP IN 0 -> dcpext1, dock DP IN 1 (4K240) -> dcpext2 + dcpext3 left-front display unplugged, dock DP IN 0 display re-plugged -> dock DP IN 0 -> dcpext0 left-front display plugged again: dcpext0 and dcpext2 drive tunnels, dcpext1 is idle, and the display waits for a free pipeline Once another pipeline a port reaches drives a display, have a tunnel take a tunnel-only route before one that can carry DP alt mode. A lone tunnel still takes the lowest pipeline, so a single dock display keeps its connector (DP-1), and ports without tunnel-only routes keep the CRTC order. Signed-off-by: Diljit Singh <hey@djdev.me>
DjDeveloperr
force-pushed
the
djdev/t6050-tunnel-only-first
branch
from
November 16, 2026 01:39
54905b5 to
36f2fbe
Compare
Contributor
Author
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.
Stacks on #1921. This branch is integration/aurora c0a2a75 with #1921's head (4c6a7b4) merged in unchanged, plus one commit. Only the last commit is new here. Once #1921 is merged with its commits unchanged (not squashed or rebased), the merge adds nothing. Review #1921 first.
Part of a set of seven J714s external-display PRs, measured together (table below): #2032 EDID defaults, #2033 atc tunnel open, #2034 tunnel-only first (stacks on #1921), #2035 merged-mode limit, #2036 tunnel clock, #2037 DPTX connection DP IN and #2038 DP IN bandwidth allocation (merge those two together). Suggested order: #1921, #2006, then the set in any order.
What
drm/apple: dcp-fabric: keep DP alt mode pipelines free of a second tunnelOn the J714s:
So three external displays fit: a DP alt mode display on dcpext0 or dcpext2, and a dock's two tunnels on the other two pipelines.
A tunnel takes the free pipeline with the lowest CRTC index, dcpext0 before dcpext1. So once one tunnel sits on dcpext2, the next one goes to dcpext0 even with dcpext1 free. For example, with a DP alt mode display on the left-front port and a dock on the right:
Once another pipeline the port reaches drives a display, a tunnel now takes a tunnel-only route before one that can carry DP alt mode. A lone tunnel still takes the lowest pipeline, so a single dock display keeps its connector. Ports without tunnel-only routes keep the CRTC order. New KUnit case
fabric_tunnel_only_first_testchecks the choice behind step 2. With dcpext2 driving a display, a tunnel gets dcpext1 and a DP alt mode display still finds dcpext0. A lone tunnel, and a port without tunnel-only routes, keep the CRTC order.Tested
In k3 to k6 the displays came up in the order DP alt mode first, then the two tunnels. Routing in every one of those boots: Dell → dcpext0 (DP-2), JTG on DP IN 0 → dcpext1 (DP-5), G81SF on DP IN 1 → dcpext2 (DP-3). That's what this commit chooses, and also what the CRTC order chose before it. The replug sequence above was not run on hardware. Only the routing choice is covered, by that KUnit case, and the case was not run either (the compile-proof config has no KUnit).
Compile: fedora-kcheck (cross build, M5 intg6 config, this branch with #1921): OK (vmlinux, Image and modules linked), 0 new warnings. checkpatch --strict: 0 errors; its one warning is the From/Signed-off-by name mismatch these commits always have.
Rig and kits
J714s (MacBook Pro 14", M5 Pro):
Each kit was integration/aurora 514ae1f + #2006 (which carries #1921) + #2018 as it was at 0521255 (its earlier PHY-side version) + the changes up to that row. Built natively on the M5, one-shot test boot, read-outs only (sysfs, debugfs, kernel log,
hyprctl monitors), then the default kernel restored and verified byte-identical. Since 514ae1f, integration/aurora has gained only #2022, which touches none of these files. The k6 tree is the tree of all seven PRs of this set merged on #2006, apart from a diagnostic log commit used only in the kits and theserialkeyword added to one log line in the EDID PR.The internal panel ran at 3024x1964@120 in every row. k6 was read at about 60 s and 150 s after boot, with the same result both times, and with no oops, WARN, DART fault or GPU fault.
¹ The left-front port's PD controller came up late in that boot and the Dell never entered DP alt mode. None of these changes touch that path.
² In k2b the JTG was on DP-1 and the compositor ran it at 1920x1080; from k3 on it is DP-5 at its native 1920x1280.
Neo rows needed
No. The new preference applies only to a port with
apple,tunnel-onlyroutes, which only the J714s DT has (with #1921/#2006).🤖 Generated with Claude Code