Repository navigation
drm/apple: send firmware 27 swap timestamps in the firmware's timebase - #1404
Merged
DjDeveloperr merged 1 commit intoNov 10, 2026
Merged
Conversation
This was referenced Nov 10, 2026
RyanTheTide
reviewed
Nov 10, 2026
RyanTheTide
left a comment
Contributor
There was a problem hiding this comment.
The change is limited to the firmware-27 template instance: dcp_swap_time() and dcp_swap_prev_time() scale and clamp only under DCP_FW_H17(DCP_FW_VER) && DCP_FW_VER >= DCP_FW_VERSION(27, 0, 0). Other instances still pass the raw counter and the previous timestamp. That instance is used only by apple,t6050-dcp/apple,t6050-dcpext. No code changes needed.
It depends on firmware-27 code that exists only on its base, funkzy/t6050-gpu-on-integration (#1012). It can go in after that lands, retargeted to integration/aurora.
This was referenced Nov 10, 2026
Firmware 27 counts the continuous time of swap timestamps at 24 MHz, but on T6050 the ARM counter Linux reads runs at 1 GHz, so a raw counter value names a moment about 40 times as far from boot as now. The firmware accepts such a swap and holds it, and the commit times out. Without timestamps, the internal ProMotion panel presents at 60 Hz in its 120 Hz mode. On firmware 27, scale the counter to 24 MHz, and use the previous accepted swap's time only when it is at most a second old; after an idle period the firmware would otherwise pace from a stale time. The dual-pipe path records its submission time the same way. Other firmware is unchanged. On J716c the internal panel completes 119.5 swaps per second in its 120 Hz mode with timestamps on, against 60.0 without them. Developed with Claude Code. Signed-off-by: Erik Bourget <erik@ebourget.net>
DjDeveloperr
force-pushed
the
j716c/v27-swap-timebase
branch
from
November 10, 2026 09:11
01a88d7 to
7e32e38
Compare
DjDeveloperr
changed the base branch from
funkzy/t6050-gpu-on-integration
to
fix/m5-fbdev-argb-fw27
November 10, 2026 09:11
DjDeveloperr
changed the base branch from
fix/m5-fbdev-argb-fw27
to
funkzy/t6050-gpu-on-integration
November 10, 2026 10:21
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.
What this fixes
On T6050 the internal ProMotion panel either timed out its first present in the 120 Hz mode (with swap timestamps) or presented at 60 Hz in that mode (without them). Firmware 27 counts the continuous time of swap timestamps at 24 MHz, while the ARM counter runs at 1 GHz there, so a raw counter value named a moment about 40 times too far from boot and the firmware held the swap for it.
The change
On firmware 27, swap timestamps are the counter scaled to 24 MHz. The previous accepted swap's time is used only when it is at most a second old. The dual-pipe path records its submission time the same way. Other firmware versions are unchanged.
With this, the fixed-rate ProMotion timestamp policy on integration/aurora works on firmware 27, and #1270 drops its policy workaround.
Testing (J716c)
Created with Claude Opus 5.5 and Claude Fable 5.2 in T3 Code.