Files
reims-vgpu/firmware
vintowareandClaude Opus 5.5 9c91714b60 🆕 Boot arm64 macOS under KVM, and check its boot there
macOS's kernel sets up each GIC redistributor with a pre-indexed store,
`str w9, [x8, #128]!`. Under KVM it traps with no instruction syndrome
(ISV=0) into KVM's in-kernel vGIC, which neither KVM nor QEMU's ISV=0
emulator can complete, so an arm64 guest on an arm64 Linux host panics
early in its boot. firmware/ambrosia/kvm.plist holds an Ambrosia
Kernel > Patch that writes the same values to the same two registers with
plain stores. Its four instructions are once in com.apple.kernel in each
VirtualMac2,1 kernelcache from 13.6 to 27.2.1, so it sets Expect to 1: a
kernel they leave stops at Ambrosia with a named error.

reims-ctl adds the patch to an arm64 VM's bundle where the VM runs on KVM,
after the VM's own patches; HVF and TCG bundles are unchanged.
`make config-bundle KVM=1` adds it to our configuration's bundle, and
check-boot.sh -k boots that bundle under KVM, with HVF's limits and
judgements and TCG's memfd RAM, refusing a bundle without the patch.

Booted on an M1 Pro under Fedora Asahi Remix 45: reims-ctl restored
macOS 27.2.1, its first boot made the Data volume, and after finish-eacs
it reached Setup Assistant and the desktop (docs/qemu.md). check-boot.sh
-k has not run, as its guest probes build on a Mac.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:06:12 -08:00
..