Apple M2 Enablement For Linux Begins With Good Progress

Written by Michael Larabel in Apple on 28 June 2022 at 07:45 PM EDT. 14 Comments
APPLE
Hector Martin who has been leading the Asahi Linux effort for bringing up Linux on Apple Silicon recently received his new 2022 MacBook Pro 13-inch to begin porting Linux to Apple's new M2 SoC. While only started this week, he's already making significant progress. Fortunately, much of the existing M1-written Linux code can work for the M2 but some new drivers will need to be written before the new M2 Macs are fully usable on Linux.

Earlier this month Apple announced the M2 with new MacBook Air and MacBook Pro models. The Apple M2 can support up to 24GB of LPDDR5 memory, is an 8-core CPU with up to 10-core GPU, up to 18% faster CPU performance over the M1 and up to 35% faster GPU performance, and up to 50% greater memory bandwidth.


Hector Martin on Monday began his Linux M2 bring-up effort, including with a livestream of this reverse engineering / debugging / kernel hacking effort. Hector confirmed NVMe, USB, and SMC functionality are working for the M2 on the first day of the effort.


Hector Martin shows Linux booting on the Apple M2 in early form.


Unfortunately, the keyboard and trackpad with the new Apple M2 devices will require a new driver for support. Additionally, SPMI will need a new driver and the PCIe support needs a fusemap in the m1n1 code to initialize. There is also PCIe, PMU, Thunderbolt, DP Alt Mode, and other functionality not yet tackled.

There is also still the Apple Silicon graphics support that needs to be addressed as the elephant in the room. There is progress being made on that front including the first triangle milestone with a fully open driver, but still will be months before having a full-featured Gallium3D OpenGL driver, a DRM/KMS kernel driver suitable for upstreaming, etc. Obviously Vulkan support will also be a requirement for some users too before considering the hardware fully for daily use. The M1 graphics work continues and hopefully the M2 graphics won't present many major additional hurdles.

More details and his activity around the M2 Linux bring-up can be found via Twitter:

Those wanting to track the code progress can see the m1n1 changes via its GitHub repository. The Linux kernel changes meanwhile are being worked on via this Git branch. The current Asahi Linux porting progress for various Apple Mac systems for the M1 and M2 SoCs can be tracked via the Asahi Linux Wiki.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week