Repository navigation
drm/apple: take the zero VRR range fallback on 13.5 firmware too - #3611
Conversation
f61e041 to
dcc6c11
Compare
The 13.5 display firmware of the MacBook Pro 14-inch (2021) publishes both VRR range fields as zero for its internal ProMotion panel, the way the 26.6 desktop firmware does. The panel runs adaptive at up to 120 Hz, so take the same fallback there. The parser test now covers three firmware versions: 12.3 without the fallback, 13.5 and desktop 26.6 with it. Signed-off-by: Andreas Fernandez <andreas.fernandez@hotmail.com>
dcc6c11 to
fb3ad06
Compare
|
Merge readiness at
Areas: Updated by pr-readiness on pushes, edits, reviews and comments, and on a schedule. Rules: merge policy · labels. |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
Verdict: HOLD at fb3ad061
Blockers:
- Hosted
pull_requestCI workflows (Apple build and KUnit,Apple DRM KUnit,Host tests,pr-text) arecompleted/action_requiredawaiting maintainer workflow approval for this fork PR; onlypr-readinesshas executed atfb3ad061. - The PR notes a new J314s boot-time DCP firmware warning (
FBPropertyManager ... WARNING - type mismatchon a boolean property) seen on candidatec397c4d6f188that has not yet been isolated from this commit. Please confirm with an isolated boot offb3ad061on J314s whether that firmware warning is caused by this change or by another patch in the candidate tree.
Checked:
drivers/gpu/drm/apple/iomfb.c(dcp_modes_replace()),drivers/gpu/drm/apple/parser-test.c(parser_vrr_empty_range()),tools/testing/selftests/drivers/gpu/apple-dcp/rate.py, anddrivers/gpu/drm/apple/parser.c/dcp-refresh.honmain.- Verified
dcp_refresh_range()indcp-refresh.halready restricts the0/0fallback (24..rate) tointernal && dcp_refresh_is_promotion(rate)(internal ~120 Hz ProMotion modes), so 60 Hz internal 13.5 panels and external displays are unaffected.
Evidence
- Regarding the scope question in
Details: indrivers/gpu/drm/apple/parser.c(dcp_refresh_range()), the zero-range fallback only activates when!minimum && !maximum && internal && dcp_refresh_is_promotion(rate)(120 Hz/119.88 Hz), so keying onDCP_FIRMWARE_V_13_5will not enable VRR on 60 Hz 13.5 panels. - Workflow runs at
fb3ad061469f73132d739a8e3603fcef49708d29:pr-readiness(pull_request_target) succeeded;Apple build and KUnit,Apple DRM KUnit,Host tests, andpr-text(pull_request) arecompleted/action_required.
|
Isolated the firmware line on the J314s, all on main e6c7b03 built the same way. Main plus only fb3ad06 logs In every boot I've looked at, the line comes right after the panel DCP loads its Same picture on a MacBook Pro 16 M2 Max (main ea7aa36 against this commit): with the commit the panel comes up with |
There was a problem hiding this comment.
Verdict: MERGE at fb3ad061469f
Converts this App's earlier review at the same head to an approval under the 12-01 merge bar (better than before and doesn't break; block only on a shown failure). No code blocker was found in it. The merge gate (a row on one Mac at this head + fast CI) is tracked by pr-readiness, not held here.
Checked: - drivers/gpu/drm/apple/iomfb.c (dcp_modes_replace()), drivers/gpu/drm/apple/parser-test.c (parser_vrr_empty_range()), tools/testing/selftests/drivers/gpu/apple-dcp/rate.py, and drivers/gpu/drm/apple/parser.c / dcp-refresh.h on main.
- Verified
dcp_refresh_range()indcp-refresh.halready restricts the0/0fallback (24..rate) tointernal && dcp_refresh_is_promotion(rate)(internal ~120 Hz ProMotion modes), so 60 Hz internal 13.5 panels and external displays are unaffected.
Follow-ups (not blocking): fork CI approval; isolate J314s FBPropertyManager warning from candidate tree
|
Merging at |
…erialize timed updates Live testing on a 14-inch M3 Pro (J514S) showed that v14.7 PreferredTimingElements publishes zero VRR range placeholders (matching 13.5 firmware in #3611 and desktop 26.6), leaving best->vrr false unless ctx.zero_vrr_range_fallback is enabled. Enable zero_vrr_range_fallback for swap-stamping ProMotion boards, trust the parser's VRR admission and exact fractional min_vrr/max_vrr instead of forcing selected[0].vrr, clear min_vrr/max_vrr on the locked 60 Hz copy, and select timed vs untimed swaps in iomfb_v14_7_modeset() by refresh rate under v14->lock. Signed-off-by: Marcelo Alcantara <maralc@gmail.com>
…erialize timed updates Live testing on a 14-inch M3 Pro (J514S) showed that v14.7 PreferredTimingElements publishes zero VRR range placeholders (matching 13.5 firmware in #3611 and desktop 26.6), leaving best->vrr false unless ctx.zero_vrr_range_fallback is enabled. Enable zero_vrr_range_fallback for swap-stamping ProMotion boards, require best->vrr before splitting the 120 Hz mode so a parser-rejected VRR timing is never split or forced to advertise VRR, preserve the parser's exact min_vrr/max_vrr on the 120 Hz mode while clearing them on the locked 60 Hz copy, and select timed vs untimed swaps in iomfb_v14_7_modeset() by refresh rate under v14->lock. Signed-off-by: Marcelo Alcantara <maralc@gmail.com>
What: On the J314s (display firmware 13.5) the internal ProMotion panel publishes both VRR range fields as zero, so on main it comes up without VRR (
vrr:0on the first mode set). This takes the zero-range fallback, today scoped to desktop 26.6, on 13.5 as well; the panel then getsvrr:1and Hyprland lists it as VRR capable. Mostly a question about scope, see Details.Tested: J314s M1 Pro at fb3ad06 (candidate c397c4d6f188 on main ea7aa36): boots, the same failed units as plain main, panel mode set with
vrr:1; the parser test covers 12.3 without the fallback and 13.5 and desktop 26.6 with it.Risk: two-way door · Macs on 13.5 display firmware whose panel publishes a zero range (every 13.5 Mac if the zeros mean something else there).
Not yet: 13.5 Macs other than the J314s and an M2 Max. The
FBPropertyManager ... WARNING - type mismatchline the panel's DCP logs at boot with this commit is the firmware's own: plain main logs it too once the panel is powered back on, see the comment below.Details
9976639 scoped the fallback to desktop 26.6 because older panel paths may use a pair of zeros as an explicit fixed-refresh range. This commit widens a firmware-version condition, and a version is the wrong key if a pair of zeros means fixed refresh on some other 13.5 panel. I have one machine, so I'd rather hear how you want it decided than guess. The options I can see:
Since the first push the host tests failed on this change: the publication fixture in
rate.pydid not declareDCP_FIRMWARE_V_13_5. It does now; the driver change is the same.Evidence
vrr:0.vrr:1.Thanks!