coinboot
coinboot copied to clipboard
modprobe: can't load module zstd (kernel/crypto/zstd.ko): unknown symbol in module, or unknown parameter
Booting a focal
suite kernel 5.15.0-48-generic
with zram
bootflag ends up in a kernel panic:
$ qemu-system-x86_64 -kernel coinboot-vmlinuz-5.15.0-48-generic -initrd coinboot-initramfs-5.15.0-48-generic -m 4096 -smp 2 -nographic -serial mon:stdio -append "console=ttyS0 net.ifnames=0 biosdevname=0 break=skip_loading_plugins zram"
[...]
Honoring zram kernel arg
[ 4.269253] zram: Added device: zram0
[ 4.284727] zstd: Unknown symbol ZSTD_initCCtx (err -2)
[ 4.285098] zstd: Unknown symbol ZSTD_getParams (err -2)
[ 4.285335] zstd: Unknown symbol ZSTD_CCtxWorkspaceBound (err -2)
[ 4.285609] zstd: Unknown symbol ZSTD_compressCCtx (err -2)
modprobe: can't load module zstd (kernel/crypto/zstd.ko): unknown symbol in module, or unknown parameter
[ 4.360702] Can't allocate a compression stream
[ 4.361164] zram: Cannot initialise zstd compressing backend
sh: write error: Cannot allocate memory
When booting with kernel commandline flag break=top
to enter an interactive debugging in early user space init
we can see that the module zstd_compress.ko
is missing.
zstd_compress.ko
is a depency of the module zstd.ko
as we can see with modinfo zstd
.
$ qemu-system-x86_64 -kernel coinboot-vmlinuz-5.15.0-48-generic -initrd coinboot-initramfs-5.15.0-48-generic -m 4096 -smp 2 -nographic -serial mon:stdio -append "console=ttyS0 net.ifnames=0 biosdevname=0 break=top zram"
[...]
cd /lib/modules/5.15.0-48-generic
/lib/modules/5.15.0-48-generic # ls -R .
.:
kernel
./kernel:
crypto drivers
./kernel/crypto:
zstd.ko
./kernel/drivers:
block
./kernel/drivers/block:
zram
./kernel/drivers/block/zram:
zram.ko
Did a fix at: 6b6517ef51ec884a9ba31c4bd656e36f1731fc91