]> git.ipfire.org Git - thirdparty/grub.git/commit
loader/efi/linux: Unload previous Linux kernel/initrd before updating kernel size
authorAdriano Cordova <adrianox@gmail.com>
Wed, 18 Jun 2025 15:38:14 +0000 (11:38 -0400)
committerDaniel Kiper <daniel.kiper@oracle.com>
Thu, 26 Jun 2025 16:05:08 +0000 (18:05 +0200)
commitde80acf3684d8440937a5beb6270579f6893fee4
treecfb9b33dede070ca5f7bf21cedf9157030028baf
parent249db11d8fc365476b45103ccef4b14361d70b7e
loader/efi/linux: Unload previous Linux kernel/initrd before updating kernel size

Unload previous Linux kernel/initrd before updating the global variable
kernel_size. Otherwise the previous Linux kernel gets deallocated with
the kernel_size of the Linux kernel that is being currently loaded.

Signed-off-by: Adriano Cordova <adriano.cordova@canonical.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/loader/efi/linux.c