Asahi Linux

Last updated

Asahi Linux
AsahiLinux logo svg.svg
Arch Linux ARM-Asahi Linux Desktop English 07-2023.png
Screenshot of Arch Linux ARM of Asahi Linux with KDE Plasma 5
Developer
OS family Linux (Unix-like)
Working stateOfficial Stable (Fedora 39)
Source model Open source
Repository github.com/AsahiLinux
Platforms Apple silicon (AArch64)
Official website asahilinux.org

Asahi Linux is a project that ports the Linux kernel and related software to Apple silicon-powered Macs. The software design project was started and is led by Hector Martin. Work began in early 2021, a few months after Apple formally announced the transition to Apple silicon. An initial alpha release followed in 2022. The project has been made challenging by the lack of publicly available documentation of Apple's proprietary firmware. [2] [3]

Contents

History

Shortly after Apple announced their transition away from Intel x86 processors in late 2020, Linux creator Linus Torvalds expressed interest in Linux support for the Apple M1 Mac, but thought that the work to make this happen was too time-consuming for him to personally take on the necessary software development tasks. [4]

Martin announced the project in December 2020 and formally started work a month later, after securing crowd-sourced funding. Alyssa Rosenzweig, who developed the open-source graphics driver stack Panfrost, joined the project to help support the Apple silicon graphics processing unit (GPU). [5]

The developers quickly realised that just attempting to boot the Linux kernel compiled for Apple silicon's processor architecture (AArch64) would be challenging, as it involved working out the functionality of proprietary Apple code used in the boot process. The work was time-consuming and took most of the year, including submitting pull requests to the main Linux kernel developers to keep development in sync and avoid regressions. However, it subsequently led to a thorough and comprehensive explanation of the previously undocumented boot process, which Martin and others published on GitHub. [2] [6]

The project released an experimental alpha version of the Asahi Linux installer on March 18, 2022. The installer offers the choice of a desktop based on Arch Linux ARM (expected to change), [7] a minimal environment, or a basic UEFI environment for installing OpenBSD or alternate Linux distributions with support for Apple silicon via a bootable USB drive. [3] Despite being able to launch a UEFI shell, booting Microsoft Windows is not supported, and there are no plans to do so, as it would involve modifying the proprietary Windows kernel. [8] While other projects that are attempting to study a possible port of Windows to these systems specified challenging roadblocks related to Windows handling the proprietary Apple Interrupt Controller (AIC), and the 16K pages only found on the IOMMU.

Full support for all Apple silicon-supported Macs is not expected for another year or two following the first alpha release. [9] In July 2022, the Asahi Linux team released an update with support for the M1 Ultra, Mac Studio, and early initial support for the M2 MacBook Pro. [10]

In August 2023, it was announced that Asahi was partnering with the Fedora Project to release the Fedora Asahi Remix, which would supersede the original Arch-based distribution as Asahi's flagship OS. [11] The effort began in late 2021, and is an upstream-first project.

On October 21, 2023, Asahi updated the front page to direct users to Fedora Asahi Remix, posted on official Mastodon account. At that time, Fedora Asahi Remix was at Beta release. [12]

On December 19, 2023, the first official stable release of Fedora Asahi Remix was announced. [13]

Hardware and driver support

Asahi Linux is currently considered alpha software. It has a display for a graphical user interface and has early support for graphics acceleration, with initial OpenGL support being implemented for all GPUs across Apple's M-series chips. While initially using the Panfrost driver implementation, the Asahi Linux Project also made use of Gallium-3D and Rust based APIs for driver development. Vulkan and OpenCL support, as of Early-Mid 2023, are still being worked on. [14]

On June 6, 2023, OpenGL support was further expanded when support for OpenGL ES 3.0 and OpenGL 3.1 was released, and once more on August 22 when a fully-compliant driver for OpenGL ES 3.1 was released, introducing support for compute shaders and atomics. [15] [16] On February 14, 2024, OpenGL support was expanded to full conformant OpenGL 4.6 and OpenGL ES 3.2. This allowed workloads such as Blender, Ryujinx, and Citra to directly run on Asahi Linux. [17]

