80.11. linux-firmware-20260916
All of linux-firmware, as the vendor ports that split it: Intel, AMD, NVIDIA, Realtek, MediaTek, Broadcom, Qualcomm and the rest
| Version | 20260916, release 2 |
| Shelf | boot — Everything before userspace: the kernel, microcode, firmware for the host, bootloader and EFI tooling |
| Phase | 41_system (System), 229 of 1047 in build order |
| Licence | LicenseRef-linux-firmware |
| Homepage | https://gitlab.com/kernel-firmware/linux-firmware |
| Build time | 0.1 SBU |
| Installed size | 0 B in 0 files |
| Recipe | ports/core/boot/linux-firmware/kpkgbuild |
About
linux-firmware is the collection of firmware files that device drivers load into the hardware they drive: Wi-Fi and Bluetooth chips, network cards, sound DSPs and, on most current machines, the GPU. Without it a real machine has no Wi-Fi, no Bluetooth and, on most current graphics, no accelerated display: amdgpu brings up no GPU without its blobs, and the system falls through to simpledrm on the EFI framebuffer, which has no render node, so the compositor draws with the pixman software renderer and no application gets hardware EGL; xe, and i915 on the Intel graphics that submit work through the GuC, run nothing on the GPU without the GuC firmware.
This port is a meta: it installs nothing itself and depends on the eight vendor ports that split upstream’s tree between them, so kpkg install linux-firmware or sudo kdos update install linux-firmware is the whole tree. Each vendor port builds the same tarball and keeps its share; firmware-map builds it once more and records which port ships each file, for kdos firmware sync. The installation medium carries the four vendors most machines need, and every other one is a prebuilt package from the release’s binary host (see The base image).
| Port | Takes | Files and links | Bytes | On the medium |
|---|---|---|---|---|
| firmware-intel | i915/, xe/, intel/ (iwlwifi, Bluetooth ibt-*, IPU, VPU, ISH, QAT, ice, the AVS and catpt DSPs), the top-level iwlwifi-* and qat_* links, isci/ |
792 | 165,910,365 | yes |
| firmware-amd | amdgpu/, radeon/, r128/, amd/, amdnpu/, amdtee/, amd-ucode/ |
977 | 46,613,917 | yes |
| firmware-mediatek | mediatek/ and Ralink’s top-level rt2*, rt3* and rt73 files |
135 | 40,047,901 | yes |
| firmware-realtek | rtw88/, rtw89/, rtlwifi/, rtl_bt/, rtl_nic/, realtek/ |
165 | 9,580,394 | yes |
| firmware-nvidia | nvidia/ |
491 | 113,769,285 | no |
| firmware-qualcomm | ath*/, ar3k/, qca/, qcom/ and Atheros’ top-level ath3k, ar5523, ar7010, ar9170, ar9271, carl9170, htc_* and wil6210 files |
428 | 83,369,680 | no |
| firmware-broadcom | brcm/, cypress/, bnx2/, bnx2x/, tigon/ |
161 | 14,900,487 | no |
| firmware-misc | everything else: Cirrus and TI sound amplifiers, Marvell, Mellanox, Netronome, QLogic and Chelsio server networking, TV tuners, older Wi-Fi | 3,427 | 121,511,339 | no |
The bytes are the files each package installs, measured from a build of upstream’s 20260916 release; each package also carries the licence texts, about 0.97 MB. The medium’s four come to 262,152,577 bytes and the four left off it to 333,550,791. AMD’s CPU microcode is in firmware-amd, under amd-ucode/, and 090_initramfs.sh concatenates it into the early microcode archive (see Microcode); the medium therefore always carries firmware-amd.
The files are code for another processor, so they are one of the payloads that are installed as upstream publishes them rather than compiled here; see What is built from source.
Why it is in KDOS
The comment above the 10 ports from firmware-intel to linux-firmware in script/phases/41_system/packages.d/boot.txt:
Firmware. Without it a real machine has no Wi-Fi, no Bluetooth and — this is the one that surprises people — no GPU: from Vega/GFX9 on, amdgpu must load PSP/SMU/GFX/SDMA blobs before it can bring the display up, and Xe and Gen12+ i915 refuse to load without GuC. You fall through to simpledrm on the EFI framebuffer: a picture, no EGL, no compositor.
Upstream's whole tree, installed by its own copy-firmware.sh and split by vendor: each firmware-* port builds the same tarball and keeps its share, firmware-map records which port ships each file for
kdos firmware sync, and the linux-firmware meta is all of them.
Sources
None: the port builds from its own directory, /ports/core/boot/linux-firmware.
Dependencies
Depends on: firmware-intel, firmware-amd, firmware-nvidia, firmware-realtek, firmware-mediatek, firmware-broadcom, firmware-qualcomm, firmware-misc.
Required by: no port names it.
Installation
From the repository root, inside the build container, this is the line kdosbuild runs for the port:
script/chroot/exec.sh bash -c 'source script/phases/41_system/phase.env && kpkg install linux-firmware'
What kpkg does
kpkg runs these steps, in this order, as root inside the chroot. The port directory is /ports/core/boot/linux-firmware.
1. Verify every declared source. Each file a sha256 = line names, found in the port directory or in /var/cache/kpkg/sources, must hash to its line; a mismatch stops the build before anything is unpacked.
2. Unpack. The work directory is emptied and the first source is unpacked into $SRC with its top directory stripped; any later tarball lands unstripped beside it in $SRC_ROOT, and a file that is not a tarball is copied into $SRC.
SRC_ROOT=/var/cache/kpkg/work/linux-firmware
SRC=$SRC_ROOT/linux-firmware-20260916
PKG=$SRC_ROOT/pkg
rm -rf "$SRC_ROOT"
mkdir -p "$SRC" "$PKG"
Every config.guess and config.sub older than automake’s is then replaced with automake’s, so a configure script recognises the musl target.
3. Build. build.sh is sourced in a subshell under set -e, from $SRC, with name, version, release and the recipe’s helpers group and the five paths PKGNAME, PORT_SRC, SRC_ROOT, SRC and PKG set as shell variables. Its body, verbatim:
The common switches of each build system are explained in the Flag glossary.
4. Package. kpkg removes libtool archives, the info directory index, mimeinfo.cache and every fonts.dir from $PKG, copies the source’s licence files into /usr/share/licenses/linux-firmware, prunes what the image does not ship, lints the tree and rolls it reproducibly:
tar --sort=name --format=gnu --numeric-owner --owner=0 --group=0 \
--mtime=@$SOURCE_DATE_EPOCH \
--use-compress-program='xz -9 -T0 --block-size=32MiB --no-adjust' \
-cf linux-firmware-20260916-2.tar.xz -C "$PKG" .
5. Adopt. kpkgadd installs the package’s files over the root, refusing a path another package owns, records the file list in /var/lib/kpkg/db/linux-firmware, and runs the triggers its paths call for.
Notes
Every vendor port and firmware-map carries linux-firmware-$version.tar.xz under this port’s file name and checksum, its version equals this port’s, and all of them carry group = linux-firmware, so the version checker offers the set only as one bump (see A second build of the same source). They share one build.sh, byte for byte, and testing/preflight.sh fails a port whose copy differs from firmware-map’s, a vendor the rule names that is not a port, and a vendor port this meta’s depends leaves out. That one script:
- Installs every file and link upstream’s
WHENCElists into a staging tree with upstream’s owncopy-firmware.sh --zstd, so eachFile:entry lands as<name>.zstand eachRawFile:entry, the AMD microcode among them, uncompressed. The kernel decompresses them as it loads them: the linux port’skdos.configsetsCONFIG_andFW_ LOADER_ COMPRESS CONFIG_, and a kernel built without them finds none of these files. zstd is in each port’sFW_ LOADER_ COMPRESS_ ZSTD dependsfor this. - Deletes the firmware no x86 kernel loads, in order. Under
qcom/, every entry exceptaic100,aic200,qdu100, thesdx*directories and theprog_firehose_*files, which are the Qualcomm firmware kept as loadable by an x86 kernel, and every top-level symlink intoqcom/this leaves without a target. Of the Mellanox Spectrum switch firmware, everymlxsw_spectrum*.mfa2except one version for each of the first three Spectrum generations: the file the kernel’smlxswdriver names in itsMLXSW_SP1_FW_FILENAME,MLXSW_SP2_FW_FILENAMEandMLXSW_SP3_FW_FILENAME. The driver requests that exact file and no other; every Spectrum-4 image goes, because the driver names no firmware file for that generation. Of the Marvell Prestera firmware, the two oldest images,v2.0andv3.0, which the kernel’s driver never asks for: it asks for its supported version,v4.1, and falls back only to the one before it,v4.0. - Fails if any symlink in the staging tree is left without a target.
- Gives every file and link to one vendor with
fw_vendor, acaseover its path relative to/lib/firmware, first match winning, anything unmatched going to firmware-misc. A link is given to the vendor of the file it resolves to, never by its own path, so the top-leveliwlwifi-*links travel withintel/iwlwifi/and the TI amplifier links at the top withti/audio/, and no package holds a link to another package’s file; the vendor port’s build fails if one does. - In a vendor port, copies the files and links that are its own into
$PKG/lib/firmware, and fails when there are none, which is what a misspelt vendor in the rule produces. In firmware-map, writes one<port> <path>line per file and link instead, the path without.zst, as a driver requests it, and sorted by path, to/usr/share/kdos/firmware-map. - Installs
WHENCE, the top-level licence files and theLICENSES/directory into/usr/share/licenses/<port>, and fails ifWHENCEnames a licence file that is not there.
The mlxsw versions kept are the kernel’s choice, written into build.sh as a list of files to keep. When a new linux names different versions, that list has to follow it, or the firmware the new driver requests is among the files deleted. The Prestera images are deleted by name, so a kernel that asks for a newer one is unaffected.
A rule moved from one vendor to another changes which package owns the files, so every port of the set is rebuilt together, as a version bump does. Each vendor port names linux-firmware in replaces: on a root whose linux-firmware package still owns the files, the vendor port takes them instead of being refused, and the meta’s own upgrade then installs no files. The meta cannot be in the vendor ports’ depends, which replaces otherwise asks for, because it depends on them; it owns no path, so installing it again never contends with them.
The packages install into /lib/firmware. /lib is a link to /usr/lib in the KDOS root, so the files land in /usr/lib/firmware, the directory the image phase reads microcode from.