This is a note to let you know that I've just added the patch titled x86/boot: efistub: Assign global boot_params variable to the 6.1-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: x86-boot-efistub-assign-global-boot_params-variable.patch and it can be found in the queue-6.1 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From stable+bounces-25910-greg=kroah.com@xxxxxxxxxxxxxxx Mon Mar 4 12:21:16 2024 From: Ard Biesheuvel <ardb+git@xxxxxxxxxx> Date: Mon, 4 Mar 2024 12:19:55 +0100 Subject: x86/boot: efistub: Assign global boot_params variable To: stable@xxxxxxxxxxxxxxx Cc: linux-efi@xxxxxxxxxxxxxxx, Ard Biesheuvel <ardb@xxxxxxxxxx>, Ingo Molnar <mingo@xxxxxxxxxx> Message-ID: <20240304111937.2556102-37-ardb+git@xxxxxxxxxx> From: Ard Biesheuvel <ardb+git@xxxxxxxxxx> From: Ard Biesheuvel <ardb@xxxxxxxxxx> [ Commit 50dcc2e0d62e3c4a54f39673c4dc3dcde7c74d52 upstream ] Now that the x86 EFI stub calls into some APIs exposed by the decompressor (e.g., kaslr_get_random_long()), it is necessary to ensure that the global boot_params variable is set correctly before doing so. Signed-off-by: Ard Biesheuvel <ardb@xxxxxxxxxx> Signed-off-by: Ingo Molnar <mingo@xxxxxxxxxx> Signed-off-by: Ard Biesheuvel <ardb@xxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- drivers/firmware/efi/libstub/x86-stub.c | 2 ++ 1 file changed, 2 insertions(+) --- a/drivers/firmware/efi/libstub/x86-stub.c +++ b/drivers/firmware/efi/libstub/x86-stub.c @@ -827,6 +827,8 @@ void __noreturn efi_stub_entry(efi_handl unsigned long kernel_entry; efi_status_t status; + boot_params_ptr = boot_params; + efi_system_table = sys_table_arg; /* Check if we were booted by the EFI firmware */ if (efi_system_table->hdr.signature != EFI_SYSTEM_TABLE_SIGNATURE) Patches currently in stable-queue which might be from kroah.com@xxxxxxxxxxxxxxx are queue-6.1/x86-decompressor-avoid-magic-offsets-for-efi-handover-entrypoint.patch queue-6.1/x86-efistub-avoid-placing-the-kernel-below-load_physical_addr.patch queue-6.1/x86-efistub-avoid-legacy-decompressor-when-doing-efi-boot.patch queue-6.1/x86-efistub-perform-4-5-level-paging-switch-from-the-stub.patch queue-6.1/x86-boot-rename-conflicting-boot_params-pointer-to-boot_params_ptr.patch queue-6.1/x86-efistub-perform-snp-feature-test-while-running-in-the-firmware.patch queue-6.1/x86-efistub-simplify-and-clean-up-handover-entry-code.patch queue-6.1/efi-libstub-add-memory-attribute-protocol-definitions.patch queue-6.1/efi-libstub-add-limit-argument-to-efi_random_alloc.patch queue-6.1/efi-x86-fix-the-missing-kaslr_flag-bit-in-boot_params-hdr.loadflags.patch queue-6.1/arm64-efi-limit-allocations-to-48-bit-addressable-physical-region.patch queue-6.1/x86-efistub-prefer-efi-memory-attributes-protocol-over-dxe-services.patch queue-6.1/efi-efivars-prevent-double-registration.patch queue-6.1/x86-boot-efistub-assign-global-boot_params-variable.patch queue-6.1/x86-efistub-clear-bss-in-efi-handover-protocol-entrypoint.patch queue-6.1/x86-decompressor-factor-out-kernel-decompression-and-relocation.patch queue-6.1/efi-x86-avoid-physical-kaslr-on-older-dell-systems.patch