From nobody Sat Jul 11 19:30:26 2026 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4gyJh33DMXz6lWV8 for ; Sat, 11 Jul 2026 19:30:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "YR1" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4gyJh30ScDz3ZjN for ; Sat, 11 Jul 2026 19:30:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1783798227; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=f9NN5nuCXMl3yN6uZD8XXH4YENLRHS4eZWlZmZNlP0s=; b=HO9eLhruqrdy8HCXvxyFNyHG2KLDFB4WalQzh877pSpHweNgvy77XIx1DBtUS/2cpL39/j 4gdhv6Yo+krN3ypKnyR7B61EAr0wUG+RBfG19UM4KhE1N2yyMMo6qXl8/0+I7KNsfRpKwF 2QF4HvWz+3jhSZ/xQgwNKQRNUvxlNMQXa29MFCFg8XQEKqmRcyJqgkuICz3j0EI/dDBQyi SQ6ybLbiOVKsGq6Nvx155HVzARAVtfEOdTIcN19F3SX9EAnYyBiyI+Rjui6oZau11DQeDc p2Ls5ebBvPSCqJiZ+1WJfLIqlj9gixNxawks2fe1x0lxl+7ESHKeTLP9oAqwkA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1783798227; a=rsa-sha256; cv=none; b=VvfkMmRuog2fxAyti6+Nw3SUqI7VonbJM7obE5fzcKw7VswJWKtMFE/0AYb0C4NVVW7ka+ /N6kE2nHZV3AUKvgwEp2d2WwnATUl//iVO8te0ekmQ4Bb58raeyFu2goAuqEuKBlHmNklB T5kPBlQqr67p3DrKyBVA33+ogRsXRW69yK9U52gXp9IZMJmbCS/mqPcXkGWLdFg0n77nmM vpGHJbN8o2EoKXpypYMljH9tl6tH7fpNUUCrtGp8P/xU6eNgj43B6AXsLK46QpHhZYpTZy bp82QBD3v5s1lO8krjAxaq1wvYrwpO16qECEzuT/8eDbFGvZFknLakPm3MidRQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1783798227; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=f9NN5nuCXMl3yN6uZD8XXH4YENLRHS4eZWlZmZNlP0s=; b=pacHKmNcEQcbOf/I3JoAGfierl2sbFY3YAe+Ys1Jdo7Bcd/46+xArJwHbHEUxpOmcKiqvO gxlgCGTVqVCw9ba+Ms528vbetnmtn8GZXC29UIhGr7xs7FSFMh7lLpveXcQ9qDEG2j/jnB iRQJbit0Gyc3ZTnmyjDathsk2G1PCMK4SL/qtkF0m1NheAzYME16e8noo1bdYyyO7/1sM/ ZDPQURklfcNo/hVmZQ0MYRS7PsBZvzKi+avf1fM4/yxBOt+AWH831petJE42To0manO9ze 0uCUhdNnPFT3IfR/vM58RrrTwLyLGfLmhK8PuQJTGBI4J/fG+u+WI1hc6KbpPA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4gyJh26TcGztsZ for ; Sat, 11 Jul 2026 19:30:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 2703a by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sat, 11 Jul 2026 19:30:26 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: c61ee49cd06a - main - loader: zstd based filesystem, zstdfs like gzipfs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c61ee49cd06a610193493f033f04d38cf61f11e2 Auto-Submitted: auto-generated Date: Sat, 11 Jul 2026 19:30:26 +0000 Message-Id: <6a5299d2.2703a.4911201a@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=c61ee49cd06a610193493f033f04d38cf61f11e2 commit c61ee49cd06a610193493f033f04d38cf61f11e2 Author: Warner Losh AuthorDate: 2026-07-11 14:46:19 +0000 Commit: Warner Losh CommitDate: 2026-07-11 19:28:47 +0000 loader: zstd based filesystem, zstdfs like gzipfs Off by default. Sponsored by: Netflix --- stand/efi/loader/conf.c | 1 + stand/i386/loader/conf.c | 1 + stand/kboot/kboot/conf.c | 4 ++++ stand/libsa/Makefile | 6 ++++++ stand/libsa/libsa.3 | 14 ++++++++++++++ stand/libsa/stand.h | 1 + stand/userboot/userboot/conf.c | 1 + 7 files changed, 28 insertions(+) diff --git a/stand/efi/loader/conf.c b/stand/efi/loader/conf.c index 4f257dc5ba23..30d9b95739e8 100644 --- a/stand/efi/loader/conf.c +++ b/stand/efi/loader/conf.c @@ -57,6 +57,7 @@ struct devsw *devsw[] = { struct fs_ops *file_system[] = { #ifdef EFI_ZFS_BOOT &zfs_fsops, + &zstdfs_fsops, #endif &dosfs_fsops, &ufs_fsops, diff --git a/stand/i386/loader/conf.c b/stand/i386/loader/conf.c index 643990699ca1..3360c2722035 100644 --- a/stand/i386/loader/conf.c +++ b/stand/i386/loader/conf.c @@ -62,6 +62,7 @@ struct devsw *devsw[] = { struct fs_ops *file_system[] = { #if defined(LOADER_ZFS_SUPPORT) &zfs_fsops, + &zstdfs_fsops, #endif #if defined(LOADER_UFS_SUPPORT) &ufs_fsops, diff --git a/stand/kboot/kboot/conf.c b/stand/kboot/kboot/conf.c index 5d384c5270e6..03c3ea750e76 100644 --- a/stand/kboot/kboot/conf.c +++ b/stand/kboot/kboot/conf.c @@ -85,11 +85,15 @@ struct fs_ops *file_system[] = { #if defined(LOADER_BZIP2_SUPPORT) &bzipfs_fsops, #endif +#if defined(LOADER_XZ_SUPPORT) + &xzfs_fsops, +#endif #if defined(LOADER_MSDOS_SUPPORT) &dosfs_fsops, #endif #if defined(LOADER_ZFS_SUPPORT) &zfs_fsops, + &zstdfs_fsops, #endif &hostfs_fsops, NULL diff --git a/stand/libsa/Makefile b/stand/libsa/Makefile index 2bb33060ee2a..173dec69657d 100644 --- a/stand/libsa/Makefile +++ b/stand/libsa/Makefile @@ -192,6 +192,12 @@ SRCS+= g_eli_hmac.c pkcs5v2.c # Maybe ZFS .if ${MK_LOADER_ZFS} == "yes" .include "${SASRC}/zfs/Makefile.inc" + +# zstdfs.c is a stacked filesystem for .zst files, like gzipfs.c/bzipfs.c +# above; it's only buildable here because zfs/Makefile.inc already pulled +# the zstd decompressor in for ZFS's on-disk compression. +SRCS+= zstdfs.c +CFLAGS.zstdfs.c+= ${ZSTD_CFLAGS} .endif # Crypto hashing functions diff --git a/stand/libsa/libsa.3 b/stand/libsa/libsa.3 index 0947f97a0a1f..a44588901f8b 100644 --- a/stand/libsa/libsa.3 +++ b/stand/libsa/libsa.3 @@ -781,6 +781,20 @@ The same as but for .Xr bzip2 1 Ns -compressed files. +.It Va xzfs_fsops +The same as +.Va gzipfs_fsops , +but for +.Xr xz 1 Ns -compressed +files. +.It Va zstdfs_fsops +The same as +.Va gzipfs_fsops , +but for +.Xr zstd 1 Ns -compressed +files. +Only available when built with ZFS support, since that is the only +source of the zstd decompressor in the boot loader environment. .It Va pkgfs_fsops File access from a tar file typically streamed via TFTP. The order of files in the tar file must match the order they are diff --git a/stand/libsa/stand.h b/stand/libsa/stand.h index 3cb227ce2079..6e363b145595 100644 --- a/stand/libsa/stand.h +++ b/stand/libsa/stand.h @@ -131,6 +131,7 @@ extern struct fs_ops cd9660_fsops; extern struct fs_ops gzipfs_fsops; extern struct fs_ops bzipfs_fsops; extern struct fs_ops xzfs_fsops; +extern struct fs_ops zstdfs_fsops; extern struct fs_ops dosfs_fsops; extern struct fs_ops ext2fs_fsops; extern struct fs_ops splitfs_fsops; diff --git a/stand/userboot/userboot/conf.c b/stand/userboot/userboot/conf.c index 8d37f241c9bf..662f4e405f0a 100644 --- a/stand/userboot/userboot/conf.c +++ b/stand/userboot/userboot/conf.c @@ -67,6 +67,7 @@ struct fs_ops *file_system[] = { &cd9660_fsops, #if defined(USERBOOT_ZFS_SUPPORT) &zfs_fsops, + &zstdfs_fsops, #endif &gzipfs_fsops, &bzipfs_fsops,