This driver is currently the only fully-compliant graphics driver for any widespread graphics standard. The process has involved creating device drivers for Apple silicon's proprietary GPU from scratch due to the lack of documentation. [18] [19] [14] HDMI video output is only supported on the Apple silicon Mac mini, and there is no support for Thunderbolt video output on Apple Silicon MacBooks and iMacs [18] , although external displays can be used via DisplayLink docks.

The Asahi Linux kernel has been configured with support for 16  kB pages, which may result in some problems with existing software. This was ultimately, and initially, done to address the Apple GPU only supporting 16k page outputs, but eventually, support for 4k pages was added in March 2023 to the GPU driver, which was mentioned in a blog post regarding explicit sync by Asahi Lina. [20] [21] Despite this, the operating system's kernel is still 16kB pages, and programs that were to expect 4k pages, or have improper/missing support for 16kB pages, will still experience problems with alignment when being mapped to memory. [22] Marcan stated that the page sizes set by Linux were global, and that there is not a native mechanism in place to have individual page sizes. [23]

Reception

The project has been well received. A review in The Register said that it ran surprisingly well for alpha software that is still in development. [19] Similarly, a review in Ars Technica was impressed by the amount of hardware that was already supported early in the project lifecycle. [9]

See also

Notes

  1. A pseudonymous developer only known by their VTuber identity.

Related Research Articles

<span class="mw-page-title-main">OpenGL</span> Cross-platform graphics API

OpenGL is a cross-language, cross-platform application programming interface (API) for rendering 2D and 3D vector graphics. The API is typically used to interact with a graphics processing unit (GPU), to achieve hardware-accelerated rendering.

Darwin is the core Unix operating system of macOS, iOS, watchOS, tvOS, iPadOS, visionOS, and bridgeOS. It previously existed as an independent open-source operating system, first released by Apple Inc. in 2000. It is composed of code derived from NeXTSTEP, FreeBSD, other BSD operating systems, Mach, and other free software projects' code, as well as code developed by Apple.

Direct3D and OpenGL are both application programming interfaces (APIs) that can be used in applications to render 2D and 3D computer graphics. As of 2005, graphics processing units (GPUs) almost always implement one version of both of these APIs. Examples include: DirectX 9 and OpenGL 2 circa 2004; DirectX 10 and OpenGL 3 circa 2008; and most recently, DirectX 11 and OpenGL 4 circa 2011. GPUs that support more recent versions of the standards are backwards compatible with applications that use the older standards; for example, one can run older DirectX 9 games on a more recent DirectX 11-certified GPU.

<span class="mw-page-title-main">OpenGL ES</span> Subset of the OpenGL API for embedded systems

OpenGL for Embedded Systems is a subset of the OpenGL computer graphics rendering application programming interface (API) for rendering 2D and 3D computer graphics such as those used by video games, typically hardware-accelerated using a graphics processing unit (GPU). It is designed for embedded systems like smartphones, tablet computers, video game consoles and PDAs. OpenGL ES is the "most widely deployed 3D graphics API in history".

Mesa, also called Mesa3D and The Mesa 3D Graphics Library, is an open source implementation of OpenGL, Vulkan, and other graphics API specifications. Mesa translates these specifications to vendor-specific graphics hardware drivers.

<span class="mw-page-title-main">Free and open-source graphics device driver</span> Software that controls computer-graphics hardware

A free and open-source graphics device driver is a software stack which controls computer-graphics hardware and supports graphics-rendering application programming interfaces (APIs) and is released under a free and open-source software license. Graphics device drivers are written for specific hardware to work within a specific operating system kernel and to support a range of APIs used by applications to access the graphics hardware. They may also control output to the display if the display driver is part of the graphics hardware. Most free and open-source graphics device drivers are developed by the Mesa project. The driver is made up of a compiler, a rendering API, and software which manages access to the graphics hardware.

<span class="mw-page-title-main">Hackintosh</span> Non-Apple computer running macOS

A Hackintosh is a computer that runs Apple's Macintosh operating system macOS on computer hardware that is not authorized for the purpose by Apple. This can also include running Macintosh software on hardware it is not originally authorized for. Benefits of "Hackintoshing" can include cost, ease of repair and piecemeal upgrade, and freedom to use customized choices of components that are not available in the branded Apple products. macOS can also be run on several non-Apple virtualization platforms, although such systems are not usually described as Hackintoshes. Hackintosh laptops are sometimes referred to as "Hackbooks".

