From 29f2903c8795d3269e1ffff507190c82e01267f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kai=20L=C3=BCke?= Date: Mon, 26 Jul 2021 14:29:11 +0200 Subject: [PATCH] sys-kernel/coreos-modules: switch to gzip/zstd compression With the default gzip compression the 60 MB limit for the vmlinuz bundle of kernel+initramfs was reached. The limit comes from the size of the /boot partition which is 128 MB large and the kernel needs to fit twice, in addition to GRUB. Use zstd for the initramfs as it provides a similar speed but better compression. For the kernel we can't switch yet to zstd for arm64 but for amd64 it works. --- .../sys-kernel/coreos-kernel/coreos-kernel-5.10.52.ebuild | 2 ++ .../sys-kernel/coreos-modules/files/amd64_defconfig-5.10 | 1 + 2 files changed, 3 insertions(+) diff --git a/sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-kernel/coreos-kernel-5.10.52.ebuild b/sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-kernel/coreos-kernel-5.10.52.ebuild index fad542f804..175e1b2e3a 100644 --- a/sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-kernel/coreos-kernel-5.10.52.ebuild +++ b/sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-kernel/coreos-kernel-5.10.52.ebuild @@ -11,6 +11,7 @@ KEYWORDS="amd64 arm64" RDEPEND="=sys-kernel/coreos-modules-${PVR}" DEPEND="${RDEPEND} app-arch/gzip + app-arch/zstd app-shells/bash coreos-base/coreos-init:= sys-apps/coreutils @@ -65,6 +66,7 @@ src_prepare() { # Symlink to bootengine.cpio so we can stick with relative paths in .config ln -sv "${ROOT}"/usr/share/bootengine/bootengine.cpio build/ || die config_update 'CONFIG_INITRAMFS_SOURCE="bootengine.cpio"' + config_update 'CONFIG_INITRAMFS_COMPRESSION_ZSTD=y' # include all intel and amd microcode files, avoiding the signatures local fw_dir="${ROOT}lib/firmware" diff --git a/sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-modules/files/amd64_defconfig-5.10 b/sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-modules/files/amd64_defconfig-5.10 index 0cd55ee7ec..0863067341 100644 --- a/sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-modules/files/amd64_defconfig-5.10 +++ b/sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-modules/files/amd64_defconfig-5.10 @@ -76,6 +76,7 @@ CONFIG_ISCSI_IBFT=y CONFIG_ISCSI_IBFT_FIND=y CONFIG_ITCO_VENDOR_SUPPORT=y CONFIG_ITCO_WDT=m +CONFIG_KERNEL_ZSTD=y CONFIG_KEXEC_FILE=y CONFIG_KPROBES_ON_FTRACE=y CONFIG_KVM=m