lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMj1kXF2kKyEOc6KSBfbdUMf5m4o=DLZXk4++C3q-utA_9g4DA@mail.gmail.com>
Date: Mon, 3 Nov 2025 16:00:44 +0100
From: Ard Biesheuvel <ardb@...nel.org>
To: Nathan Chancellor <nathan@...nel.org>
Cc: Eugene Shalygin <eugene.shalygin@...il.com>, 
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>, Masahiro Yamada <masahiroy@...nel.org>, 
	linux-kbuild@...r.kernel.org
Subject: Re: Can't boot kernel 6.17.4+ via rEFInd

On Fri, 31 Oct 2025 at 23:07, Nathan Chancellor <nathan@...nel.org> wrote:
>
> Hi Eugene,
>
> On Wed, Oct 29, 2025 at 09:07:20PM +0100, Eugene Shalygin wrote:
> > On Tue, 28 Oct 2025 at 18:45, Nathan Chancellor <nathan@...nel.org> wrote:
> > > > Replacing CONFIG_KERNEL_ZSTD with  CONFIG_KERNEL_GZIP made the kernel
> > > > bootable. What does that mean?
> > >
> > > Hmmmm, I am not sure... That seems rather odd within the context of the
> > > flagged change.
> >
> > Huh! The fourth of my machines with the similar config (also fully
> > updated ~amd64 Gentoo) with rEFind boots kernel 6.17.5 with
> > CONFIG_KERNEL_ZSTD enabled.
> >
> > > Could you post the output of 'readelf -S vmlinux vmlinux.unstripped'
> > > from the broken and good builds?
> >
> > Attached.
>
> Unfortunately, nothing appears to be out of the ordinary there... Only
> .modinfo gets removed from the vmlinux.unstripped to vmlinux stage.
>
> > > Does rEFInd have any sort of additional
> > > debugging to see why/what it is complaining about not being able to
> > > find?
> >
> > No, unfortunately. However, I was unable to find the first part of the
> > error message ("Not Found") in the rEFInd sources.
>
> I am guessing the "Not Found" is EFI_NOT_FOUND, so I think this is
> coming from StartEFIImage() in refind/launch_efi.c:
>
>   https://sourceforge.net/p/refind/code/ci/253abe5c4af58d044912517daa567c4440612c46/tree/refind/launch_efi.c#l290
>
> I am not sure where the LoadImage call comes from (the firmware?) so I
> don't really know why that call would fail... Has CONFIG_KERNEL_ZSTD
> always worked in this configuration? Presumably since you are not seeing
> "Invalid loader file", you are going into the
>
>   if ((LoaderType == LOADER_TYPE_EFI) || (LoaderType == LOADER_TYPE_GZIP)) {
>
> branch there. I am at a bit of a loss here. Ard, could you see any
> obvious reason from an EFI perspective why
>
>   3e86e4d74c04 ("kbuild: keep .modinfo section in vmlinux.unstripped")
>
> would cause issues with booting via rEFInd?

For some reason, this change seems to result in a PE/COFF header
change that results in the EFI firmware refusing to load it.

Eugene, can you try whether the image can be loaded by the EFI shell
directly? You may have to rename the file and give it a .efi
extension, but otherwise, you should be able to boot it using

Shell> fs0:bzImage.efi root=/dev/....   etc etc

(or wherever the file resides)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