<span class="mw-page-title-main">Apple–Intel architecture</span> Unofficial name used for Macintosh models that use Intel x86 processors

The Apple–Intel architecture, or Mactel, is an unofficial name used for Macintosh personal computers developed and manufactured by Apple Inc. that use Intel x86 processors, rather than the PowerPC and Motorola 68000 ("68k") series processors used in their predecessors or the ARM-based Apple silicon SoCs used in their successors. As Apple changed the architecture of its products, they changed the firmware from the Open Firmware used on PowerPC-based Macs to the Intel-designed Extensible Firmware Interface (EFI). With the change in processor architecture to x86, Macs gained the ability to boot into x86-native operating systems, while Intel VT-x brought near-native virtualization with macOS as the host OS.

<span class="mw-page-title-main">Boot Camp (software)</span> Built-in macOS software to natively install Microsoft Windows on a Mac.

Boot Camp Assistant is a multi boot utility included with Apple Inc.'s macOS that assists users in installing Microsoft Windows operating systems on Intel-based Macintosh computers. The utility guides users through non-destructive disk partitioning of their hard disk drive or solid-state drive and installation of Windows device drivers for the Apple hardware. The utility also installs a Windows Control Panel applet for selecting the default boot operating system.

nouveau (software) Open source software driver for Nvidia GPU

nouveau is a free and open-source graphics device driver for Nvidia video cards and the Tegra family of SoCs written by independent software engineers, with minor help from Nvidia employees.

<span class="mw-page-title-main">OpenCL</span> Open standard for programming heterogenous computing systems, such as CPUs or GPUs

OpenCL is a framework for writing programs that execute across heterogeneous platforms consisting of central processing units (CPUs), graphics processing units (GPUs), digital signal processors (DSPs), field-programmable gate arrays (FPGAs) and other processors or hardware accelerators. OpenCL specifies programming languages for programming these devices and application programming interfaces (APIs) to control the platform and execute programs on the compute devices. OpenCL provides a standard interface for parallel computing using task- and data-based parallelism.

Nvidia Optimus is a computer GPU switching technology created by Nvidia which, depending on the resource load generated by client software applications, will seamlessly switch between two graphics adapters within a computer system in order to provide either maximum performance or minimum power draw from the system's graphics rendering hardware.

<span class="mw-page-title-main">Radeon HD 7000 series</span> Series of video cards

The Radeon HD 7000 series, codenamed "Southern Islands", is a family of GPUs developed by AMD, and manufactured on TSMC's 28 nm process.

<span class="mw-page-title-main">Radeon 300 series</span> Series of video cards

The Radeon 300 series is a series of graphics processors developed by AMD. All of the GPUs of the series are produced in 28 nm format and use the Graphics Core Next (GCN) micro-architecture.

Vulkan is a low-level, low-overhead cross-platform API and open standard for 3D graphics and computing. It was intended to address the shortcomings of OpenGL, and allow developers more control over the GPU. It is designed to support a wide variety of GPUs, CPUs and operating systems, it is also designed to work with modern multi-core CPUs.

<span class="mw-page-title-main">ROCm</span> Parallel computing platform: GPGPU libraries and application programming interface

ROCm is an Advanced Micro Devices (AMD) software stack for graphics processing unit (GPU) programming. ROCm spans several domains: general-purpose computing on graphics processing units (GPGPU), high performance computing (HPC), heterogeneous computing. It offers several programming models: HIP, OpenMP/Message Passing Interface (MPI), and OpenCL.

<span class="mw-page-title-main">Apple M1</span> Series of systems-on-a-chip designed by Apple Inc.

Apple M1 is a series of ARM-based system-on-a-chip (SoC) designed by Apple Inc. as a central processing unit (CPU) and graphics processing unit (GPU) for its Mac desktops and notebooks, and the iPad Pro and iPad Air tablets. The M1 chip initiated Apple's third change to the instruction set architecture used by Macintosh computers, switching from Intel to Apple silicon 14 years after they were switched from PowerPC to Intel, and 26 years after the transition from the original Motorola 68000 series to PowerPC. At the time of introduction in 2020, Apple said that the M1 had the world's fastest CPU core "in low power silicon" and the world's best CPU performance per watt. Its successor, Apple M2, was announced on June 6, 2022, at Worldwide Developers Conference (WWDC).

