Repository navigation
accel/ane: t6050: admit the 27.2 26B8125 firmware the K boards ship - #3525
Conversation
The K114/K116 MacBook Pros run macOS 27.2 as build 26B8125. Its ANE image has the same name (h17_ane0_fw_hyperion_j71y), RTKit (3514.41.1), preload layout and environment sections as 26B123, but other code. The layout selects the 26B123 build, its code pin misses, and the engine is left off on every K board: H17 ANE: firmware 27.2 26B123, TEXT code sha256 8d552dcd... (not the code pin) H17 ANE: no loader hand-off (firmware TEXT pin); leaving the engine alone Give a build a second code pin for another build with its layout, and add the 26B8125 pin, computed from the image in the 26B8125 restore image with both loader-filled sections zeroed. A K114s reports the same digest for the TEXT iBoot loaded. Signed-off-by: Ryan Murray <[email protected]>
0a51200 to
e01e982
Compare
The last 12 bytes of the pin were mistyped, so a K114s still reported 'not the code pin' for the 26B8125 image. Generate the array from the digest (8d552dcd...e431a8). Signed-off-by: Ryan Murray <[email protected]>
|
K114s (14-inch M5 Pro, T6050, 27.2 26B8125) hardware row at head The first K114s row, at the first head, still refused the image. That head had 12 bytes of the pin array mistyped.
Once the engine has started, the module stays pinned (rmmod: in use), so the row ended with a plain reboot to the saved default. |
There was a problem hiding this comment.
Verdict: MERGE at 4af41e80
Blockers: None (wait for remaining queued KUnit CI jobs to finish; apple-build, host-tests, pr-text, KUnit ane-boot, and KUnit ane-pm are already green).
Checked:
- Audited all four touched files (
ane_fw_platform.h,ane_fw_cold.c,ane_fw_platform.c,ane_fw_platform_test.c):ane_fw_code_pinned()cleanly checks bothsoc->text_code_pinandsoc->text_code_pin_altwith NULL guards in bothane_fw_text_pinned()and theane_fw_handoff_present()boot log. - Verified
ane_t6050_code_26b8125matches the 32-byte SHA-256 digest8d552dcd27c4f539e89a285c5af893849ab8ae2e3efffed0aba8944e44e431a8byte-for-byte, leaving26B123,26A428, and all non-T6050 SoCs untouched. - Verified KUnit coverage in
ane_t6050_builds_test()(9/9local arm64 KUnit +KUnit ane-boot/KUnit ane-pmgreen in CI) and the exact-head4af41e80K114s (14" M5 Pro, T6050, 27.2 26B8125) hardware row ((code pin)accepted,/dev/accel/accel0bound, 5/5add64HWX runs4096/4096exact0 ulp, clean power-down/park, 0 new kernel errors, stock negative control confirmed).
Evidence
drivers/accel/ane/ane_fw_cold.c:ane_fw_text_pinned()already requiressoc->text_code_pin && soc->text_env[0].sizebefore hashing with zeroed env sections, andane_fw_code_pinned()accepts eithertext_code_pinortext_code_pin_alt.drivers/accel/ane/ane_fw_platform.c:.build_name = "27.2 26B123/26B8125",.text_code_pin_alt = ane_t6050_code_26b8125(32bytes verified against8d552dcd...e431a8).drivers/accel/ane/ane_fw_platform_test.c: assertsb27_2->text_code_pin_altis non-NULL and differs fromb27_2->text_code_pin, whileb27_0->text_code_pin_altremains NULL.
|
code-owner ping <@422957901716652033> / @DjDeveloperr: merge train at |
|
Merge readiness at
Areas: Updated by pr-readiness on pushes, edits, reviews and comments, and on a schedule. Rules: merge policy · labels. |
|
Merging under the 6-point rule (Ryan 09:29, permanent), at |
Problem
The K114/K116 MacBook Pros (T6050) run macOS 27.2 as build 26B8125. The driver knows the T6050 27.0 (26A428) and 27.2 (26B123) ANE images only. 26B8125's image has the same name (
h17_ane0_fw_hyperion_j71y), RTKit (3514.41.1), preload layout and loader-filled sections as 26B123, but its code is different. The layout selects the 26B123 entry, the code pin does not match, and the engine is left off on every K board. From the K114s, this boot:Change
ane_fw_platform.h: a build entry can name a second code pin,text_code_pin_alt, for another build with the same layout and environment sections.ane_fw_cold.c:ane_fw_code_pinned()accepts either pin, both in the check and in the per-boot log line.ane_fw_platform.c: the 26B8125 pin is added to the T6050 27.2 entry. I computed it fromFirmware/ane/h17_ane0_fw_hyperion_j71y.im4pin Apple's publicUniversalMac_27.2_26B8125_Restore.ipsw: the image laid out from its segments, the first 0xbc000 bytes,ce_env(0x4000 at 0xb4f80) andtext_env(0x20 at 0xb8f80) zeroed. That gives8d552dcd..., the digest the K114s reports for the TEXT iBoot loaded. The hash of the code before the first section matches too:87d1ae72....No layout or protocol change. Other SoCs are untouched.
Testing
kunit.py run --arch=arm64(qemu,DRM_ACCEL_ANE=y,DRM_ACCEL_ANE_FW_KUNIT_TEST=y):ane-fw-platform9/9 passed, includingane_t6050_builds_test.4af41e80(see the row comment): code pin, engine starts,/dev/accel/accel0, add64 exact over 5 runs, 0 new kernel errors.Risk
two-way · T6050 boards that run 26B8125 (the K114/K116). The engine now starts on these boards, where it used to be left off. 26B123 and 26A428 boards are unchanged.
Tested: K114s (T6050, macOS 27.2 26B8125 firmware) at 4af41e8: ANE code pin accepted, engine starts, /dev/accel/accel0 present, add64 exact over 5 runs, 0 new kernel errors.
Risk: two-way · T6050 machines on the 27.2 26B8125 ANE image only (other firmware keeps its existing pin).