X
Tech

Linux on Apple's Arm silicon Macs? This crowdfunded project wants to give it a try

Project wants to create a polished Linux experience on Apple Silicon Macs.
Written by Liam Tung, Contributing Writer

A crowdfunded project has launched that aims to to port Linux to Apple's new Arm-based silicon Macs.

Hector Martin, a Tokyo-based IT security consultant by day and hacker by night, has kicked off what he is calling the Asahi Linux project

Martin's Asahi Linux project aims to create "a remix of Arch Linux ARM that is designed to include bleeding-edge M1 support and convenient installation instructions."

"Any Arch Linux users should feel right at home," Martin said. 

SEE: Hiring Kit: Computer Hardware Engineer (TechRepublic Premium)

Martin announced the crowdfunding project in December and officially launched the project this week after reaching the $4,000 per month target he wanted to begin serious work on the Linux port for Apple's M1 – the first release of Apple's Arm-based silicon system-on-chips (SoC) for Macs.  

The project is being developed in the open with contributions regularly pushed to GitHub

The Asahi project today also announced it had gained the help of Alyssa Rosenzweig, a developer who's been working on Panfrost, a free and open-source graphics stack for Arm Mali GPUs used in Android devices. Arm Mali GPUs have been "historical thorns in Linux's side, due to the closed nature of the official drivers," Rosenzweig explained

Apple's GPU, which is part of the M1 SoC, poses the same problem for the Asahi Linux project as Mali did for Linux, Rosenzweig says in a blogpost detailing the M1 GPU hurdles she's cleared to date.   

"This custom Apple GPU has neither public documentation nor open-source drivers. Some speculate it might descend from PowerVR GPUs, as used in older iPhones, while others believe the GPU to be completely custom," writes Rosenzweig. 

She's following the same processes she used to reverse engineer Mali GPUs for Panfrost, but has found there are "some macOSisms that need to be translated". 

"While the standard Linux/BSD system calls do exist on macOS, they are not used for graphics drivers. Instead, Apple's own IOKit framework is used for both kernel and userspace drivers, with the critical entry point of IOConnectCallMethod, an analogue of ioctl." 

According to Martin, the first target will be the M1 Mac Mini. 

"Apple allows booting unsigned/custom kernels on Apple Silicon macs without a jailbreak! This isn't a hack or an omission, but an actual feature that Apple built into these devices. That means that, unlike iOS devices, Apple does not intend to lock down what OS you can use on Macs (though they probably won't help with the development)," he argues.

Martin argues that reverse engineering for interoperability is protected by law in many countries. 

"As long as no code is taken from macOS in order to build the Linux support, the end result is completely legal to distribute and for end users to use, as it would not be a derivative work of macOS," he notes. 

SEE: Mac Mini (Late 2020) review: Apple's most affordable M1 Mac offers great value for money

Linux creator Linus Torvalds has previously said he would love to have a new M1 Mac but won't buy one because it doesn't run Linux and the key problem to porting Linux to Apple silicon is its closed GPU, which prevents anyone but Apple from developing drivers for the kernel to access the hardware. The GPU is critical for performance and graphics-heavy apps. 

"The main problem with the M1 for me is the GPU and other devices around it, because that's likely what would hold me off using it because it wouldn't have any Linux support unless Apple opens up," Torvalds recently told ZDNet's Steven J. Vaughan-Nichols

Editorial standards