<span class="mw-page-title-main">Alyssa Rosenzweig</span> Software developer

Alyssa Rosenzweig is a software developer and software freedom activist known for her work on free software graphics drivers.

Hector Martin Cantero, also known as marcan, is a Spanish security hacker known for hacking multiple PlayStation generations, the Wii and other devices. Martin is lead developer on the Asahi Linux project.

The Linux kernel can run on a variety of devices made by Apple, including devices where the unlocking of the bootloader is not possible with an official procedure, such as iPhones and iPads.

References

  1. "About Asahi Linux". Archived from the original on April 5, 2023. Retrieved May 4, 2023.
  2. 1 2 Sharma, Mayank (March 15, 2021). "Porting Linux to Apple M1 Macs is proving trickier than previously imagined". TechRadar . Archived from the original on March 21, 2022. Retrieved March 23, 2021.
  3. 1 2 Martin, Hector. "The first Asahi Linux Alpha Release is here! – Asahi Linux". asahilinux.org. Archived from the original on March 20, 2022. Retrieved March 20, 2022.
  4. "Linus Torvalds would like to use an M1 Mac for Linux, but ..." ZDNet. November 24, 2020. Archived from the original on April 1, 2022. Retrieved April 5, 2022.
  5. Tung, Liam (January 8, 2021). "Linux on Apple's Arm silicon Macs? This crowdfunded project wants to give it a try". ZDnet. Archived from the original on January 20, 2021. Retrieved May 31, 2021.
  6. Calligeros, James. "Apple Silicon Subsystems - Platform Initialisation and Boot". GitHub. Archived from the original on June 9, 2022. Retrieved August 1, 2022.
  7. "Hector Martin (@marcan@treehouse.systems)". Treehouse Mastodon. March 5, 2023. Retrieved March 28, 2023.
  8. "Windows support?". Asahi Linux GitHub. May 21, 2021. Archived from the original on April 5, 2022. Retrieved April 5, 2022.
  9. 1 2 "Asahi Linux is reverse-engineering support for Apple Silicon, including M1 Ultra". Ars Technica. March 25, 2022. Archived from the original on April 5, 2022. Retrieved April 5, 2022.
  10. Cunningham, Andrew (July 18, 2022). "Linux distro for Apple silicon Macs is already up and running on the brand-new M2". Ars Technica. Archived from the original on July 19, 2022. Retrieved July 20, 2022.
  11. Proven, Liam (August 7, 2023). "Asahi Linux project hooks up with Fedora: Remix that's not a remix coming soon". The Register. Retrieved August 7, 2023.
  12. "We've updated our front page to direct new users to Fedora Asahi!". Asahi Linux Official Mastodon Account. October 21, 2023.
  13. "We've updated our front page to direct new users to Fedora Asahi!". Asahi Linux Official Webpage. December 19, 2023.
  14. 1 2 Purdy, Kevin (December 7, 2022). "Four-person dev team gets Apple's M-series GPU working in Linux". Ars Technica. Retrieved December 8, 2022.
  15. "OpenGL 3.1 on Asahi Linux". rosenzweig.io. Retrieved October 13, 2023.
  16. "The first conformant M1 GPU driver". rosenzweig.io. Retrieved October 13, 2023.
  17. "Conformant OpenGL 4.6 on the M1". rosenzweig.io. Retrieved February 22, 2024.
  18. 1 2 Crume, Jacob (March 21, 2022). "Asahi Linux Distro Improves Apple M1 Support With First Alpha Release". It's FOSS. Archived from the original on March 21, 2022. Retrieved April 5, 2022.
  19. 1 2 "We take Asahi Linux alpha for a spin on an M1 Mac Mini". The Register. March 22, 2022. Archived from the original on April 5, 2022. Retrieved April 5, 2022.
  20. "Progress Report: September 2021 - Asahi Linux". asahilinux.org. Retrieved August 11, 2023.
  21. "Paving the Road to Vulkan on Asahi Linux - Asahi Linux". asahilinux.org. Retrieved August 11, 2023.
  22. "Broken Software". GitHub. Retrieved September 29, 2023.
  23. "Linux does support mixed page sizes (that's how huge pages work) and the page si... | Hacker News". news.ycombinator.com. Retrieved September 29, 2023.