Skip to content

Add aarch64 to the base Linux kernel package - #824

Closed
emirb wants to merge 3 commits into
masterfrom
arm/linux-omarchy-aarch64
Closed

emirb wants to merge 3 commits into
masterfrom
arm/linux-omarchy-aarch64

Conversation

@emirb

@emirb emirb commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Makes linux-omarchy build for aarch64 from the same recipe as x86_64. The x86_64 build is unchanged.

What changes

  • arch= gains aarch64, with its own config.aarch64 next to config.x86_64.
  • The package installs the raw EFI-stub Image as vmlinuz on arm64. make image_name gives the gzip Image.gz there, which neither UEFI nor systemd-stub can start; Arch Linux ARM ships the raw image for the same reason.
  • The package installs the arm64 device trees in /usr/lib/modules/<version>/dtbs/<vendor>/, where linux-aurora already puts the Apple ones. Snapdragon laptops and most other arm64 boards boot from a device tree. Next to the modules they always match the kernel they were built with, stay off the ESP, and do not collide with the trees Arch Linux ARM's linux-aarch64 owns under /boot/dtbs, so both kernels can be installed side by side.
  • The device trees are built with symbols (dtc -@), as Arch Linux ARM does, so overlays can be applied to them. The flag is set in the environment, not on the make command line, so the kernel's own dtc flags still apply.
  • The headers package maps aarch64 to the kernel's arm64 directory.

The config

config.aarch64 is derived from config.x86_64 for 7.2.8: every option that exists on arm64 keeps its x86 value. 9,288 options are shared and 174 differ, mostly options that need x86, ACPI features or x86-only drivers.

Ten arm64-only options are switched on beyond that. None exists in config.x86_64, and all ten resolve unchanged through olddefconfig in the patched 7.2.8 tree:

  • Hardware video decoding on Snapdragon X: VIDEO_QCOM_IRIS, and SM_VIDEOCC_8550, the video clock controller the X1 Elite device tree binds to. Arch Linux ARM's kernel builds neither, so video is decoded on the CPU there.
  • X2 Elite (Glymur) SoC support: CLK_GLYMUR_GCC, CLK_GLYMUR_TCSRCC, PINCTRL_GLYMUR and INTERCONNECT_QCOM_GLYMUR built in, CLK_GLYMUR_DISPCC, CLK_GLYMUR_GPUCC, CLK_GLYMUR_VIDEOCC and PHY_QCOM_M31_EUSB as modules. The split follows the X1 Elite options.

Tested

  • The first commit built natively as linux-omarchy 7.2.8-2 and linux-omarchy-headers for aarch64: 62 minutes on 32 AmpereOne cores from an empty compiler cache, 10 minutes with a warm ccache.
  • An aarch64 Omarchy ISO with that kernel installed and booted under QEMU with KVM on Apple Silicon: the installed system reports 7.2.8-2-omarchy, state running, no failed units.
  • The device-tree build and install were rehearsed against the patched 7.2.8 source with this config, outside makepkg: 1,499 device trees and 63 overlays across 14 vendors, 125 MB installed, with no dtc warnings. They include the Yoga Slim 7x, ThinkPad T14s, Dell Inspiron 7441 and the X2 Elite reference boards.
  • Not tested: the package built with the config and device-tree commits (this PR's run is the first), real arm64 hardware, and the BORE variant, which this PR does not touch.

Open questions before this can merge

  • Whether the aarch64 job fits the build workflow's 180-minute limit on the 4-core ubuntu-24.04-arm runner is not known yet. The native build above took 62 minutes on 32 AmpereOne cores from an empty cache. If it does not fit, arm64 kernel builds need a larger arm64 runner, a compiler cache or a cross build, in the publish workflow as well.
  • config.aarch64 has to follow config.x86_64 on every kernel update. The tooling that regenerates it is not part of this PR.
  • Nothing reads the new device-tree location yet. The Dragon installer and runtime take Snapdragon device trees from /boot/dtbs/qcom, which linux-aarch64 populates, and the installer still selects linux-aarch64 by name. Both need a follow-up change before a Snapdragon machine can boot this kernel.
  • X2 Elite laptops are not covered by this alone: 7.2.8 carries device trees for the Glymur and Mahua reference boards only.

emirb added 3 commits October 7, 2026 01:02
The recipe builds for aarch64 as well as x86_64: its own config.aarch64,
the arm64 header directory in the headers package, and the raw EFI-stub
Image as vmlinuz, because arm64's image_name is the gzip Image.gz, which
neither UEFI nor systemd-stub can start.

config.aarch64 is derived from config.x86_64 for 7.2.8: every option that
exists on arm64 keeps its x86 value (9288 shared options, 174 differ).
The x86_64 build is unchanged.
Hardware video decoding on Snapdragon X needs the Iris driver and, for the
X1 Elite, the SM8550 video clock controller its device tree binds to. Both
were off, so video was decoded on the CPU.

The X2 Elite (Glymur) clock controllers, pin controller, interconnect and
M31 eUSB2 PHY were off as well. They follow the X1 Elite choices: global
clocks, TCSR, pinctrl and interconnect built in, the rest as modules.

All ten options resolve unchanged through olddefconfig in the patched
7.2.8 tree, and none exists in config.x86_64.
Snapdragon laptops and most other arm64 boards boot from a device tree, and
the package shipped none. Install them next to the modules, in
/usr/lib/modules/<version>/dtbs/<vendor>/, as linux-aurora already does for
Apple Silicon: they always match the kernel they were built with, stay off
the ESP, and do not collide with the trees another installed kernel owns
under /boot/dtbs.

Build them with symbols (dtc -@), as Arch Linux ARM does, so overlays can
be applied to them.
@jdvmi00

jdvmi00 commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Tested the CI build of linux-omarchy 7.2.8-2 on a DGX Spark (GB10) with NVIDIA open 615.71.09 via DKMS. Boot from NVMe with nvme as a module, both displays, ConnectX at 200 Gb/s with RDMA, and the DGX Dashboard all work. CUDA hangs, though: a GPU write into ordinary process memory, such as a device-to-host cudaMemcpy into a stack variable, never completes.

This config enables DEVICE_PRIVATE, so nvidia-uvm builds HMM and CUDA uses process memory directly. On GB10 that needs SVA, and CONFIG_ARM_SMMU_V3_SVA isn't set, so the GPU never gets a translation. NVIDIA's DGX OS kernel sets both, and so does linux-omarchy-n1x on the gb10 branch.

A local build of this branch with ARM_SMMU_V3_SVA=y passes everything on the same Spark with default driver settings: the hanging case, GPU access to malloc and mmap memory, both Docker GPU paths and a 1 GiB copy. The commit is here if you want to cherry-pick it: https://github.com/jdvmi00/omarchy-pkgs/commits/linux-omarchy-aarch64-sva. ARM_SMMU_V3_SVA isn't in config.x86_64, so it would need to join your arm64-only list to survive regeneration.

@birkskyum

Copy link
Copy Markdown
Contributor

@emirb #930 gave the aarch64 kernel a recipe of its own, linux-omarchy-aarch64, and that's what ships now, so this one can be closed.

@emirb

emirb commented Oct 20, 2026

Copy link
Copy Markdown
Contributor Author

Closing as #930 was merged

@emirb emirb closed this Oct 20, 2026
@emirb
emirb deleted the arm/linux-omarchy-aarch64 branch October 20, 2026 11:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants