Original title: The forgetful CPU (Linux on M4)
Article
A developer describes bringing Linux to Apple’s M4 Mac mini despite new barriers introduced by Secure Page Table Monitor, which complicated m1n1-based reverse engineering and hypervisor support. Early progress required disabling strict boot security, skipping initialization of locked GXF and RVBAR registers, and using serial debugging. A minimal device tree and early assembly prints revealed that Linux lacked identity mappings for UART MMIO after enabling the MMU, while a virtualization register write also caused crashes. Adding the mappings, correcting stdout-path, and avoiding that register write allowed Linux to reach a shell. Enabling secondary cores exposed an M4 flaw in which WFI and WFIT could erase architectural registers, contrary to the ARM64 specification. Replacing those instructions with NOPs enabled multicore booting, leading to upstream Linux support for a boot option that disables WFI idle and corresponding m1n1 changes. Current systems can boot M4, M4 Pro, M4 Max, and M5 machines with all cores, while peripheral reverse engineering and hypervisor support remain ongoing.
Commenters broaden the discussion to Apple’s closed hardware and software ecosystem, citing proprietary macOS trackpad and gesture protocols as a reason third-party accessories cannot match the Magic Trackpad without emulating a mouse. Some argue that Apple’s integrated control over computers, operating systems, accessories, and services creates a strong moat, while others criticize macOS as bloated and wish Apple supported more open hardware. Another commenter questions the decision to buy hardware from a company perceived as hostile to open platforms, and asks whether AI could help accelerate the reverse-engineering and Linux-support work.