Repository navigation
soc: apple, arm64: dts, drm/apple: enable T6031 internal display on firmware 27.2 - #4049
Conversation
RyanTheTide
left a comment
There was a problem hiding this comment.
Review at 2b77bf3 (checked against the T6031 J516c/J514c 26.6.2 + 27.2 ADTs, names only). Nothing blocks; one point affects the Risk text.
- Medium: 14.7 T6031 changes too.
t6031-dcp.dtsinow gives the T6031 DCPapple,bw-scratch. On main that node has none, anddcp_get_bw_scratch_reg()has no fallback, so the T6031 DCP currently fails probe ("failed to find display registers") on every firmware. With this PR a 14.7 T6031 also gets past that point, and its firmware is handed that PTD slot. The slot is only shown working on 27.2. If 14.7 numbers that entry differently, bandwidth votes would land on another device's entry. Please either run a 14.7 J516c row (Naeem's 14.7 J516c could) or say in the Risk line that 14.7 T6031 changes. - Low:
apple,dcp.yamlstill exemptsapple,t6031-dcpfrom the requiredapple,bw-scratch. The driver can't probe without it, so dropping the exemption lets dtbs_check enforce it. - Low: the
gate_t6031comment still says only the 14.7 image is admitted. - Dj's concern (the UUID alone):
apple_pmp_start_check_layout()checks the handed-overptd-rangeagainstapple_pmp_offsets_t6031and the seeded ANS record (report@21) before starting the PMP, so a wrong offset or ANS index fails safe. report@10 (display) isn't seeded, so its only evidence is the boot where the PMP acked the display request. Theiop-pmp0-nubproperty set is the same in 26.6.2 and 27.2, thesoc-devicetable splits into the 35 records the comment states, and J514c matches J516c. - Error paths fine: the gate's UUID check frees its node reference,
bw-scratchindex 5 is inside the 6disp-Nwindows and bounds-checked, andafk_name_fallbackis firmware-27-only as on T6030. T6034 includes the dtsi but its node stays disabled, and the gate runs only onapple,t6031. T6030/T8122 untouched.git merge-treeis clean against #4037 (8660886) and main. - Before it leaves draft: the PR says non-120 Hz modes crash the 27.2 DCP, yet all 6 modes are advertised. A compositor that switches rate or turns on VRR will hit that, so limit the mode list to what works until it's fixed.
Admit the T6031 PMP firmware UUID from system firmware 27.2 (26B123), 5135AF78-00F4-3217-9DA3-B33A2B9CCA70, via pmp_uuid_alt on gate_t6031. Its PTD range map keeps PMP-STATUS (0x1), SOC-DEV-PS-REQ (0x200) and SOC-DEV-PS-ACK (0x208) at the 14.7 offsets and preserves ID-ordered soc-device entries (DISPINT at 0x10, ANS at 0x21). Add the corresponding KUnit test case gate_t6031_pmp_image_27_2 and update the gate_t6031 comments for both 14.x and 27.2 images. Signed-off-by: Acelogic <miguelc4600@gmail.com>
Drop the stale apple,t6031-dcp exemption from the apple,bw-scratch requirement now that t6031-dcp.dtsi wires the internal DCP bandwidth scratch slot. Signed-off-by: Acelogic <miguelc4600@gmail.com>
Add apple,bw-scratch = <&pmgr_dcp 0 5 0x1208> to the T6031 internal DCP node, pointing at PTD bandwidth request entry 577 in the disp-5 update window (0x2903d1208, matching T6030 internal slot layout and immediately preceding T6031 dcpext0 at 0x1210). Firmware 27.2 requires this dashboard slot to initialize the internal Liquid Retina XDR panel. Signed-off-by: Acelogic <miguelc4600@gmail.com>
…T6031 Firmware 27.2 on the T6031 internal DCP announces AFK infrastructure services on SYSTEM_ENDPOINT (ep:20) without EPIC identity properties, matching T6030 (#3768). Enable afk_name_fallback on apple_dcp_hw_t6031 so those services bind by announced name under DCP_FIRMWARE_V_27_0. Also set only_120hz_modes on apple_dcp_hw_t6031 and gate the only_120hz_modes check in dcp_mode_settable() on DCP_FIRMWARE_V_27_0, with a 14.7 non-regression check in parser_internal_v27_only_120hz. Switching away from the 120 Hz boot timing crashes firmware 27.2 DCP during ALPM/link teardown, while 14.7 fixed modes stay unaffected. Signed-off-by: Acelogic <miguelc4600@gmail.com>
2b77bf3 to
1ef7a8e
Compare
|
Merge readiness at
Areas: Updated by pr-readiness on pushes, edits, reviews and comments, and on a schedule. Rules: merge policy · labels. |
RyanTheTide
left a comment
There was a problem hiding this comment.
Approving at 1ef7a8e. All four review points are addressed: the t6031 bw-scratch schema exemption is gone; the Risk line now covers 14.7 T6031 probing past bw-scratch; the gate comments name both images; and only_120hz_modes is on T6031 with a new firmware-27 gate in dcp_mode_settable(), plus a KUnit case that 14.7 keeps every fixed rate. The T6050 profile is always firmware 27, so it is unaffected. Because #3693's paced rates key on only_120hz_modes plus firmware 27, T6031 will pick them up when that lands. Merge still needs the exact-head J516c boot row, and a 14.7 J516c row would settle the 0x1208 slot there.
|
Follow-up on 14.7 T6031 Verified against
So this PR is completely inert on 14.7 T6031 and only takes effect on firmware 27.2 T6031. |
What: Enable native internal display bringup on T6031 (M3 Max) Macs running macOS 27.2 (
26B123) firmware, paired with mergedaurora-silicon/aura#654(5c38202f1715):5135AF78-00F4-3217-9DA3-B33A2B9CCA70) viapmp_uuid_altongate_t6031indrivers/soc/apple/display-gate.c, update thegate_t6031comments for both 14.x and 27.2 images, and addgate_t6031_pmp_image_27_2indisplay-gate-test.c.apple,t6031-dcpexemption fromDocumentation/devicetree/bindings/display/apple,dcp.yamlsodtbs_checkenforcesapple,bw-scratchon T6031 internal DCP.apple,bw-scratch = <&pmgr_dcp 0 5 0x1208>;ondcp: dcp@386c00000inarch/arm64/boot/dts/apple/t6031-dcp.dtsi(PTD bandwidth request entry 577 indisp-5, immediately preceding T6031dcpext0at0x1210).apple_dcp_hw_t6031indrivers/gpu/drm/apple/dcp.c, enableafk_name_fallback = true(matching T6030 drm/apple: dcp: enable AFK init-prop name fallback on T6030 internal DCP #3768 soSYSTEM_ENDPOINTep:20services bind underDCP_FIRMWARE_V_27_0) andonly_120hz_modes = true, gatingonly_120hz_modesindrivers/gpu/drm/apple/iomfb.c(dcp_mode_settable()) onDCP_FIRMWARE_V_27_0so firmware 27.2 stays safely on its boot refresh rate while 14.7 fixed modes remain unaffected. Add the 14.7 non-regression check toparser_internal_v27_only_120hz(parser-test.c) and update theapple-dcpboot.pyhost stub.Tested:
1ef7a8e1b8fa7f6f910d28db313480a28d810f41(16-inch MacBook Pro, M3 Max,apple,j516c/apple,t6031, macOS 27.226B123stub, Aura Stage 11.0.0b19, Stage 21.0.0b19-7-g0e94e259fromaura#654,boot_id a0e305ba-f3f3-4e8c-b8bf-4f69269dcbfc,Linux 7.3.0-t6031-disp27+,ImageSHA-256da3c22f4d47e...,t6031-j516c.dtbSHA-256a6d1bfce52f4...,boot.binSHA-25631e6e9a76408...):apple-t6031-display: admitted PMP5135AF78-00F4-3217-9DA3-B33A2B9CCA70, copied 88 values from/chosen/asahi,t6031-pmponto/soc/pmp@290700000, completedpmp_report(report@10display +report@21storage).apple_pmp/apple-pmp-report:PMP firmware and endpoint ready,PMP started,PMP ready: PTD status 0x1 request 0x200010000 ack 0x200010400.apple-dcp:AFK[ep:20]: new service system on channel 1,AFK[ep:20]: new service powerlog-service on channel 3(0failed to extract init propserrors),Using Dashboard 2903d1208,DCP booted,Initialized apple 1.0.0 for display-subsystem on minor 1,set_digital_out_mode(color:1 timing:2) "3456x2160": 120->finished:8500,boot scanout retired by displayed swap 5,fb0: appledrmfb.modetest -M apple -c:eDP-1 connected,346x223 mm, 1 mode advertised (3456x2234 120.00 Hz, preferred/driver) — non-120 Hz fw-27 crash path closed./sys/class/backlight/apple-panel-bl: live brightness step verified (140 -> 220 -> 140,actual_brightnessmatches,max=500,bl_power=0, DCPbrightness_changedlogged).wld0) and Thunderbolt (thunderbolt0) up; 0 priority 0–3 display/PMP/DCP/AFK/DART kernel errors; 0 failed systemd units.apple-display-gate: 77/77 PASS (apple-display-gate-t603120/20 incl.gate_t6031_pmp_image_27_2,t60306/6,t812228/28,t60411/1,t6041-max14/14,t81328/8).dcp-display(drivers/gpu/drm/apple/tests/display.kunitconfig): 309/310 pass, 1 skip, 0 fail (all 24 suites PASS, incl.apple-display-parser48/48 with updatedparser_internal_v27_only_120hz).dcp-bw-scratch-window-tests.py,dcpext26-startup-tests.py,t6030-display-admission-tests.py,dcp14-panel-tests.py,dcp-ext-repower-tests.pyPASS;apple-dcpselftestsboot6/6 (incl.v27-panel-handoff) &edid4/4 PASS;scripts/checkpatch.pl --strict0 errors, 0 warnings, 0 checks across all 4 commits.Risk: two-way · T6031 (M3 Max) internal display and PMP handoff on firmware 27.2, plus 14.7 T6031 (wiring
apple,bw-scratch0x1208lets 14.7 T6031 probe pastdcp_get_bw_scratch_reg()wheremaincurrently refuses probe;only_120hz_modesandafk_name_fallbackare both gated onDCP_FIRMWARE_V_27_0so 14.7 fixed modes and AFK paths stay unchanged). T6030, T8122, T6034, T6050, and other SoCs are unchanged.Not yet:
0x1208on 14.7 (no 14.7 stub here).