Skip to content

media: apple: isp: add firmware version 27.2 - #1831

Closed
RyanTheTide wants to merge 1 commit into
integration/aurorafrom
fw272/isp-v27_2-refmac
Closed

RyanTheTide wants to merge 1 commit into
integration/aurorafrom
fw272/isp-v27_2-refmac

Conversation

@RyanTheTide

@RyanTheTide RyanTheTide commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Part of the macOS 27.2 (build 26B123) firmware port for the M1/M2/M3 Macs (FW272).

The M1/M2/M3 image signal processors run the legacy-ABI ISP firmware with an apple,firmware-compat of <27 2 0>. The version parser had no arm for it, so it read back as UNKNOWN. UNKNOWN sorts below ISP_FIRMWARE_V_13_5, which would make isp_cmd_ch_set_file_load() fall back to the 12.x 32-bit set-file record; 27.2, like every firmware from 13.5 on, expects the 64-bit record.

This adds ISP_FIRMWARE_V_27_2 after ISP_FIRMWARE_V_26_6_2 (keeping it above 13.5), parses exactly <27 2 0>, prints 27.2, and leaves the firmware ISP_FW_ABI_LEGACY so the existing >= ISP_FIRMWARE_V_13_5 condition selects the 64-bit set-file format. 27.2 is a normal legacy firmware and is not caught by the J613-only 26.6.2 preview gate.

A KUnit case (apple-isp-fwver) covers the string and the enum ordering invariant that drives the set-file selection.

Tested: apple-isp-* KUnit green under arm64/QEMU (44 tests incl. the new isp_test_fw_version_27_2). No hardware yet runs 27.2 firmware on the Linux side; functional ISP qualification is gated on the per-Mac 27.2 stub.

Draft: part of the staged FW272 series; held until the 27.2 stub boots for hardware verification.

Assisted-by: LLM (Claude:Opus 5.5)

macOS 27.2 (build 26B123) ships the legacy-ABI ISP firmware on the
M1/M2/M3 image signal processors with an apple,firmware-compat of
<27 2 0>. The parser has no arm for it, so the version reads back as
UNKNOWN. UNKNOWN sorts below ISP_FIRMWARE_V_13_5, which makes
isp_cmd_ch_set_file_load() fall to the 12.x 32-bit set-file record;
27.2, like every firmware from 13.5 on, expects the 64-bit record.

Add ISP_FIRMWARE_V_27_2 after ISP_FIRMWARE_V_26_6_2 so it stays above
13.5, parse exactly <27 2 0>, and print "27.2". The firmware stays
ISP_FW_ABI_LEGACY and the existing >= ISP_FIRMWARE_V_13_5 condition then
selects the 64-bit set-file format. 27.2 is a normal legacy firmware and
is not caught by the J613-only 26.6.2 preview admission gate.

A KUnit case covers the string and the ordering invariant that drives
the set-file selection.

Assisted-by: LLM
Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
@satchlj

satchlj commented Nov 20, 2026

Copy link
Copy Markdown
Member

Claude Opus 5.5 on @satchlj's behalf.

Hardware result on MacBook Air M2 (J413, T8112), macOS 27.2 (26B123) stub: pass. ISP probe and capture work.

One-shot boot d7eca1c6 (2026-11-20). apple-isp.ko was built from this PR's head 0e89ab422379, applied in place of phellos's local 27.2 version arm (which matched only J413). It was loaded after boot, and its build ID matched that build. The loader carried aurora-silicon/aura#227's ISP heap admission.

  • No "unknown apple,firmware-version: 27.2.0" message. Before any 27.2 arm, the same machine printed that message and then failed the set-file load with -62. The sensor probed: ch 0: sensor 0x558, 6 configs, platform 0xe, setfile apple/isp_1921_01XX.dat.
  • /dev/video0 (apple-isp): 1280x720 NV12 streamed at 30.0 fps (90 frames, written to /dev/null; no image kept).
  • After one RTC s2idle cycle, 30 more frames streamed without error.

🤖 Generated with Claude Code

@satchlj

satchlj commented Nov 20, 2026

Copy link
Copy Markdown
Member

Claude Opus 5.5 on @satchlj's behalf: hardware run.

PR head Checked Result
0e89ab42 Camera with aura#227's isp.c: 1280x720 NV12, 150 frames at 30.0 fps Pass

Build: phellos (MacBook Air M2, J413, macOS 27.2 / 26B123 stub), default rebuilt 2026-11-20 = linux integration/aurora 458f759 + #2519 #1832 #1831 #2264 #2525 #2526 #2543 #2544 #2545; Aura main 0beafec9 + aurora-silicon/aura#377 aurora-silicon/aura#227 (isp.c only) aurora-silicon/aura#381 aurora-silicon/aura#382; U-Boot aurora-wip 37baf8f7 + aurora-silicon/u-boot#67; Stage 2 DTB t8112-j413-fw27.dtb. One-shot boot under the SoC watchdog, then made the default (two default boots healthy).

@RyanTheTide

Copy link
Copy Markdown
Contributor Author

Early note on this draft (no full review yet):

  1. drivers/media/platform/apple/isp/isp-drv.c:604: the parser accepts exactly <27 2 0>, so the next point release (27.2.1, 27.3) reads back as UNKNOWN and falls to the 12.x 32-bit set-file record again. The only thing the version drives here is the >= 13.5 set-file choice, so decide that from the version itself: treat any legacy-ABI apple,firmware-compat at or above 13.5 that has no specific quirk as the modern record, instead of adding one enum arm per firmware release.

Assisted-by: LLM (Claude:Opus 5.5)

@RyanTheTide

Copy link
Copy Markdown
Contributor Author

Superseded by 0872ebb in integration/aurora, which already parses firmware 27.2.0 for the ISP.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants